Difference between revisions of "Guestmount"

From wikieduonline
Jump to navigation Jump to search
 
(19 intermediate revisions by the same user not shown)
Line 1: Line 1:
<code>guestmount</code> command [[mount]] a guest filesystem on the host using [[FUSE]] and [[libguestfs]]. It is included in <code>[[libguestfs-tools]]</code> package.
+
{{lowercase}}
* https://linux.die.net/man/1/guestmount
+
<code>guestmount</code> command [[mount]] a guest filesystem on the host using [[FUSE]] and <code>[[libguestfs]]</code>. It is included in <code>[[libguestfs-tools]]</code> package.
 +
*Man page: https://linux.die.net/man/1/guestmount
  
guestmount -a path_to_image.[[qcow2]] -i --ro /mount_point
+
== Examples ==
 +
* <code>[[guestmount -a]] path_to_image.[[qcow2]] -i --ro /mount_point</code>
 +
* <code>guestmount -a path_to_image.[[qcow2]] -i --rw /mount_point</code>
 +
 
 +
Verify:
 +
[[mount]]
 +
.../...
 +
[[/dev/fuse]] on /mount/path type [[fuse]] (rw,nosuid,nodev,relatime,user_id=0,group_id=0)
 +
.../...
  
 +
-a your_image.[[qcow2]]
  
 
  -i --inspector  inspect the disks looking for an operating system and mount filesystems as they would be mounted on the real virtual machine
 
  -i --inspector  inspect the disks looking for an operating system and mount filesystems as they would be mounted on the real virtual machine
Line 10: Line 20:
 
  guestmount -a path_to_image.[[qcow2]] -i --ro /mount_point
 
  guestmount -a path_to_image.[[qcow2]] -i --ro /mount_point
  
<pre>
+
  guestmount: no operating system was found on this disk
guestmount: no operating system was found on this disk
+
 +
  If using guestfish '-i' option, remove this option and instead
 +
  use the commands 'run' followed by 'list-filesystems'.
 +
  You can then mount filesystems you want by hand using the
 +
  'mount' or 'mount-ro' command.
 +
 +
  If using guestmount '-i', remove this option and choose the
 +
  filesystem(s) you want to see by manually adding '-m' option(s).
 +
  Use '[[virt-filesystems]]' to see what filesystems are available.
 +
 +
  If using other virt tools, this disk image won't work
 +
  with these tools.  Use the guestfis
  
If using guestfish '-i' option, remove this option and instead
 
use the commands 'run' followed by 'list-filesystems'.
 
You can then mount filesystems you want by hand using the
 
'mount' or 'mount-ro' command.
 
  
  If using guestmount '-i', remove this option and choose the
+
  libguestfs: error: findfs_uuid: findfs: unable to resolve '[[UUID]]=8bc77dbf-2217-11e9-bf56-525400670XXX'
filesystem(s) you want to see by manually adding '-m' option(s).
 
Use 'virt-filesystems' to see what filesystems are available.
 
  
  If using other virt tools, this disk image won't work
+
  guestmount -a IMAGE.qcow2  --rw ./mount_point
  with these toolsUse the guestfis
+
  guestmount: error: you must specify either -i at least one -m option.
</pre>
+
  Try ‘guestmount --help’ for more information.
  
  
libguestfs: error: findfs_uuid: findfs: unable to resolve '[[UUID]]=8bc77dbf-2217-11e9-bf56-525400670XXX'
+
guestmount -a your_image.qcow2 -i --ro ./dest_path/
 +
libguestfs: error: /usr/bin/[[supermin]] exited with error status 1.
 +
To see full error messages you may need to enable debugging.
 +
Do:
 +
  export LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1
 +
and run the command again.  For further information, read:
 +
  http://libguestfs.org/guestfs-faq.1.html#debugging-libguestfs
 +
You can also run 'libguestfs-test-tool' and post the *complete* output
 +
into a bug report or message to the libguestfs mailing list.
 +
 +
  Solution: execute as root user
  
 
== Related commands ==
 
== Related commands ==
* <code>[[virt-filesystems]] -a output.img --all --long -h</code>
+
* <code>[[virt-filesystems]] -a --all --long -h output.img</code>
 +
* <code>[[virt-inspector]]</code>
 
* <code>[[findfs]]</code>
 
* <code>[[findfs]]</code>
 
* <code>[[mount]]</code>
 
* <code>[[mount]]</code>
 +
* <code>[[guestfish]]</code>
 +
* <code>[[virt-rescue]]</code>
 +
* <code>[[qemu-nbd]]</code>
  
 
== See also ==
 
== See also ==
 +
* {{virt}}
 
* {{KVM}}
 
* {{KVM}}
* {{virt}}
 
  
 
[[Category:KVM]]
 
[[Category:KVM]]

Latest revision as of 10:49, 13 October 2021

guestmount command mount a guest filesystem on the host using FUSE and libguestfs. It is included in libguestfs-tools package.

Examples[edit]

Verify:
mount
.../...
/dev/fuse on /mount/path type fuse (rw,nosuid,nodev,relatime,user_id=0,group_id=0)
.../...
-a your_image.qcow2
-i --inspector  inspect the disks looking for an operating system and mount filesystems as they would be mounted on the real virtual machine
-m mount
guestmount -a path_to_image.qcow2 -i --ro /mount_point
 guestmount: no operating system was found on this disk

 If using guestfish '-i' option, remove this option and instead
 use the commands 'run' followed by 'list-filesystems'.
 You can then mount filesystems you want by hand using the
 'mount' or 'mount-ro' command.

 If using guestmount '-i', remove this option and choose the
 filesystem(s) you want to see by manually adding '-m' option(s).
 Use 'virt-filesystems' to see what filesystems are available.

 If using other virt tools, this disk image won't work
 with these tools.  Use the guestfis


libguestfs: error: findfs_uuid: findfs: unable to resolve 'UUID=8bc77dbf-2217-11e9-bf56-525400670XXX'
guestmount -a IMAGE.qcow2  --rw ./mount_point
guestmount: error: you must specify either -i at least one -m option.
Try ‘guestmount --help’ for more information.


guestmount -a your_image.qcow2 -i --ro ./dest_path/
libguestfs: error: /usr/bin/supermin exited with error status 1.
To see full error messages you may need to enable debugging.
Do:
  export LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1
and run the command again.  For further information, read:
 http://libguestfs.org/guestfs-faq.1.html#debugging-libguestfs
You can also run 'libguestfs-test-tool' and post the *complete* output
into a bug report or message to the libguestfs mailing list.

 Solution: execute as root user

Related commands[edit]

See also[edit]

Advertising: