Results 1 to 9 of 9
  1. #1
    5 Star Lounger petesmst's Avatar
    Join Date
    Dec 2009
    Location
    Cape Town, South Africa
    Posts
    902
    Thanks
    48
    Thanked 55 Times in 44 Posts

    Does Guest OS in a VM on a SSD "see" the SSD as a SSD?

    When running Windows 10 (in my case, "Insider, Fast Ring") in a VM running on the SSD of the host OS (Windows 10 Pro), does the guest OS "see" the segment of the SSD it runs on as an SSD? Or does it see it as a HDD? Can the host OS run Trim on the SSD segment? If not, should the user run Optimise in the guest OS if the VM disk is shown to be fragmented by the guest OS?

    I ask this, because my Windows 10 Insider VM (running under VMWare on the same SSD as my host Windows 10 Pro OS) indicates the Guest OS to be fragmented and offers the option to "defragment" it. I clicked to see what would happen, and VMWare ran the "defrag" for about 5 minutes. This is longer than one would expect if Trim had been carried out. If Trim can not be run in this situation, is it wise to run Defrag and possibly increase wear on the SSD?

    Does the Virtual Windows 10 OS "see" the SSD as an SSD and does it automatically run Trim as it would when not installed as a VM? Can it, in fact, run Trim when in a virtual setup?

    (The VMWare Support/Help page states the following:

    "Solid-State Drives:

    If your host machine has a physical solid-state drive (SSD), the host informs guest operating systems they are running on an SSD.

    This allows the guest operating systems to optimize behavior. How the virtual machines recognize SSD and use this information depends on the guest operating system and the disk type of the virtual disk (SCSI, SATA, or IDE).

    On Windows 8, Ubuntu, and Red Hat Enterprise Linux virtual machines, all drive types can report their virtual disks as SSD drives.

    On Windows 7 virtual machines, only IDE and SATA virtual disks can report their virtual disks as SSD. SCSI virtual disks only report as SSD when used as a system drive in a virtual machine, or as a mechanical drive when used as a data drive inside a virtual machine.

    On Mac virtual machines, only SATA virtual disks are reported as SSD. IDE and SCSI virtual disks are reported as mechanical drives.

    Use the virtual machine operating system to verify your virtual machine is using SSD as its virtual disk."


    So, it seems that the Guest "sees" the SSD; but the above does not say if the Guest can actually Trim its segment of the SSD. All it says is "How the virtual machines recognize SSD and use this information depends on the guest operating system and the disk type of the virtual disk (SCSI, SATA, or IDE)."

    The text in Red further complicates things: How does one "verify that the VM OS is using the SSD as an SSD?

    A Wiki article upsets things by stating: "The TRIM command does not work with disks which are stored in disk image files. This is caused by the fact that computer files can only be deleted completely or truncated at the end. This problem affects applications like virtual disk services, virtual machines, etc."

    It seems that "the question is not about translating a TRIM operation on the virtual disk to a TRIM operation on the host disk. It does not work so directly. The question is clearly about translating a TRIM call on the virtual disk to a shortening of the image file on the host disk (which, incidentally, can in turn trigger a TRIM operation on the host disk, but the question is about the first step)

    Comments from Expert Loungers that could perhaps clarify this complex issue would be greatly appreciated.

    (Sorry for the convoluted way I have expressed myself, but hopefully Loungers will understand my dilemma!!)
    Last edited by petesmst; 2017-05-22 at 09:29. Reason: Corrected several typos and added two paras
    (My Setup: Custom built: 4.00GHz Intel Core i7-6700K CPU; MSI Z170A Gaming Carbon Mobo (Military Class V); Win 10 Pro (64 bit)-(UEFI-booted); 16GB RAM; 500GB SAMSUNG 960 EVO M.2 NVME SSD; 512GB SAMSUNG 850 PRO SSD; Seagate 2TB Barracuda SATA6G HDD; 2 X GeForceGTX 1070 8GB Graphics Card (SLI); Office 2013 Prof (32-bit); Acronis TI 2017 Premium, Norton Internet Security, VMWare Workstation12 Pro). WD My Book 3 1TB USB External Backup Drive). Dell S2417DG G-Sync UHD Monitor.

  2. #2
    Administrator Rick Corbett's Avatar
    Join Date
    Dec 2009
    Location
    South Glos., UK
    Posts
    3,638
    Thanks
    161
    Thanked 1,004 Times in 801 Posts
    I'm running a similar setup and I just hover the mouse over the hard disk icon in the status bar below the Guest window.

    vmware.png

    VMware Workstation shows me the type of HD that has been configured for the Guest OS. Mine always defaults to a virtual SCSI drive, even though it's running on an SSD.

    Hope this helps...

  3. #3
    5 Star Lounger petesmst's Avatar
    Join Date
    Dec 2009
    Location
    Cape Town, South Africa
    Posts
    902
    Thanks
    48
    Thanked 55 Times in 44 Posts
    @Rick Corbett: Thanks (mine does too), but the contradictory "stuff" in my post is still not resolved: Does The host disk get "trimmed", or does the recognition of a fragmented state get dealt with by means of a "shortening of the image file on the host disk" instead?
    (My Setup: Custom built: 4.00GHz Intel Core i7-6700K CPU; MSI Z170A Gaming Carbon Mobo (Military Class V); Win 10 Pro (64 bit)-(UEFI-booted); 16GB RAM; 500GB SAMSUNG 960 EVO M.2 NVME SSD; 512GB SAMSUNG 850 PRO SSD; Seagate 2TB Barracuda SATA6G HDD; 2 X GeForceGTX 1070 8GB Graphics Card (SLI); Office 2013 Prof (32-bit); Acronis TI 2017 Premium, Norton Internet Security, VMWare Workstation12 Pro). WD My Book 3 1TB USB External Backup Drive). Dell S2417DG G-Sync UHD Monitor.

  4. #4
    Administrator Rick Corbett's Avatar
    Join Date
    Dec 2009
    Location
    South Glos., UK
    Posts
    3,638
    Thanks
    161
    Thanked 1,004 Times in 801 Posts
    I think 'fragmentation' refers to the file/files that make up the virtual hard disk.

    Hope this helps...

  5. #5
    WS Lounge VIP
    Join Date
    Dec 2009
    Location
    Earth
    Posts
    9,073
    Thanks
    65
    Thanked 1,146 Times in 1,067 Posts
    The virtual disk is just a file(s) on the host disk, so TRIM is not relevant and is probably ignored by VMware.

    Fragmentation is referring to the files in the virtual disk. This may be because you started with a small virtual disk that you have expanded several times, so the file on the host disk contains multiple segments and the virtual files are split over those segments. It's OK to let VMware defrag as it's only the virtual files that are affected.

    cheers, Paul

  6. #6
    5 Star Lounger petesmst's Avatar
    Join Date
    Dec 2009
    Location
    Cape Town, South Africa
    Posts
    902
    Thanks
    48
    Thanked 55 Times in 44 Posts
    @Paul T: Thanks. So it seems that Windows 10, as Guest OS, does not/cannot send a Trim command to the SSD it is running on.
    (My Setup: Custom built: 4.00GHz Intel Core i7-6700K CPU; MSI Z170A Gaming Carbon Mobo (Military Class V); Win 10 Pro (64 bit)-(UEFI-booted); 16GB RAM; 500GB SAMSUNG 960 EVO M.2 NVME SSD; 512GB SAMSUNG 850 PRO SSD; Seagate 2TB Barracuda SATA6G HDD; 2 X GeForceGTX 1070 8GB Graphics Card (SLI); Office 2013 Prof (32-bit); Acronis TI 2017 Premium, Norton Internet Security, VMWare Workstation12 Pro). WD My Book 3 1TB USB External Backup Drive). Dell S2417DG G-Sync UHD Monitor.

  7. #7
    WS Lounge VIP
    Join Date
    Dec 2009
    Location
    Earth
    Posts
    9,073
    Thanks
    65
    Thanked 1,146 Times in 1,067 Posts
    I would expect a guest to send TRIM commands, but VMware probably ignores them.

    cheers, Paul

  8. #8
    New Lounger
    Join Date
    Dec 2009
    Location
    Smack Dab in the Middle
    Posts
    20
    Thanks
    4
    Thanked 1 Time in 1 Post
    In a VM environment I can't see any performance issue with fragmentation on a SSD drive. It's having to refer to different locations of memory rather then contiguous space which should be negligible in differences in time. The difference with a HDD is the head(s) have to bounce around the platters to satisfy requests. This takes more time since its a mechanical interaction causing more time to complete file reads on fragmented files vs contiguous files.

    I'd love to see someone performance test this.

  9. #9
    5 Star Lounger petesmst's Avatar
    Join Date
    Dec 2009
    Location
    Cape Town, South Africa
    Posts
    902
    Thanks
    48
    Thanked 55 Times in 44 Posts
    @Paul T and @ Lex Rex. Many thanks. I note that VMWare DOES, from time to time, warn me (particularly after upgrading Windows 10 Insider to a new build that "your drive is defragmented, run now to reduce file size").
    (My Setup: Custom built: 4.00GHz Intel Core i7-6700K CPU; MSI Z170A Gaming Carbon Mobo (Military Class V); Win 10 Pro (64 bit)-(UEFI-booted); 16GB RAM; 500GB SAMSUNG 960 EVO M.2 NVME SSD; 512GB SAMSUNG 850 PRO SSD; Seagate 2TB Barracuda SATA6G HDD; 2 X GeForceGTX 1070 8GB Graphics Card (SLI); Office 2013 Prof (32-bit); Acronis TI 2017 Premium, Norton Internet Security, VMWare Workstation12 Pro). WD My Book 3 1TB USB External Backup Drive). Dell S2417DG G-Sync UHD Monitor.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •