Commit d1a0ab50 authored by Guido Trotter's avatar Guido Trotter
Browse files

Merge branch 'devel-2.2' into devel-2.3



* devel-2.2:
  Fix rename for file-backed instances
Signed-off-by: default avatarGuido Trotter <ultrotter@google.com>
Reviewed-by: default avatarIustin Pop <iustin@google.com>
parents 9a91d357 be9f4904
......@@ -1005,10 +1005,11 @@ class ConfigWriter:
if disk.dev_type == constants.LD_FILE:
# rename the file paths in logical and physical id
file_storage_dir = os.path.dirname(os.path.dirname(disk.logical_id[1]))
disk_fname = "disk%s" % disk.iv_name.split("/")[1]
disk.physical_id = disk.logical_id = (disk.logical_id[0],
utils.PathJoin(file_storage_dir,
inst.name,
disk.iv_name))
disk_fname))
# Force update of ssconf files
self._config_data.cluster.serial_no += 1
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment