curl driver (http) always says "No such file or directory"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
QEMU |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
I have a remote server, on which an http disk image definitely exists. However the qemu curl block driver cannot open it. It always gives the bogus error:
CURL: Error opening file: Connection time-out
qemu-system-x86_64: -drive file=http://
On the server, I can see from the logs that qemu/curl is opening it:
192.168.0.175 - - [15/Jan/
192.168.0.175 - - [15/Jan/
I am using qemu & curl from git today.
curl: curl-7_
qemu: for-anthony-
Here is the full command I am using:
http_proxy= \
LD_LIBRARY_
LIBGUESTFS_
LIBGUESTFS_
guestfish -v --ro -a http://
The full output (includes qemu command itself) is:
libguestfs: launch: program=guestfish
libguestfs: launch: version=
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=
libguestfs: launch: umask=0002
libguestfs: launch: euid=1000
libguestfs: command: run: /usr/bin/
libguestfs: command: run: \ --verbose
libguestfs: command: run: \ -f checksum
libguestfs: command: run: \ --host-cpu x86_64
libguestfs: command: run: \ /usr/lib64/
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/lib64/
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/
checking modpath /lib/modules/
checking modpath /lib/modules/
checking modpath /lib/modules/
picked kernel vmlinuz-
supermin helper [00000ms] finished creating kernel
supermin helper [00000ms] visiting /usr/lib64/
supermin helper [00000ms] visiting /usr/lib64/
supermin helper [00000ms] visiting /usr/lib64/
supermin helper [00000ms] visiting /usr/lib64/
supermin helper [00041ms] visiting /usr/lib64/
supermin helper [00041ms] visiting /usr/lib64/
supermin helper [00041ms] adding kernel modules
supermin helper [00064ms] finished creating appliance
libguestfs: checksum of existing appliance: 2017df18eaeee7c
libguestfs: [00066ms] begin testing qemu features
libguestfs: command: run: /home/rjones/
libguestfs: command: run: \ -display none
libguestfs: command: run: \ -help
libguestfs: command: run: /home/rjones/
libguestfs: command: run: \ -display none
libguestfs: command: run: \ -version
libguestfs: qemu version 1.7
libguestfs: command: run: /home/rjones/
libguestfs: command: run: \ -display none
libguestfs: command: run: \ -machine accel=kvm:tcg
libguestfs: command: run: \ -device ?
libguestfs: [00127ms] finished testing qemu features
[00128ms] /home/rjones/
-global virtio-
-nodefconfig \
-enable-fips \
-nodefaults \
-display none \
-machine accel=kvm:tcg \
-cpu host,+kvmclock \
-m 500 \
-no-reboot \
-no-hpet \
-kernel /var/tmp/
-initrd /var/tmp/
-device virtio-
-drive file=http://
-device scsi-hd,drive=hd0 \
-drive file=/var/
-device scsi-hd,
-device virtio-serial-pci \
-serial stdio \
-device sga \
-chardev socket,
-device virtserialport,
-append 'panic=1 console=ttyS0 udevtimeout=600 no_timer_check acpi=off printk.time=1 cgroup_
CURL: Error opening file: Connection time-out
qemu-system-x86_64: -drive file=http://
libguestfs: error: appliance closed the connection unexpectedly, see earlier error messages
libguestfs: child_cleanup: 0x7f07bf6599b0: child process died
libguestfs: sending SIGTERM to process 19654
libguestfs: error: /home/rjones/
libguestfs: error: guestfs_launch failed, see earlier error messages
libguestfs: closing guestfs handle 0x7f07bf6599b0 (state 0)
libguestfs: command: run: rm
libguestfs: command: run: \ -rf /tmp/libguestfs
description: | updated |
summary: |
- curl driver (http) always says "No such file or directory" + curl driver (https) always says "No such file or directory" |
Turns out this is because of using "snapshot=on".
Simple reproducer:
./x86_64- softmmu/ qemu-system- x86_64 -drive 'file=http:// 127.0.0. 1/~rjones/ cirros- 0.3.1-x86_ 64-disk. img,if= virtio, snapshot= on'