Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.

Bug 511372

Summary: guestfish doesn't understand '~' in filenames
Product: [Community] Virtualization Tools Reporter: Richard W.M. Jones <rjones>
Component: libguestfsAssignee: Richard W.M. Jones <rjones>
Status: CLOSED UPSTREAM QA Contact:
Severity: medium Docs Contact:
Priority: low    
Version: unspecifiedCC: mbooth, virt-maint
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-03-27 10:39:35 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Richard W.M. Jones 2009-07-14 20:31:05 UTC
Description of problem:

><fs> add-drive ~/my.img
libguestfs: error: ~/my.img: No such file or directory

This was reported by 'KVM' here:

http://d.hatena.ne.jp/kvm/20090711/1247323823

Comment 1 Matthew Booth 2009-07-14 21:47:40 UTC
A little man page digging threw up wordexp(3).

Comment 2 Richard W.M. Jones 2009-07-15 10:47:25 UTC
Using wordexp or glob is more complicated because you would
have to prevent it from expanding other globs (eg '*') in the
path.  This patch takes a more direct approach using getpwent:

http://git.et.redhat.com/?p=libguestfs.git;a=commitdiff;h=9449b0fce4145a56df9d43169d61e8b2c4e41b09

Comment 3 Fedora Update System 2009-07-23 15:12:24 UTC
libguestfs-1.0.64-2.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/libguestfs-1.0.64-2.el5

Comment 4 Fedora Update System 2009-07-27 14:45:27 UTC
libguestfs-1.0.64-3.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/libguestfs-1.0.64-3.el5

Comment 5 Fedora Update System 2009-07-29 17:01:04 UTC
libguestfs-1.0.65-2.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/libguestfs-1.0.65-2.el5

Comment 6 Fedora Update System 2009-08-07 08:34:25 UTC
libguestfs-1.0.66-4.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/libguestfs-1.0.66-4.el5

Comment 7 Fedora Update System 2009-08-14 09:14:06 UTC
libguestfs-1.0.67-1.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/libguestfs-1.0.67-1.el5

Comment 8 Fedora Update System 2009-08-18 00:23:03 UTC
libguestfs-1.0.65-2.el5 has been pushed to the Fedora EPEL 5 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 9 Fedora Update System 2009-08-19 21:55:36 UTC
libguestfs-1.0.68-5.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/libguestfs-1.0.68-5.el5

Comment 10 Fedora Update System 2009-09-08 22:59:44 UTC
libguestfs-1.0.68-5.el5 has been pushed to the Fedora EPEL 5 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 11 Richard W.M. Jones 2010-03-27 10:39:35 UTC
Long fixed upstream:

><fs> add ~/disk.img
><fs>