Does partitioning hard drives into a smaller partition than the actual size make it perform better objectively

hard drivepartitioning

I used to work on a 80gb HDD back in 2016 and it actually felt snappy most of the time. And after purchasing a new laptop with 1TB HDD and a much bigger ram and faster CPU – the HDD actually felt much slower than my old one although it was newer generation HDD (Not sure about the RPM speed).

So lately I've decided to partition my 1TB HDD into 80gb primary partition and leave the rest of the space unallocated since I don't really need anything beyond the OS and a main web browser.

After doing it – it actually felt much snappier than before for some reason. File manager runs so quickly and the overall performance of the HDD just feels much better. I want to know if it's just a placebo or it's a legit thing that has been going on before the SSD era.

I read something about "Disk short stroking" but I'm not sure if that's the same as what I did. Maybe my BIOs partitions space on the edges first? I want to know your explanations of this.

Best Answer

Yes, what you're doing is called "short-stroking".

It improves seek performance by limiting the drive's head movement. Hard drive performance is primarily limited by three factors: Seek time (the time it takes to move the heads in or out to the desired cylinder), rotational latency, and of course the actual data transfer rate.

principles

Most modern 3.5 inch hard drives have average seek times in the 9 to 10 msec range. Once a "seek" is done, then the drive has to wait for the start of the desired sector to come under the heads. The average rotational latency is simply half of the time it takes for the drive to turn one full revolution. A 7200 rpm drive, turns at 120 revs per second, so a rev takes 1/120 sec, so half a rev - the average rotational latency - is 1/240 sec, or 4.2 msec. (Note that this is the same for every 7200 rpm hard drive.) So we have an average of about 13 msec before we can start transferring data.

The data transfer rate is whatever the drive spec says. With modern drives this is almost always somewhat lower than what the physical interface, e.g. SATA 3, supports. Note that the data transfer portion of an I/O operation is generally the smallest-duration part, and with modern interfaces can almost be ignored. Even on an old ATA33 drive, transferring 4KiB only took 1.2 msec.

The seek time specification is an average of possible seek times for various head-movement distances. You can see how a seek from one cylinder to the adjacent cylinder would be much shorter than from the innermost to the outermost. (A "cylinder" is the collection of all of the tracks that are accessible from a single head position.) Both of those are atypical situations. The assumption in HD performance is that data being accessed will be fairly randomly distributed across the drive, so the usual quoted seek time of around 9 or 10 msec is an average of a number of different seek distances. On the most detailed spec sheets, some manufacturers list both the cylinder to cylinder (often labeled "track to track"), ie adjacent, seek time and the maximum (end to end) in addition to the average.

When you see drive benchmarks done with large "sequential" transfers you are seeing tests done with data access patterns that minimize both seek time and rotational latency, and maximize the effectiveness of the drive's onboard cache. i.e. reading a single large file sequentially - from start to finish - using reading e.g. 64 KiB at a time, with the file occupying one contiguous range of blocks.

so how does short-stroking work?

By creating - and only using - a partition much smaller than the drive, you are keeping all of your data in a narrow span of possible cylinders (head positions). This makes the maximum possible seek time smaller, so the average is smaller. It doesn't help the rotational latency or transfer rate.

Another way it helps is by keeping your usage of the drive to the largest-capacity cylinders. Modern HDs use "zone bit recording", meaning there are more sectors per track on the outer tracks than on the inner. So if the data's on outer cylinders, you can access more data without moving the heads as much .

does it really work?

A lot of different tech enthusiast sites have tested this. For example, see this article at Tom's Hardware. The results are impressive: Nearly doubling the I/O rate per second.

But this was done by buying a large hard drive and only using a small fraction of the drive's capacity. This radically increases your cost per GB.

However, there is a workaround. You don't have to never use the remainder of the drive to get the speed benefit. You just have to keep it out of everyday use when your system is hitting your main partition a lot. Most of us have a few files we access a lot (the OS, apps, and some data that the apps work on) and a much larger amount of data that we access not so much. For example, you could use the remainder of the drive for some sort of archival storage, or for multimedia files like music and video. Media playback is generally infrequent, sequential access to a single file and you're usually not doing much else with the machine at the time. So using the drive this way won't make media playback any worse than if everything was all spread across one big partition, and work that doesn't involve the media data should get the benefit of short-stroking.

but is a good idea?

On the other hand... The tests performed by TH were synthetic benchmarks, and to get those results they threw away very high percentages of the disk capacity. Modern operating systems do quite a bit of work to try to optimize HD performance. One example is Windows' "file placement optimization", which is described in the comments to this answer. And "short-stroking" will make this less effective. Just because someone got impressive results in a synthetic benchmark doesn't mean "short-stroking" is necessarily a good thing to do.

Think about it: A 1 TB hard drive these days costs about $50. But you're only using 80 GB of it. You say you only need the OS and a browser... well, for $63 you can get a Samsung 128 GB SSD, giving you half again the space of your 80 GB and FAR better performance no matter how far you "short-stroke" the HD. Or for $50 you can get a SanDisk SSD with 240 GB capacity. That seems like a better deal than not-using almost all of a $50 one-terabyte hard drive.

btw

btw: Your "BIOS" (or UEFI for that matter) does not create partitions and has nothing to do with where the partitions are. It's up to the operating system's partitioning utility. Every OS I've ever heard of uses the outer cylinders first. For example, in Windows' Disk Management utility, the graphical display of drive partitions within each disk shows the layout with the outermost cylinders on the left. The AOMEI disk partitioning utility does the same.

ASIDE - TRUE STORY: Back in the day when 5.25-inch form factor hard drives were sized in the tens and hundreds of MB, a company called CDC had a line of drives called the "Wren" series. (This name was no doubt a slap at the much-physically-larger Fujitsu "Eagle" drives of a slightly earlier era.) For a while they also had a slightly higher-performance model, the "WrenRunner". About 90% the capacity, 20% more cost, and a millisecond or so shaved off of the average access time. After some experiments it was clear that the "WrenRunner" was just a "Wren" with the first and last few tracks locked out in the drive's firmware. i.e. you could get the same performance and capacity out of the cheaper Wren by "short stroking", though we didn't use that term then. A friend of mine was a distributor and made good karma with his customers by telling them "spend less money - just buy the Wren and don't use all of it!"

Related Question