diff --git a/lib/bdev.py b/lib/bdev.py index 8ba593022f6a18ff3b34e7af4cc3f1ce56e0fdac..8ae50e8faaa84230b010b66cac575464b66ad119 100644 --- a/lib/bdev.py +++ b/lib/bdev.py @@ -2280,7 +2280,7 @@ class FileStorage(BlockDev): try: f = open(dev_path, 'w') except IOError, err: - raise BlockDeviceError("Could not create '%'" % err) + raise errors.BlockDeviceError("Could not create '%'" % err) else: f.truncate(size * 1024 * 1024) f.close() diff --git a/lib/cmdlib.py b/lib/cmdlib.py index 9d3b9a509aa34981ba22bd1825d67900bd00d1e3..c21eafce7da11c29b5f6df06308e3ddeffe507e3 100644 --- a/lib/cmdlib.py +++ b/lib/cmdlib.py @@ -3025,7 +3025,7 @@ def _CreateDisks(cfg, instance): file_storage_dir) if not result: - logger.Error("Could not connect to node '%s'" % inst.primary_node) + logger.Error("Could not connect to node '%s'" % instance.primary_node) return False if not result[0]: @@ -4396,7 +4396,7 @@ class LUExportInstance(LogicalUnit): # shutdown the instance, but not the disks if not rpc.call_instance_shutdown(src_node, instance): raise errors.OpExecError("Could not shutdown instance %s on node %s" % - (instance.name, source_node)) + (instance.name, src_node)) vgname = self.cfg.GetVGName()