Running VM on the same SSD as host OS, useful or pointless?

6,353

Solution 1

Putting the VM on an SSD will greatly enhance disk IO over it being on a drive - this will, however, only help you if the bottleneck is caused by disk IO. If the issue is that the guest OS is swapping a lot, then SSD will help over a hard drive, but will still be way slower then speccing enough memory for the VM.

Similarly, if the problem relates to video or other resources, using an SSD may not make much of a difference.

You do not need a seperate disk for a VM.

Solution 2

I also have only one 512GB SSD and run my VMs also on this SSD and the performance is much better compared to the default 5400rpm drive which was originally installed by Dell. SSDs don't have the delay of the HDDs (no rotating parts) so running VMs on the SSD doesn't slow down the drive.

Solution 3

It will actually increase the performance of disk operations, but the change will not be so apparent in comparison with native OS. It is because the native OS knows it is using SSD and adapts its I/O scheduler to this, but virtual OS does not and I think there is no way to telling it.

The external drive, esp. USB2, would actually slow anything down noticeably. It will add its own delays which will kill all advantages of SSD (delays are exact thing which makes rotating HDD slow in comparison with SSD).

Don't forget to use paravirtualized guest drivers. These exist for linux over vmware, they are included with ubuntu, so you probably need to check which driver you run for now (start with sudo lspci -k) and try to use most efficient. Virtual network card driver is called vmxnet3, graphical driver is vmwgfx, disk driver I believe is called vmw_pvscsi. The usage of proper drivers will have significant impact on performance.

Share:
6,353

Related videos on Youtube

Jorge Orpinel Pérez
Author by

Jorge Orpinel Pérez

Updated on September 18, 2022

Comments

  • Jorge Orpinel Pérez
    Jorge Orpinel Pérez over 1 year

    I have an Alienware M11x R2 computer. A bit old but still kikin'. I run Windows 10 on it and I have VMWare Player installed to run Ubuntu 14.04 LTE on. It works but I used to have dual boot and Ubuntu was def. much faster running natively.

    My question is: Will replacing my HDD with a SSD likely increase the performance of my virtual machine? Someone suggested that. But wouldn't I need a separate drive so that guest OS was stored on a different drive than the host OS, in order to see upgrade? I've read that all over.

    My problem is this computer only has USB 2.0 so I can't really have a fast external drive anyway so stuck with single drive I think.

    Suggestions?

    • David Schwartz
      David Schwartz over 8 years
      "I've read that all over." Then you should be able to give us at least one link to someone saying that so we might have some idea what you're talking about. I can't think of any reason that would be so. An SSD is way faster than an HDD for the same use scenario.
  • David Schwartz
    David Schwartz over 8 years
    Virtualbox lets you tell the guest that it's running on an SSD. I bet many other virtualization solutions do too.
  • Ben Voigt
    Ben Voigt over 8 years
    Indeed, the ability of an SSD to service requests both inside and outside the virtual disk without seeking a head in between makes this one of the best case scenarios for an SSD.
  • Ben Voigt
    Ben Voigt over 8 years
    I think you're overstating the value of telling the OS it is running on an SSD. Even SSD-unaware OSes benefit immensely. It might, however, be a good idea to manually disable any scheduled defragmentation inside the guest, since this reduces the life of the drive for no benefit.
  • Jorge Orpinel Pérez
    Jorge Orpinel Pérez over 8 years
    Thank you. "You do not need a seperate disk for a VM." Reason or source?
  • Jorge Orpinel Pérez
    Jorge Orpinel Pérez over 8 years
    Thanks for the "paravirtualized guest drivers" tip, I wasn't aware.
  • davidgo
    davidgo over 8 years
    I maintain arround a dozen VM servers. Many of those use files as disk. There are specific files commonly used for VMs. I use KVM and COW files but but you can use vmdk files for VMWARE. See pubs.vmware.com/workstation-9/topic/com.vmware.ws.using.doc/‌​…
  • davidgo
    davidgo over 8 years
    Also, on VMs, disk IO is often a bottleneck. Using SSD provides much lower latencies and higher read speeds greatly reducing the bottleneck. Also, there are techniques to convert files into apparent disks (kpartx, loopback mounts, iscsi).