Bug 626873 - pool creation fails if directory includes a broken symlink
Summary: pool creation fails if directory includes a broken symlink
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: libvirt
Version: 6.1
Hardware: All
OS: Linux
low
medium
Target Milestone: rc
: ---
Assignee: Osier Yang
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Keywords:
: 652189 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-08-24 15:33 UTC by Eric Paris
Modified: 2011-05-19 13:20 UTC (History)
8 users (show)

(edit)
Clone Of:
(edit)
Last Closed: 2011-05-19 13:20:43 UTC


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:0596 normal SHIPPED_LIVE libvirt bug fix and enhancement update 2011-05-18 17:56:36 UTC

Description Eric Paris 2010-08-24 15:33:55 UTC
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-16 04:17:17 UTC
*** Bug 652189 has been marked as a duplicate of this bug. ***

Comment 3 Osier Yang 2010-12-22 03:44:58 UTC
patch post upstream:

76965b800e40c2084f03c4359f614fd802087832

Comment 4 Jiri Denemark 2011-01-09 23:57:29 UTC
Built into libvirt-0.8.7-1.el6

Comment 6 Nan Zhang 2011-01-10 08:46:54 UTC
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 07:24:59 UTC
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 13:20:43 UTC
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.