2

With spinning hard disks it was relatively common to hear disk thrashing when some process, Windows or otherwise, was making a bad fist of things.

Quite often this was an indicator that a process was in need of attention so became a bit of a canary in the coalmine. OK, actually finding which application was creating the svchost process that was doing all the disk activity wasn't always trivial, but as the impact to system performance was high it was invariably worth the effort.

There are a few things that change in the SSD world however:

  1. SSDs are much faster at the random reads/writes that caused slowdown in HDD-based systems, so the actual impact many be much reduced
  2. SSDs don't make any noise so the user won't immediately know this is happening
  3. Many modern systems don't even have a disk activity light to monitor

Even if 1. means the impact is minimised this doesn't fix the underlying issue or mean it's not worth investigating and fixing.

On the basis that Windows a) hasn't suddenly been fixed to prevent this, and b) that SSDs don't magically cure the issue, how best then to detect "disk" thrashing in SSDs?

7
  • 1
    OK, the word 'thrashing' refers to to the noise a HDD makes, so in that sense SSDs don't 'thrash', but are you saying the simple act of replacing one physical storage medium with another somehow fixes all manner of potential problems with virtual memory, allocation, paging, threading etc. in the OS and in all installed programs/services?
    – Lunatik
    May 6 '16 at 15:01
  • Re your update, simply because hardware masks a genuine problem means we should pretend it has gone away? Odd view, especially when SSD life could in theory be impacted by excess thrashing that a user wouldn't really be aware of until the disk dies.
    – Lunatik
    May 6 '16 at 15:03
  • 1
    Also, thrashing isn't simply about fragmentation but cache and page misses.
    – Lunatik
    May 6 '16 at 15:05
  • Although this can happen in modern operating systems, it is far less common than in older OSes. There are multiple software applications that can monitor for high virtual memory or disk use. Really, this "condition" is caused more commonly by insufficient hardware resources these days, and far less rarely a runaway process. And I don't know what kind of hard drives you have, but it's probably been close to 10 years since I've had a hard drive you could audibly hear disk thrashing in without putting my head right next to it.
    – acejavelin
    May 6 '16 at 15:06
  • @Ramhound No gap. I don't doubt the ability of an SSD to retrieve or write a file much more quickly than a HDD (not 'instantly', in fact nowhere close), but the fact that it might be happening at all is sometimes, not always, a cause for concern.
    – Lunatik
    May 6 '16 at 15:16
1

Things to consider when switching to an SSD:

While "thrashing" isn't a problem with SSDs you do need to configure your system to get the best performance out of it.

  1. Enable AHCI (Advanced Host Controller Interface) This is normally available in the BIOS menu, It will allow your system to use most of the feature available in your SSD

  2. Enable TRIM

you will need to open command prompt to do this. Go to start type cmd and hit enter. Then in command prompt type fsutil behavior set disabledeletenotify 0

  1. Disable Indexing

Indexing is unnecessary seeing as SSDs are so fast that you don't get any gain from using it

To do this go to computer, right-click your SSD, and click Properties. De-select the box that says “Allow files to have contents indexed in addition to file properties” and click ok

  1. Disable Scheduled Defragmentation

SSDs don't really need to be defraged again because there is no gain.

to do this go to Start menu, click “Accessories,” click “System Tools,” and then click “Disk Defragmenter.” Click “Configure schedule,” and uncheck the box that says “Run on a schedule.”

(in windows 10 go to start type defragment hit enter select the SSD from the list click "change settings" and uncheck "Run on a schedule"

  1. Remove The Page File

To do this Right-click “Computer” in the Start menu and click “Properties.” Click “Advanced system settings” on the top left-hand side of the window and access the “Advanced” tab. Click “Settings” under “Performance.”

Then

Click the “Advanced” tab and click “Change.” and you should see the option in there

  1. Disable Hibernation

Go to start type cmd, hit enter then type powercfg -h off and hit enter

  1. Disable Prefetch and Superfetch

Go to start type regedit hit enter go to HKEY_LOCAL_MACHINE\CurrentControlSet\Control\SessionManager\Memory Management\PrefetchParameters

and set the options for Prefetch and Superfetch to 0

  1. Configure Write Caching

User level write caching can have a detrimental effect on the drive.

right-click “Computer” and click "Properties" then click “Device manager,” expand “Disk Drives,” right-click your SSD, and click “Properties.” Select the “Policies” tab. In this tab, you’ll see an option labeled “Enable write caching on the device.” uncheck it and click ok

  1. Disable Services for Windows Search and Superfetch

Press “Win+R” on your keyboard, type “services.msc,” and press “Enter.” Find both services mentioned in the title of this section and disable them.

  1. Disable ClearPageFileAtShutdown and LargeSystemCache

We no longer need them because we disabled the pagefile

Go back to Regedit and locate HKEY_LOCAL_MACHINE\CurrentControlSet\Control\SessionManager\Memory Management and set those options to 0

  1. Set the “High Performance” Power Option

open start type control panel find "power options" and slect "High Performance"

This should just about cover it

1
  • Defragging an SSD will shorten its life.
    – Andrew
    Jun 28 '18 at 17:13
1

Probably the best way is to use performance counters:

https://blogs.technet.microsoft.com/askperf/2008/06/10/the-basics-of-page-faults/

1

How to detect thrashing on an SSD-equipped system? [on Windows]

The tool you want to use is Resource Monitor.

Resource Monitor has a "Disk" tab that basically shows you the "disk bandwidth" being consumed. If it's maxed out at 100%, you can look at the processes that are using the most and investigate. SSDs are so fast that you may not notice a performance impact unless trying to do something else storage-intensive, but you can still see what is going on from this tool.

Resource Monitor is accessible via Start Menu or a button in the Task Manager.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.