Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 590799 - guestfish donot work with xen domain xml
Summary: guestfish donot work with xen domain xml
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: libguestfs
Version: 6.0
Hardware: All
OS: Linux
low
medium
Target Milestone: rc
: ---
Assignee: Richard W.M. Jones
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-05-10 17:56 UTC by Kirby Zhou
Modified: 2010-05-12 11:58 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-05-12 11:58:16 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Kirby Zhou 2010-05-10 17:56:42 UTC
Description of problem:

guestfish donot work with xen domain xml.

Version-Release number of selected component (if applicable):

guestfish-1.0.85-1.el6.1.x86_64
libguestfs-1.0.85-1.el6.1.x86_64
libguestfs-tools-1.0.85-1.el6.1.x86_64
qemu-img-0.12.1.2-2.17.el6.x86_64

How reproducible:


Steps to Reproduce:

[root@djt-18-97 ~]# guestfish -i kirby-dev.xml
--fish output is only possible with a single OS

[root@djt-18-97 ~]# cat kirby-dev.xml 
<domain type='xen' id='57'>
  <name>kirby-dev</name>
  <uuid>8859ada6-2fa6-d53a-1f2f-c36e0614d807</uuid>
  <memory>8388608</memory>
  <currentMemory>8388608</currentMemory>
  <vcpu>8</vcpu>
  <bootloader>/usr/bin/pygrub</bootloader>
  <clock offset='utc'/>
  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>restart</on_crash>
  <devices>
    <disk type='block' device='disk'>
      <driver name='phy'/>
      <source dev='/dev/vgxpool/kirby-dev'/>
      <target dev='xvda' bus='xen'/>
    </disk>
    <disk type='block' device='disk'>
      <driver name='phy'/>
      <source dev='/dev/vgxpool/kirby-dev-data0'/>
      <target dev='xvdb' bus='xen'/>
    </disk>
    <interface type='bridge'>
      <mac address='00:16:3e:72:70:57'/>
      <source bridge='vbr0'/>
      <script path='vif-bridge'/>
      <target dev='vif57.0'/>
    </interface>
    <interface type='bridge'>
      <mac address='00:16:3e:72:70:58'/>
      <source bridge='vbr1'/>
      <script path='vif-bridge'/>
      <target dev='vif57.1'/>
    </interface>
    <console type='pty' tty='/dev/pts/12'>
      <source path='/dev/pts/12'/>
      <target port='0'/>
    </console>
  </devices>
</domain>



Actual results:


Expected results:


Additional info:

guestmount works

~]# guestmount $(virt-inspector --ro-fish /dev/vgxpool/kirby-dev /dev/vgxpool/kirby-dev-data0) /mnt/xxx/

Comment 2 Richard W.M. Jones 2010-05-10 18:15:38 UTC
> [root@djt-18-97 ~]# guestfish -i kirby-dev.xml

I see what you're trying to do, but the '-i' option can
only be used on disk image(s), not on libvirt XML.

You can extract the disk image paths from the
XML by doing:

$ xpath /domain/devices/disk/source < /tmp/dev.xml
Found 2 nodes:
-- NODE --
<source dev="/dev/vgxpool/kirby-dev" />
-- NODE --
<source dev="/dev/vgxpool/kirby-dev-data0" />

[Using the xpath program from perl-XML-XPath]

Then run guestfish -i directly on those disk images:

# guestfish -i /dev/vgxpool/kirby-dev /dev/vgxpool/kirby-dev-data0

Comment 3 Richard W.M. Jones 2010-05-10 18:16:29 UTC
Or ...  if the domain is in libvirt, you can just do:

# guestfish -i NameOfDomain

Comment 4 RHEL Product and Program Management 2010-05-10 19:13:57 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for
inclusion.

Comment 5 Richard W.M. Jones 2010-05-12 11:58:16 UTC
Closing, since this is not a bug.


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