Skip to content

Instantly share code, notes, and snippets.

@gabrielhartmann
Created June 16, 2015 18:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gabrielhartmann/6114578065eae011a2b3 to your computer and use it in GitHub Desktop.
Save gabrielhartmann/6114578065eae011a2b3 to your computer and use it in GitHub Desktop.
Add Remote Disk
$ guestfish -v --ro -a "https://gabhartswarmstorage.blob.core.windows.net/vhds/osdiskforlinuxsimplemaster-osdisk.vhd?se=2016-01-01T00%3A00%3A00Z&sp=r&sv=2014-02-14&sr=b&sig=w56w5TtKsxq7976OMbQH6ZliKt7M%2B282v7d4H2FTBE8%3D" -i
libguestfs: launch: program=guestfish
libguestfs: launch: version=1.24.5
libguestfs: launch: backend registered: unix
libguestfs: launch: backend registered: uml
libguestfs: launch: backend registered: libvirt
libguestfs: launch: backend registered: direct
libguestfs: launch: backend=direct
libguestfs: launch: tmpdir=/tmp/libguestfsXNJycd
libguestfs: launch: umask=0022
libguestfs: launch: euid=0
libguestfs: command: run: /usr/bin/supermin-helper
libguestfs: command: run: \ --verbose
libguestfs: command: run: \ -f checksum
libguestfs: command: run: \ --host-cpu x86_64
libguestfs: command: run: \ /usr/lib/guestfs/supermin.d
supermin helper [00000ms] whitelist = (not specified)
supermin helper [00000ms] host_cpu = x86_64
supermin helper [00000ms] dtb_wildcard = (not specified)
supermin helper [00000ms] inputs:
supermin helper [00000ms] inputs[0] = /usr/lib/guestfs/supermin.d
supermin helper [00000ms] outputs:
supermin helper [00000ms] kernel = (none)
supermin helper [00000ms] dtb = (none)
supermin helper [00000ms] initrd = (none)
supermin helper [00000ms] appliance = (none)
checking modpath /lib/modules/3.16.0-31-generic is a directory
checking modpath /lib/modules/3.13.0-51-generic is a directory
picked kernel vmlinuz-3.16.0-31-generic
supermin helper [00000ms] finished creating kernel
supermin helper [00000ms] visiting /usr/lib/guestfs/supermin.d
supermin helper [00000ms] visiting /usr/lib/guestfs/supermin.d/base.img
supermin helper [00000ms] visiting /usr/lib/guestfs/supermin.d/daemon.img.gz
supermin helper [00000ms] visiting /usr/lib/guestfs/supermin.d/hostfiles
supermin helper [00029ms] visiting /usr/lib/guestfs/supermin.d/init.img
supermin helper [00030ms] visiting /usr/lib/guestfs/supermin.d/udev-rules.img
supermin helper [00030ms] adding kernel modules
supermin helper [00091ms] finished creating appliance
libguestfs: checksum of existing appliance: 56ce15afcd0a6544998f0b8281a5742e7ae81f3df57b835e86c5c36adeabd5ea
libguestfs: [00093ms] begin testing qemu features
libguestfs: command: run: /usr/bin/qemu-system-x86_64
libguestfs: command: run: \ -nographic
libguestfs: command: run: \ -help
libguestfs: command: run: /usr/bin/qemu-system-x86_64
libguestfs: command: run: \ -nographic
libguestfs: command: run: \ -version
libguestfs: qemu version 2.0
libguestfs: command: run: /usr/bin/qemu-system-x86_64
libguestfs: command: run: \ -nographic
libguestfs: command: run: \ -machine accel=kvm:tcg
libguestfs: command: run: \ -device ?
libguestfs: [00204ms] finished testing qemu features
libguestfs: is_openable: /dev/kvm: No such file or directory
libguestfs: command: run: dmesg | grep -Eoh 'lpj=[[:digit:]]+'
libguestfs: read_lpj_from_dmesg: external command exited with error status 1
libguestfs: command: run: grep
libguestfs: command: run: \ -Eoh lpj=[[:digit:]]+
libguestfs: command: run: \ /var/log/dmesg
libguestfs: read_lpj_from_files: calculated lpj=8778808
[00243ms] /usr/bin/qemu-system-x86_64 \
-global virtio-blk-pci.scsi=off \
-nodefconfig \
-enable-fips \
-nodefaults \
-nographic \
-machine accel=kvm:tcg \
-m 500 \
-no-reboot \
-rtc driftfix=slew \
-no-hpet \
-no-kvm-pit-reinjection \
-kernel /var/tmp/.guestfs-0/kernel.18654 \
-initrd /var/tmp/.guestfs-0/initrd.18654 \
-device virtio-scsi-pci,id=scsi \
-drive file=https://gabhartswarmstorage.blob.core.windows.net/vhds/osdiskforlinuxsimplemaster-osdisk.vhd,snapshot=on,cache=writeback,id=hd0,if=none \
-device scsi-hd,drive=hd0 \
-drive file=/var/tmp/.guestfs-0/root.18654,snapshot=on,id=appliance,cache=unsafe,if=none \
-device scsi-hd,drive=appliance \
-device virtio-serial-pci \
-serial stdio \
-device sga \
-chardev socket,path=/tmp/libguestfsXNJycd/guestfsd.sock,id=channel0 \
-device virtserialport,chardev=channel0,name=org.libguestfs.channel.0 \
-append 'panic=1 console=ttyS0 udevtimeout=600 no_timer_check lpj=8778808 acpi=off printk.time=1 cgroup_disable=memory root=/dev/sdb selinux=0 guestfs_verbose=1 TERM=screen-256color'
Warning: option deprecated, use lost_tick_policy property of kvm-pit instead.
Could not access KVM kernel module: No such file or directory
failed to initialize KVM: No such file or directory
Back to tcg accelerator.
CURL: Error opening file: The requested URL returned error: 404 The specified resource does not exist.
qemu-system-x86_64: -drive file=https://gabhartswarmstorage.blob.core.windows.net/vhds/osdiskforlinuxsimplemaster-osdisk.vhd,snapshot=on,cache=writeback,id=hd0,if=none: could not open disk image https://gabhartswarmstorage.blob.core.windows.net/vhds/osdiskforlinuxsimplemaster-osdisk.vhd: Could not open image: Invalid argument
libguestfs: error: appliance closed the connection unexpectedly, see earlier error messages
libguestfs: child_cleanup: 0x18d1ed0: child process died
libguestfs: sending SIGTERM to process 18668
libguestfs: error: /usr/bin/qemu-system-x86_64 exited with error status 1, see debug messages above
libguestfs: error: guestfs_launch failed, see earlier error messages
libguestfs: closing guestfs handle 0x18d1ed0 (state 0)
libguestfs: command: run: rm
libguestfs: command: run: \ -rf /tmp/libguestfsXNJycd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment