I have an Ubuntu VM hosted in HyperV server and a pair of usb enclosures (one SSD, one spinning metal) successfully passed through as SCSI hard drives in my Linux VM.
Issue: whenever booting the VM, partitions aren’t mountable. They aren’t shown when running lsblk. When I open the devices in fdisk, and then press ‘w’ to write the table, the drives then appear in lsblk, and become mountable.
How can I have the drives mountable at boot without additional intervention?
I’ve verified that the sector sizes reported for one of the drives (the hdd) matches the actual sector size of the drive.
Also, the partitions are recognized at boot if I’m using the drives in a non-virtualized Linux environment.
It makes it a bit of a hassle to perform regular maintenance on the host and on the vm, since rebooting requires I manually login and fixup the partitions and manually mount them.
Not sure what these mean, but dmesg includes many lines like this. Not sure what to make of them, or if they’re even related to the issue. Thanks in advance.
[978792.161396] sr 0:0:0:1: [sr0] tag#373 unaligned transfer
[978792.161397] blk_update_request: I/O error, dev sr0, sector 2097139 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 0
[978792.162284] Buffer I/O error on dev sr0, logical block 2097139, async page read.