Using virt-rescue or virt-edit

From Notes_Wiki
Revision as of 11:46, 20 November 2013 by Saurabh (talk | contribs) (Created page with "<yambe:breadcrumb>Libvirt|Libvirt</yambe:breadcrumb> =Using virt-rescue or virt-edit= It is possible to edit guest VM filesystem using tools such as guestfish, virt-rescue an...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

<yambe:breadcrumb>Libvirt|Libvirt</yambe:breadcrumb>

Using virt-rescue or virt-edit

It is possible to edit guest VM filesystem using tools such as guestfish, virt-rescue and virt-edit. virt-rescue and virt-edit are easier to use and hence are described here.


Using virt-rescue to edit guest VM files

To edit guest VM files using virt-rescue use:

  1. Start virt-rescue using 'virt-rescue -d <domain-name>'
  2. See available disk partitions using 'fdisk -l'
  3. Mount desired partition on /sysroot folder using 'mount /dev/vda<n> /sysroot'
  4. See available commands using 'help'
  5. Once editing of files is complete exit from virt-rescue using 'exit'


Using virt-edit to edit guest VM files

To edit guest VM file using virt-edit use:

virt-edit -d <domain> <file-path>



<yambe:breadcrumb>Libvirt|Libvirt</yambe:breadcrumb>