I. Category of disks
Disks can be divided into ATA (IDE), SATA, SCSI, SAS, and FC disks by interface type. According to the disk chip composition, it is divided into SSD and HDD. Because the mechanical hard disk is still the mainstream configuration, we call SAS, FC and SATA both refer to the mechanical hard disk.
The following is a brief introduction to Baidu Encyclopedia:
ATA,The full name is AdvancedTechnology Attachment. It uses a traditional 40-pin parallel port data cable to connect the motherboard and the hard disk. The interface speed is up to 133 MB/s, because the parallel line has poor anti-interference performance and occupies a large space, it is not conducive to the internal cooling of the computer and has been gradually replaced by SATA.
SATA,Serial ATA, that is, the use of Serial ATA interface, because of strong anti-interference, and the length of the data line is much lower than ATA, support hot swapping and other functions, SATA-II interface speed is 375 MB/s, the new SATA-III standard can reach 750 Mb/s transmission speed. SATA data lines are also much finer than ATA, which facilitates air circulation in the chassis and facilitates wire sorting.
SCSI,SmallComputer System Interface (Minicomputer System Interface), through multi-generation development, from the early SCSI-II, to the current Ultra320 SCSI and Fiber-Channel (Fiber Channel ), there are also a variety of interface types. SCSI hard disks are widely used on workstation-level personal computers and servers. Therefore, they use more advanced technologies, such as a high speed of 15000rpm of the disk speed and a low CPU usage during data transmission, however, the unit price is more expensive than ATA and SATA hard disks of the same capacity.
SAS(SerialAttached SCSI) is a new generation of SCSI technology. Similar to SATA hard disks, it adopts sequential technology to achieve higher transmission speeds, up to 6 Gb/s. In addition, the internal space of the system is also improved by narrowing down the connection lines.
In addition, because SAS hard disks can share the same Backplane with SATA hard disks, in the same SAS storage system, SATA hard disks can be used to replace some expensive SAS hard disks, saves overall storage costs. However, the SATA storage system cannot connect to the SAS hard disk.
FC(Fiber rechannel). Hard Disks with this interface have hot swapping, high-speed bandwidth (4 Gb/s or 10 Gb/s), and remote connection characteristics when using fiber connections; the internal transmission rate is also higher than that of an ordinary hard disk. Limited to its high price, usually used in the high-end server field.
SSD: a hard disk consisting of a control unit and a solid-state storage unit (DRAM or FLASH chip. The interface specifications, functions, and usage of SSD are the same as those of common hard disks, and the product shape and size are also the same as those of common hard disks. SSD is classified into two categories, one is FLASH memory (FLASH chip) as the storage medium, and the other is DRAM as the storage medium. SSD features good performance and high price
Ii. Physical Structure of a mechanical Disk
A disk is mainly used to read data from a disk by using a head on the disk arm. A disk consists of one or more disks (platters, they rotate around a spindle and the disk is organized into a track. The track is the concentric circle on a single disk, cylinder is composed of the cylinder with the same radius on all disks. Each track is divided into equal points by 512 bytes, which is called a sector (sector ), when reading and writing data to a disk, the unit is slice.
Iii. Disk Performance
The key factor affecting the disk is the disk service time, that is, the time the disk took to complete an I/O Request.TioIt consists of three parts: track time, rotation delay, and data transmission time.
1) Access time of the Disk)The time when the head finds the data access, which is the sum of the seek time (seek time) and the Rotationallatency (Rotationallatency.
A) Seek timeTa: Seek time refers to the time to move to the track where the data (sector) is located. The longest seek time is to move to the innermost (or outermost) sector, the minimum seek refers to moving to an adjacent sector. The average search time for a disk is 3 ~ 15 ms,
B) Rotation DelayTl: Disk rotation, which is the time required to move the data sector to the bottom of the track. The rotation delay time is related to the disk speed, which is usually expressed by 1/2 of the time required for disk rotation for one week. For example, the average rotation latency of a 7200 rpm disk is about 60*1000/7200/2 = 4.17 ms.
2) disk transmission timeTt: The time when data is transferred from the disk to the host interface, which is related to the interface and type when the host connects to the disk, and the disk transmission rate.
The following three indicators are used to measure the disk performance:
IOPS(Input/OutputPer Second): IO data that can be completed per Second. For OLTP systems, IOPS is the main indicator to measure IO performance.
Throughput(Throughput), measured in MBPS, the number of MB bytes transmitted per second, is often used to measure the IO performance of OLAP data blocks.
Response time: For processes on the host, the time required to complete an IO request is also called latency. Generally, the response time should be less than 20 ms.
The relationship between the three indicators is:IOPS = throughput/block_size, block_sizeIs the size of the data block
Take Seagate Savvio 2.5 "SAS 15 K rpm as an example. If the average time of the disk seeking is 2.9 ms and 15000 rpm, the rotation delay is 60*1000/15000/2 = 2 ms, the bandwidth of the disk interface is 151 MB/s. Assume that the data block size is 4 kb, the disk response time is 4.927 ms, the IOPS is 203, And the throughput is 0.812 MBPS (because it is a small random read, low Throughput)
Ta= 2.9 MS;Tl= 2.0 MS;Tt= 4/151 = 0.027 MS;Tio= 2.9 + 2.0 + 0.027 = 4.927 MS
IOPS= 1/4.927 = 203
Throughput: 203*4 K/1000 = 0.812 MBPS
Iv. Performance indicators for mainstream disks:
Test disk IOPS. Generally, small random reads are used. Below are some disk indicators.
Drive (Type/RPM) |
IOPS (4 kb block, random) [WintelGuy.com] |
IOPS [1] * |
IOPS [2] * |
IOPS [3] * |
FC/15 K |
163-178 |
175 |
150-190 |
|
SAS/15 K |
188-203 |
175 |
150-190 |
180 |
FC/10 K |
142-151 |
125 |
100-130 |
|
SAS/10 K |
142-151 |
125 |
100-130 |
140 |
SAS/SATA/7200 |
73-79 |
75 |
75-100 |
30-80 |
SATA/5400 |
57 |
50 |
|
|
SSD |
|
6000 |
|
|
Measure the throughput. Generally, big data blocks are read sequentially. The following are common disk indicators.
Drive (Type/RPM) |
MB/s (Large block, sequential) |
FC/15 K |
73.5-127.5 |
SAS/15 K |
91.5-126.3 |
FC/10 K |
58.1-107.2 |
SAS/10 K |
58.1-107.2 |
SAS/SATA/7200 |
43.4-97.8 |
References
Http://wintelguy.com/2013/20130406_disk_perf.html
Http://www.thomas-krenn.com/en/wiki/Linux_ I /O_Performance_Tests_using_dd
Http://www.sgidepot.co.uk/diskdata.html
Http://blog.csdn.net/tianlesoftware/article/details/6009110
Http://zh.wikipedia.org/wiki/%E7%A1%AC%E7%9B%98