+<pre>
+$ <b>virt-inspector -c qemu:///system -d Win7x32</b>
+
+<font style="color: #888;"><?xml version="1.0"?></font>
+<font style="color: #888;"><operatingsystems></font>
+ <font style="color: #888;"><operatingsystem></font>
+ <font style="color: #888;"><root></font>/dev/sda2<font style="color: #888;"></root></font>
+ <font style="color: #888;"><name></font>windows<font style="color: #888;"></name></font>
+ <font style="color: #888;"><arch></font>i386<font style="color: #888;"></arch></font>
+ <font style="color: #888;"><distro></font>windows<font style="color: #888;"></distro></font>
+ <font style="color: #888;"><product_name></font>Windows 7 Enterprise<font style="color: #888;"></product_name></font>
+ <font style="color: #888;"><product_variant></font>Client<font style="color: #888;"></product_variant></font>
+ <font style="color: #888;"><major_version></font>6<font style="color: #888;"></major_version></font>
+ <font style="color: #888;"><minor_version></font>1<font style="color: #888;"></minor_version></font>
+ <font style="color: #888;"><windows_systemroot></font>/Windows<font style="color: #888;"></windows_systemroot></font>
+ <font style="color: #888;"><windows_current_control_set></font>ControlSet001<font style="color: #888;"></windows_current_control_set></font>
+ <font style="color: #888;"><hostname></font>win7x32<font style="color: #888;"></hostname></font>
+<i>... etc ...</i>
+</pre>
+<p class="sourcelnk"><a href="win7.xml">full XML ...</a></p>
+
+ <table>
+ <tr><td colspan="2" align="middle">
+ <small><i>Click to enlarge the images</i></small>
+ </td></tr>
+ <tr><td width="50%">
+ <a href="virt-manager.png"><img src="virt-manager-t.png"></a>
+ </td><td width="50%" align="middle" valign="top">
+ <a href="vmm-icons.png"><img src="vmm-icons-t.png"></a>
+ </td></tr>
+ </table>
+
+<pre>
+ char **roots;
+ size_t i;
+ char *type, *distro, *product_name;
+ int major, minor;
+
+ roots = <b>guestfs_inspect_os</b> (g);
+
+ if (roots == NULL)
+ exit (EXIT_FAILURE);
+
+ if (roots[0] == NULL) {
+ fprintf (stderr, "no operating systems found\n");
+ exit (EXIT_FAILURE);
+ }
+
+ for (i = 0; roots[i] != NULL; ++i) {
+ type = <b>guestfs_inspect_get_type</b> (g, roots[i]);
+ distro = <b>guestfs_inspect_get_distro</b> (g, roots[i]);
+ product_name = <b>guestfs_inspect_get_product_name</b> (g, roots[i]);
+ major = <b>guestfs_inspect_get_major_version</b> (g, roots[i]);
+ minor = <b>guestfs_inspect_get_minor_version</b> (g, roots[i]);
+
+ printf ("Root: %s\n"
+ " Type: %s\n"
+ " Distro: %s\n"
+ " Version: %d.%d\n"
+ " Product name: %s\n\n");
+ roots[i],
+ type ? : "unknown", distro ? : "unknown", major, minor,
+ product_name ? : "");
+
+ free (type);
+ free (distro);
+ free (product_name);
+ free (roots[i]);
+ }
+
+ free (roots);
+</pre>
+<p class="sourcelnk"><a href="http://git.annexia.org/?p=libguestfs.git;a=blob;f=rescue/virt-rescue.c;h=0c0036460434f1365d9591d6b2b805d999b07056;hb=HEAD#l351">full source ...</a></p>
+