Skip to contentSkip to conversation

Reopen file descriptors on 'cont' command

Qemu-devel Christopher Pereira 2 participants 3 messages Feb 26, 2015 – Mar 6, 2015

lore
Share & tools
lore
#1 lore raw
Quoted 8 lines · Christopher Pereira

Does qemu reopen files on a 'cont' command?

When working with images on a gluster volume, file descriptors may get into a bad state because of network timeouts, remounting a share, etc...and reinitializing file descriptors may be usefull to get paused VMs up again.

Related BZ:
https://bugzilla.redhat.com/show_bug.cgi?id=1058300

No, QEMU doesn't reopen file descriptors.

This can be challenging because QEMU supports file descriptor passing, which is used when the QEMU process is isolated using SELinux so it cannot open files itself. Reopening would require new file descriptors passed in from the management tool.

Stefan

#2 lore raw
Quoted 7 lines · Stefan Hajnoczi
Quoted 6 lines · Christopher Pereira

Does qemu reopen files on a 'cont' command?

When working with images on a gluster volume, file descriptors may get into a bad state because of network timeouts, remounting a share, etc...and reinitializing file descriptors may be usefull to get paused VMs up again.

Quoted 8 lines
Quoted 2 lines

Related BZ:
https://bugzilla.redhat.com/show_bug.cgi?id=1058300

No, QEMU doesn't reopen file descriptors.

This can be challenging because QEMU supports file descriptor passing, which is used when the QEMU process is isolated using SELinux so it cannot open files itself. Reopening would require new file descriptors passed in from the management tool.

Thanks Stefan.

I confirmed that libvirtd is not passing a FD to QEMU, but an image path.
Is QEMU reopening this image file when the VM is resumed?
QEMU must check if the FD (initialized by QEMU) is still valid, especially after resuming a paused VM.