Bug 626873 - pool creation fails if directory includes a broken symlink
pool creation fails if directory includes a broken symlink
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: libvirt (Show other bugs)
6.1
All Linux
low Severity medium
: rc
: ---
Assigned To: Osier Yang
Virtualization Bugs
:
: 652189 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-08-24 11:33 EDT by Eric Paris
Modified: 2011-05-19 09:20 EDT (History)
8 users (show)

See Also:
Fixed In Version: libvirt-0.8.7-1.el6
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-05-19 09:20:43 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Eric Paris 2010-08-24 11:33:55 EDT
libvirt-0.8.1-27.el6.x86_64

I have a broken symlink in /var/lib/libvirt/images

I created this xml file:

<pool type='dir'>
  <name>default</name>
  <target>
    <path>/var/lib/libvirt/images</path>
  </target>
</pool>

and run virsh pool-create [path to file]

This fails to create the pool with the error:

error: Failed to create pool from [path to file]
error: cannot open volume '/var/lib/libvirt/images/[broken symlink]': No such file or directory

I don't understand why a broken symlink should cause the pool creation to fail...
Comment 2 Dave Allan 2010-11-15 23:17:17 EST
*** Bug 652189 has been marked as a duplicate of this bug. ***
Comment 3 Osier Yang 2010-12-21 22:44:58 EST
patch post upstream:

76965b800e40c2084f03c4359f614fd802087832
Comment 4 Jiri Denemark 2011-01-09 18:57:29 EST
Built into libvirt-0.8.7-1.el6
Comment 6 Nan Zhang 2011-01-10 03:46:54 EST
Verified with libvirt-0.8.7-1.el6.x86_64, it's already fixed.

# ln -s /tmp/aaa /var/lib/libvirt/images/testpool

# ll /var/lib/libvirt/images/
total 5691056
-rw-------. 1 qemu qemu 6442450944 Jan 10 03:43 demo.img
lrwxrwxrwx. 1 root root          8 Jan 10 03:23 testpool -> /tmp/aaa
-rw-------. 1 root root 8589934592 Dec 30 01:49 rhel5u6.img
-rw-------. 1 root root 1427636224 Jan  4 05:50 rhel6.qcow2
-rw-------. 1 root root 8589934592 Dec 30 02:22 test.img

# virsh pool-define ~/default-pool.xml
Pool default defined from /root/default-pool.xml
Comment 9 Cui Chun 2011-02-09 02:24:59 EST
Rechecked it on the following test environment according to comment 6. It is passed.

Test environment:
libvirt-0.8.7-5.el6
qemu-kvm-0.12.1.2-2.144.el6
kernel-2.6.32-94.el6
Comment 12 errata-xmlrpc 2011-05-19 09:20:43 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2011-0596.html

Note You need to log in before you can comment on or make changes to this bug.