I had tried to setup shared disks between my Linux VMs, one for swap and the other for software builds. This was working, but it caused more problems (not VMware-related) than it was worth. So I removed them for all VMs, deleted the files from the host.
However, the info on each disk still remains, which is not allowing me to create any snapshots. Here's what's left over on some guests:
$ grep -e 'shared-build' */*.vmx
fedora-34/fedora-34.vmx:nvme0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
fedora-34/fedora-34.vmx:scsi0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
gentoo-term-systemd/gentoo-term-systemd.vmx:scsi0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
gentoo-term/gentoo.vmx:scsi0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
opensuse-leap/opensuse-leap.vmx:nvme0:1.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
opensuse-leap/opensuse-leap.vmx:scsi0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
opensuse-tw/opensuse-tw.vmx:scsi0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
ubuntu-18/ubuntu-18.vmx:scsi0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
ubuntu-20/ubuntu-20.vmx:scsi0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
I'm hesitant to just yank these entries out, because I'm also seeing other entries that reference the old SCSI device:
$ grep --color=auto scsi0:2 opensuse-leap/opensuse-leap.vmx
scsi0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
scsi0:2.mode = "independent-persistent"
scsi0:2.redo = ""
Looking for the safest way to proceed.
For safe advice we need:
- at least one complete vmx-file
- we need to know what you actually plan to acchieve:
A: run several VMs at the same time sharing a single vmdk ?
B: re-enable snapshots for VM XY ?
Suggestion for Linux vmdks for swap only !
1. create new 8gb split vmdk.
2. boot guestOS and partition and format one swap partition.
3. use it once with swapon /dev/sdx
4. power off
5. Edit descriptor vmdk and find the lines starting with RW.
6. Change RW to RDONLY.
7 copy this VMDK to every Linux VM that needs extra swap
Advantage: files keeps smallest size over extensive use.
Tested with WS 16.2.3 on Debian Host
Here's a .vmx file:
My goal is to be able to take snapshots. My previous wishes to have shared vmdks is no longer necessary.
nvme0:0.fileName = "/media/vms/vmware-images/shared-swap/shared-swap.vmdk"
nvme0:1.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
scsi0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
scsi0:2.mode = "independent-persistent"
Blue lines make zero sense when you assign one vmdk three times to the same VM.
Remove red line to re-enable snapshots.
This vmx is incomplete after a manual edit - please send complete vmx - or we assume this has been edited without enough vmx-syntax knowhow so we fix it.
Right now only the boot vmdk and the swap vmdk are active.
Ulli
Not sure why you feel that the .vmx is incomplete; it was never manually edited, either. This is why I'm having the problem - these lines remained after I removed the devices from the VMware Workstation console.
Also, the (3) blue lines are not the same vmdk; (2) are, but I tried using both nvme and scsi buses for a performance test. I know what disks are active.
whats the difference between
nvme0:1.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
scsi0:2.fileName = "/media/vms/vmware-images/shared-build/shared-build.vmdk"
IMHO I would suggest scsi over nvme. In my tests NVME was less stable and slower than SCSI-lsi-sas.
Ok - I see.The missing lines result from lazy vmx-handling of the UI.
OK - I removed the offending blue/red lines from @continuum's earlier reply, restarted the VMware Workstation gui, and now I can take snapshots. Still not sure why there were left over from deletion in the gui, but at least snapshots are working now.
Yeah, I've gone with SCSI on all my new VMs; only the Windows ones seem to use NVMe as the default.