Bug 1248966

Summary: qemu-img unable to create image filename containing a ':'
Product: Red Hat Enterprise Linux 7 Reporter: Pei Zhang <pezhang>
Component: qemu-kvm-rhevAssignee: Hanna Czenczek <hreitz>
Status: CLOSED NOTABUG QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.2CC: areis, hhuang, hreitz, juli, juzhang, knoel, michen, pezhang, qiguo, rbalakri, shu, sluo, virt-bugs, virt-maint, xfu
Target Milestone: rcKeywords: Regression
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1071058 Environment:
Last Closed: 2015-08-03 16:00:20 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1071058    
Bug Blocks: 1072130, 1105389    

Comment 3 Pei Zhang 2015-07-31 08:52:17 UTC
In qemu-kvm-rhev-2.1.2-1.el7.x86_64, it's enable to create image filename containing a ':', but in qemu-kvm-rhev-2.3.0-13.el7.x86_64 it is unable to create such filename. So this bug is a regression.

Comment 4 Hanna Czenczek 2015-07-31 13:00:07 UTC
Hi,

Both notations work for me in qemu-kvm-rhev-2.3.0-13.el7:

First one (./foo:bar):

$ ./qemu-img create ./foo:bar.qcow2 64M
Formatting './foo:bar.qcow2', fmt=qcow2 size=67108864 encryption=off cluster_size=65536 lazy_refcounts=off refcount_bits=16
$ ls -l foo:bar.qcow2
-rw-r--r-- 1 mreitz users 197120 31. Jul 14:52 foo:bar.qcow2
$ ./qemu-img info ./foo:bar.qcow2
image: ./foo:bar.qcow2
file format: qcow2
virtual size: 64M (67108864 bytes)
...

Second one (file:foo:bar, the one that was fixed for BZ 1071058):

$ ./qemu-img create -f qcow2 file:foo:bar.qcow2 64M     
Formatting 'file:foo:bar.qcow2', fmt=qcow2 size=67108864 encryption=off cluster_size=65536 lazy_refcounts=off refcount_bits=16
$ ls -l foo:bar.qcow2
-rw-r--r-- 1 mreitz users 197120 31. Jul 14:56 foo:bar.qcow2
$ ./qemu-img info file:foo:bar.qcow2
image: foo:bar.qcow2
file format: qcow2
virtual size: 64M (67108864 bytes)
...

Note that "foo:bar.qcow2" not working is intentional (see BZ 1071058 comment 7).

So both seem to work for me.

Max

Comment 5 Pei Zhang 2015-08-03 02:50:28 UTC
Hi Max,

I am sorry for missing BZ 1071058 comment 7 before. I re-tested with './ip-192.168.254.185:asdf' and 'file:ip-192.168.254.186:asdf', and both file names work.

So this bug is not a bug.


Thanks,
zhangpei