提交 f0e72b2f 编写于 作者: S Scott Sullivan 提交者: Eric Blake

qemu: fix RBD attach regression

I have been testing libvirt v1.0.0 for deployment within my
organization, and in the process discovered what appears to be a bug
that breaks virsh attach-device, when attaching an RBD volume to an
instance. First, here is the error presented, with v1.0.0 (this worked
in v0.10.2):

[root@host ~]# virsh attach-device W5APQ8  G84VV1.xml
error: Failed to attach device from G84VV1.xml
error: cannot open file 'dc3-1-test/G84VV1': No such file or directory

Using git bisect, I narrowed the problem down to this as the first
commit to break this setup:

4d34c929 is the first bad commit
上级 bb2f6216
...@@ -2028,7 +2028,7 @@ qemuDomainDetermineDiskChain(struct qemud_driver *driver, ...@@ -2028,7 +2028,7 @@ qemuDomainDetermineDiskChain(struct qemud_driver *driver,
{ {
bool probe = driver->allowDiskFormatProbing; bool probe = driver->allowDiskFormatProbing;
if (!disk->src) if (!disk->src || disk->type == VIR_DOMAIN_DISK_TYPE_NETWORK)
return 0; return 0;
if (disk->backingChain) { if (disk->backingChain) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册