Fabian Deutsch has uploaded a new change for review. Change subject: utils: Suppress failed unmount errors ......................................................................
utils: Suppress failed unmount errors Previously failed unmounts were ignored (which is not good) and an error was shown on the screen. With this patch, the failure is still ignored, but the error is only getting logged as a warning, and not as an error anymore. The failure is still ignored, because it's not the right time to change the behavior of th Mount().unmount() call. Change-Id: I7b7d195b12203cec0944889ce9c5819d33d40eab Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1275962 Signed-off-by: Fabian Deutsch <[email protected]> --- M src/ovirt/node/utils/system.py 1 file changed, 4 insertions(+), 4 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-node refs/changes/37/47937/1 diff --git a/src/ovirt/node/utils/system.py b/src/ovirt/node/utils/system.py index 4de3a4b..e81171f 100755 --- a/src/ovirt/node/utils/system.py +++ b/src/ovirt/node/utils/system.py @@ -1061,11 +1061,11 @@ "was initialized") try: - utils.process.check_call(["umount", self.path]) + utils.process.check_output(["umount", self.path]) - except: - LOGGER.exception("Can't umount %s" % self.path, - exc_info=True) + except subprocess.CalledProcessError as e: + LOGGER.warn("Can't umount %s: %s" % (self.path, e.output), + exc_info=True) def _find_device(self): try: -- To view, visit https://gerrit.ovirt.org/47937 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I7b7d195b12203cec0944889ce9c5819d33d40eab Gerrit-PatchSet: 1 Gerrit-Project: ovirt-node Gerrit-Branch: master Gerrit-Owner: Fabian Deutsch <[email protected]> _______________________________________________ node-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/node-patches
