Some linux dual/multi-boot tutorials / general partitioning tutorials say that the inner side of a hard disk is faster than the outer side so partitions towards the outside tend to be slower while some say that the exact opposite is true.
Which side is actually faster?
Is the difference noticeable?
How are the partitions physically placed on the disk as compared to the partition listing order-for example gparted shows a logical ribbon layout of the partitions. Are the partitions shown to the left side of this ribbon near the outer or inner edge of the disk physically?
Are there software benchmarks like testing some disk intensive stuff for the first time on identical vanilla installs of the same OS but on different partitions, inner and outer?
EDIT: Links
http://www.dedoimedo.com/computers/dual-boot-windows-7-ubuntu.html ctrl + f for "slower" on this page
Does the order of partitions matter? Says outer side is faster
http://www.pcworld.com/article/255224/how_to_partition_your_hard_drive_to_optimize_performance.html Says inner side is faster
http://partition.radified.com/partitioning_2.htm Says outer side is faster(not about dual-booting)
Answer
Which side is actually faster?
The entire HDD platter assembly rotates at a fixed RPM, so the angular velocity is constant.
The average rotational latency will be the same in all cases, since the angular velocity is the same in all cases.
The outer cylinders have faster linear velocity.
Without zone recording, reading a sector on an outer track would be same as an inner track.
With zone recording (as used on probably all new HDDs), reading a sector on an outer track would be "faster" (not slower) than an inner track.
You seem to be misreading these tutorials. Links #1 and #3 clearly state that reads at the outer cylinders can be faster than the inner cylinders.
In link #1 the "end of the disk" refers to the innermost cylinders.
In link #3 the "early part of the test" refers to starting at cylinder 0, which is the outermost cylinder.
There are no inconsistencies or contradictions on this topic among any of the four links you have provided.
Note that optical discs (e.g. CDs, DVDs) are different from HDDs.
Optical discs use a spiral track (per usable side) that starts on the inside and spirals outward.
HDDs employ concentric circular tracks on each surface. Multiple surfaces have tracks that are organized into cylinders. The outermost cylinder is always numbered #0.
Is the difference noticeable?
That depends on what you're doing.
Since the days of 14" platters, then 8", 5.25" and 3.5", the ratio in track length between the outermost and innermost seems to never exceeded 2:1. A practical reason for not exceeding this ratio could be that more cylinders increases the maximum and average seek times.
Modern drives that employ zoned recording take advantage of the larger quantity of magnetic domains (and faster linear velocity) of the longer track lengths of the outer cylinders. By allocating sectors in each zone to a fixed number of magnetic domains, sectors use a consistent length of track per zone. Since there will be more sectors per track on the outer cylinders, the data transfer rate on these cylinders is now faster than the inner cylinders.
The data rate on the outermost cylinder could be twice as fast as the innermost cylinder. On average you might get a 50% faster data rate on an outer cylinder compared to an inner cylinder.
But this performance benefit is only on the data transfer between the R/W head and the platter. This one data transfer of the sector is only one transfer among several operations that will occur in order to satisfy a read or write request by the OS.
To read data in a random sector the steps that will occur are:
- The OS will construct an ATAPI read request that is transmitted over the SATA bus.
- The HDD receives the request and processes the command.
- A seek is initiated to the the proper cylinder (this delay is called seek time and can consume 10s of milliseconds).
- Once at the correct cylinder, the correct R/W head is selected, and a search for the proper sector is initiated.
- On average the search for the proper sector takes about a half revolution of the platter (this delay is aka rotational latency).
- Once the proper sector is found, the actual sector data is read into a sector buffer (usually SRAM) (this is the only operation that is affected by the outside versus inside location).
- After the entire sector has been read, the data is validated and possibly corrected using the ECC by the onboard controller. The sector data can then be transmitted to the PC over the SATA bus.
- The OS receives the data.
Now that is for just one sector.
For an idea of the numerous disk requests/operations to copy files, see this answer
On sequential reads that do not require a seek operation, then the time for R/W of the platter becomes a more prominent item in the total time to perform a disk access. How well you can perceive a reduction of a few microseconds is questionable.
How are the partitions physically placed on the disk as compared to the partition listing order-for example gparted shows a logical ribbon layout of the partitions. Are the partitions shown to the left side of this ribbon near the outer or inner edge of the disk physically?
Usually the first sector (cylinder 0, head 0, sector 0) is placed on the left side of these representations. The graph or bar represents the numerical ordering of sectors, which increments the sector number fastest, then the head number (for track number), and then the cylinder number. This progression travels from the outermost cylinder to the innermost cylinder.
A partition shown on the left side would probably be actually located on the outer cylinders. GParted has property boxes that provide the actual disk addresses (by sector numbers) to verify these relationships.
Are there software benchmarks like testing some disk intensive stuff for the first time on identical vanilla installs of the same OS but on different partitions, inner and outer?
I have no idea.
No comments:
Post a Comment