Skip to content

qemu 2.10+: consider adding --force-share flag #4024

@andrijapanicsb

Description

@andrijapanicsb
ISSUE TYPE
  • Enhancement Request

Investigate a possible usage of "--force-share" parameter when accessing qcow2 files, due to "Qemu 2.10 added the requirement of a --force-share flag to qemu-img info when reading information about a disk that is in use by a guest."

Not sure if this is applicable to qemu itself or just qemu-img (nothing to do here...) - but the way to reproduce the issue where this would help is:

  • qemu 2.10+, NFS v3 (v4 is not affected)
  • kill (power off) the host hosting a running VM
  • "qe0mu-img info" from another host can not access the qcow2 file on a shared NFS storage and also the VM can't be started - so VM HA actions are affected (this is in contrast to when you kill the qemu process only - then the lock is immediately releases, so this is not a valid test) - i.e. killing a host doesn't release a lock

Adding the --force-share option might help in VM HA cases, where NFSv3 is used, so that the VM can be started on another host. This is equivalent (afaik) to qemu-img info -U xxx.qcow2 which does allow access to the qcow2 file which is locked by the dead host.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions