#571063 qemu-kvm: Please warn if booting a mounted filesystem (with option to override)

Package:
qemu-kvm
Source:
qemu
Submitter:
Josh Triplett
Date:
2025-07-28 19:57:05 UTC
Severity:
wishlist
Tags:
#571063#3
Date:
2010-02-23 07:22:52 UTC
From:
To:
Unless you want to do something really magic[1], you almost certainly
don't want to use kvm to boot a mounted filesystem.  This can cause
filesystem corruption.  Please consider having kvm detect mounted
filesystems and refuse to boot them.  To handle those magic cases, offer
an option -force-mounted or similar to override that detection.

I've done this myself (realized halfway through a Debian install onto a
USB drive via debian-installer in KVM that I left the USB drive booted),
and I've also had to explain how to check for mounted partitions before
booting them with kvm.  A bit of DWIM seems helpful.

[1] Like mounting GFS2 or another multi-mount filesystem, or booting
    your main disk and carefully not booting the running system's root
    filesystem...

- Josh Triplett