Whenever I start an Ubuntu Server virtual machine in VMware Workstation, disk usage suddenly spikes and the computer eventually freezes if I keep using it. MySQL also sometimes fails to start inside the virtual machine. The host has 8 GB of RAM, a 7th-generation Intel Core i7, and a 1 TB hard drive. I have already disabled MySQL, PostgreSQL, and other services that I do not need at startup, but the problem still occurs. What could be causing this, and how can I troubleshoot it?
2 Answers
The virtual machine may be putting more pressure on your system than the 8 GB of RAM can comfortably handle, especially if the guest is running several services. When physical memory runs low, Windows and the VM can start paging heavily to the hard drive, which explains the disk activity and freezing. Check the VM's assigned RAM and CPU cores, monitor memory usage in both the host and guest, and avoid running unnecessary services. Moving the host and VM storage to an SSD would also make a major difference.
Disabling random host services may help a little, but first confirm what is actually being exhausted. Watch Task Manager while starting the VM and check the VM's memory settings, disk usage, and paging activity. Inside Ubuntu, check whether MySQL is failing because of low memory, a port conflict, permissions, or an existing database process. The VM's logs and the MySQL service status should show the specific startup error instead of assuming the disk spike is the only cause.

I noticed the CPU and disk activity spike right when I start the Ubuntu Server VM. I have disabled a few more Windows services that I rarely use, and I plan to move to an SSD soon.