diff --git a/tests/test_cli.py b/tests/test_cli.py index 831a3b997..0e34a6bc5 100644 --- a/tests/test_cli.py +++ b/tests/test_cli.py @@ -1436,7 +1436,6 @@ c.add_invalid("--connect %(URI-TEST-FULL)s -o test-clone-simple -n newvm --file c.add_invalid("--connect %(URI-TEST-REMOTE)s -o test-clone-simple --auto-clone --file /dev/default-pool/testvol9.img --check all=off", grep="Clone onto existing storage volume") # hit a specific error message c.add_invalid("--connect %(URI-TEST-FULL)s -o test-clone-full --auto-clone", grep="not enough free space") # catch failure of clone path setting c.add_invalid(_CLONE_NET_HTTP + " --auto-clone", grep="'http' is not cloneable") -c.add_invalid(_CLONE_NET_RBD + " --auto-clone", grep="'rbd' requires managed storage") # connection doesn't have the referenced rbd volume c.add_invalid(_CLONE_NET_RBD + " --connect %(URI-TEST-FULL)s --auto-clone", grep="Cloning rbd volumes is not yet supported") diff --git a/virtinst/cloner.py b/virtinst/cloner.py index 1fdffa2a4..34a702f91 100644 --- a/virtinst/cloner.py +++ b/virtinst/cloner.py @@ -177,17 +177,14 @@ def _get_cloneable_msg(disk): if disk.type == "network": proto = disk.source.protocol - if proto not in ["rbd"]: - return _("Disk network type '%s' is not cloneable.") % proto - disk.set_backend_for_existing_path() - if not disk.get_vol_object(): - return _("Cloning disk network type '%s' requires " - "managed storage.") % proto - else: + if proto == "rbd": # This case, rbd with managed storage, is implementable. It # requires open coding a bunch of work in cloner, or reworking # other disk code to add unique URIs for rbd volumes and pools - return _("Cloning rbd volumes is not yet supported.") + return ( + _("Cloning rbd volumes is not yet supported.") + + " https://github.com/virt-manager/virt-manager/issues/177") + return _("Disk network type '%s' is not cloneable.") % proto def _get_shareable_msg(disk):