3 - good morning to folks in the US, good afternoon or evening everywhere else
4 - welcome to the libguestfs webinar
5 - I am your host, Richard Jones
7 - a few administration points to begin with
8 - please save questions to the end
9 - you can also join the IRC channel #libguestfs and post questions
11 - if you're having problems with webex, see:
12 https://rwmj.wordpress.com/2011/11/17/libguestfs-web-seminar-this-friday/
13 - there is a handout with accompanying slides, see my blog
14 - the session is being recorded
15 - after the session, a recording will be made available; keep an eye
17 - after the session, all the programs, etc will be made available
20 Part 1: an overview of libguestfs
21 ----------------------------------------------------------------------
23 1. Introduction and what it is
25 Libguestfs is a set of tools for viewing, editing and creating
26 virtual machine disk images. That includes:
28 - injecting files into disk images
30 - creating disk images entirely from scratch
32 - adding, moving and deleting partitions and logical volumes
33 - examining disk images to find out what operating systems they contain
34 and what applications are installed
35 - rescuing VMs that don't boot
37 It is also a library, available from C, C++, Perl, Python, Ruby, Java,
38 OCaml and from shell scripts.
40 It is also a FUSE module, that lets you safely mount guest filesystems
43 Libguestfs can access virtually any disk image: We support all known
44 types of Linux filesystem, such as ext2/3/4, XFS, btrfs, GFS2, etc.
45 We support NTFS and FAT for Windows guests. We also support Mac OS X
46 and BSD filesystems. We fully support LVM, GPT partition tables.
47 qcow2, VirtualBox VDI. We have partial support for VMware VMDK.
50 Libguestfs can also access and modify the Windows Registry, read
51 the Windows Event log, change Linux configuration files, and read
57 - rm /etc/udev/rules.d/70-persistent-net.rules (script - sysprep.sh)
59 - make a disk (script - new-disk.sh) (diagram)
61 - interactive on a disk image
62 guestfish --ro -a new-disk.img -i
63 # type some filesystem commands
64 # show inspection data
66 a more realistic script would edit /etc/fstab, reset ssh host keys
67 (in RHEL 6.3: see virt-sysprep)
69 - show guestmount-ing a disk image
73 - get version of firefox installed (for any guest)
75 - takes 12 seconds to run
76 - doing a lot of work in those 12 seconds
77 - using the API directly gives you more control
89 libreoffice builder-rhel6.ods cooking.ods
95 - run virt-filesystems -a on each
97 - run virt-inspector on each
98 virt-inspector disk.img | ../highlight | less -r
100 - xpath queries : app version
101 virt-inspector disk2.img | \
102 xmlstarlet sel -t -c '//application[name="firefox"]'
104 - xpath queries : icon
105 virt-inspector disk2.img | \
106 xmlstarlet sel -t -c 'string(//icon)' | base64 -i -d | display -
110 - show alignment problems in WinXP guest
112 virt-alignment-scan -a winxp.img
114 - realign and resize it
117 truncate -s 10G resized.img
118 virt-resize winxp.img resized.img --expand /dev/sda1 --alignment 2048
120 - performance discussion (diagram here)
123 virt-alignment-scan -a resized.img
127 qemu-kvm -m 1024 -hda resized.img
129 - note this is a RHEL 6.3 feature
132 Part 2: preview of RHEL 6.3
133 ----------------------------------------------------------------------
139 For RHEL 6.0 the focus was on making bug free packages available,
140 but the performance was quite poor.
142 For RHEL 6.1 we concentrated on performance and a few features.
144 RHEL 6.3 is 6-7 months away
145 but there are already preview packages
147 1.7.17 (1.8) -> 1.14 (about 11 months of upstream development)
149 Major new features include:
151 - new tools (for alignment, sysprep, virt-ls -lR, virt-copy-in/out)
153 - further improvements to Windows support, such as being able to use
154 drive letters from most tools
156 - major API extensions for copying whole devices, cancelling
157 long-running operations, brtfs, event API
159 - improvements to guest inspection: live CDs, logos
161 - fully implemented and supported Ruby and Java bindings