Imagine if there was an application that you could feed a disk image to, wether it be Microsoft Windows 2008 or Red Hat EL 6 and see a list of applications that are installed – no step back – imagine if there was an application that you could feed a disk image to and just discover what operating system was installed.
Well fear not! There is such an application. I kid you not, if you are anything like me you are going to look and see this as one of the most amazing discoveries. When I found this, I had a “oh my goodness, why didn’t I know about this sooner” moment.
libguestfs is a set of tools for accessing and modifying virtual machine (VM) disk images. You can use this for viewing and editing files inside guests, scripting changes to VMs, monitoring disk used/free statistics, P2V, V2V, performing partial backups, cloning VMs and much much more.
libguestfs basically allows you to do anything that you have ever dreamed of. Yes. It will even read your Windows Registry “hive” files and spit them out as XML files.
The virt-inspector command examines a virtual machine or disk image and tries to determine the version of the operating system and other information about the virtual machine.
libguestfs is definitely on the TODO list for installing 🙂 I am love. I could just imagine a nice web application thrown on top of this that would allow you to do funky things like that a WIndows machine offline, run a Windows Update *while the virtual machine is not running* and then start the machine up again. Doesn’t sound awesome yet? Think about it this way: a new Windows update is released. You take an LVM snapshot of the currently running box. You apply any Windows Update to the new LVM snapshot, shutdown the current running box while bringing up the new one (or edit the registry and remove any details of the IP and add a script to run on startup…)… so many ideas 🙂