6 input = "libguestfs-1.16.2.tar.gz"
9 os.system ("qemu-img create -f raw %s 512M >/dev/null 2>&1" %
12 g = guestfs.GuestFS ()
13 g.add_drive_opts (output, format = "raw", readonly = 0)
17 g.part_disk ("/dev/sda", "mbr")
18 g.mkfs ("ext4", "/dev/sda1")
19 g.mount ("/dev/sda1", "/")