Virtual Memory or VMEM is a file extension used by virtualization software like VMware, Virtualbox, etc. VMEM files generally store RAM or Physical Memory of the related virtual machine.
VMEM File
Below we can see that there is a file named 564dfc3d-5bac-9fd4-b200-6f492dc81f20.vmem
. The name is a UUID that is unique and created to store RAM. We can see that the size of the file is about 3.1 GB. We can delete this file securely without a problem. But the VM current running state is deleted and the VM start from poweroff situation.

VMEM.lck File
VMEM files can be edited by other applications. This will create problems because the VMEM file holds virtual machines’ memory. In order to prevent VMEM file edit lock files are used. These VMEM lock files have vmem.lck
extension which is a folder. This file do not contain any file or folder.

Configuration
VMware support different configuration about Memory or VMEM files. Here some of them
Enable/Disable Memory Sharing
By disabling memory sharing your guests will not share common memory blocks. Your VMware product will also stop comparing memory blocks.
sched.mem.pshare.enable = "FALSE"
Use Named File
Doesn’t use named-file – use for VMs on USB-disks or other slow disks. On Windows: useNamedFile= “FALSE” causes memory to be backed by the host’s swap space.
mainMem.useNamedFile = "FALSE"
Fit Memory Into RAM
Fit memory into RAM. Whenever possible, avoid settings lower 100%.
prefvmx.minVmMemPct = "100"
Memory Configuration
We can configure virtual machine memory from Virtual Machine Settings
-> Memory
. This configuration will also affect vmem
file size because the memory will be written into vmem
file with the same size.
