Let's assume I have a KVM-based virtual machine. There is a volume that contains the operating system and the data.
I know it is possible to access from host at least READ-ONLY the filesystem which is on guest.
If it is possible to access the guest FS in RW mode, then could I somehow detect that the filesystem was mounted?
The filesystem is ext4, is it storing any information about how and when it was mounted?
There are 2 things LV Write Access read/write and # open 2 first one is disk is open as read/write and second one is open count.
$ lvdisplay -v /dev/vg_root/lv_swap --- Logical volume --- LV Path /dev/vg_root/lv_swap LV Name lv_swap VG Name vg_root LV UUID SyLfHM-iiKk-Kkxn-O6r9-6DaV-kTFI-7Uvzpb LV Write Access read/write LV Creation host, time localhost.localdomain, 2019-04-12 14:47:37 +0000 LV Status available # open 2 LV Size 1.00 GiB Current LE 256 Segments 1 Allocation inherit Read ahead sectors auto - currently set to 8192 Block device 253:1