Bug 1006369 - Don't autostart (or simple start) an instance when raw device is already mounted
Don't autostart (or simple start) an instance when raw device is already mou...
Product: Virtualization Tools
Classification: Community
Component: libvirt (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Libvirt Maintainers
Depends On:
  Show dependency treegraph
Reported: 2013-09-10 10:01 EDT by Arthur Lutz
Modified: 2016-04-10 10:44 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2016-04-10 10:44:11 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Arthur Lutz 2013-09-10 10:01:15 EDT
Description of problem:

When autostarting an instance make sure that the devices used in the VM are not mounted on the host. 

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. stop a machine for inspection
2. mount a device on the host for inspection
3. libvirtd gets restarted (either by monit or by hand) 
4. VM mounts the device which does not hand concurent mounts (ext4 for example)

Actual results:

kernel oops in the VM, damaged data on the disk device. 

Expected results:

the VM should not start and log a warning. 

Additional info:
Comment 1 Cole Robinson 2016-04-10 10:44:11 EDT
Sorry for the lack of a timely response, but Libvirt isn't really in the business of doing this type of checking... we don't even check if disk images are in use by other VMs which is the more likely case I suspect. Look into virtlockd daemon, it may be able to do what you want

Note You need to log in before you can comment on or make changes to this bug.