不同的速度ssd分区


0

我有三星NVMe SSD 960EVO 250GB磁盘,当使用hdparm -tT测试读取速度时,它给我一些奇怪的结果。

修剪前加速

/dev/nvme0n1:
 Timing cached reads:   24486 MB in  2.00 seconds = 12256.70 MB/sec
 Timing buffered disk reads: 5502 MB in  3.00 seconds = 1832.95 MB/sec
jkalmar@supercomp:~> sudo hdparm -tT /dev/nvme0n1p1

/dev/nvme0n1p1:
 Timing cached reads:   24878 MB in  2.00 seconds = 12452.22 MB/sec
 Timing buffered disk reads: 190 MB in  0.09 seconds = 2151.12 MB/sec
jkalmar@supercomp:~> sudo hdparm -tT /dev/nvme0n1p2

/dev/nvme0n1p2:
 Timing cached reads:   24270 MB in  2.00 seconds = 12147.96 MB/sec
 Timing buffered disk reads: 5308 MB in  3.00 seconds = 1769.32 MB/sec
jkalmar@supercomp:~> sudo hdparm -tT /dev/nvme0n1p3

/dev/nvme0n1p3:
 Timing cached reads:   22976 MB in  2.00 seconds = 11499.27 MB/sec
 Timing buffered disk reads: 7140 MB in  3.00 seconds = 2379.80 MB/sec
jkalmar@supercomp:~> sudo hdparm -tT /dev/nvme0n1p4

/dev/nvme0n1p4:
 Timing cached reads:   23908 MB in  2.00 seconds = 11967.15 MB/sec
 Timing buffered disk reads: 7022 MB in  3.00 seconds = 2339.82 MB/sec

修剪后加速

jkalmar@supercomp:~> sudo hdparm -tT /dev/nvme0n1

/dev/nvme0n1:
 Timing cached reads:   25168 MB in  2.00 seconds = 12597.67 MB/sec                                                                                                                                               
 Timing buffered disk reads: 5548 MB in  3.00 seconds = 1848.97 MB/sec                                                                                                                                            
jkalmar@supercomp:~> sudo hdparm -tT /dev/nvme0n1p1

/dev/nvme0n1p1:                                                                                                                                                                                                   
 Timing cached reads:   25226 MB in  2.00 seconds = 12627.85 MB/sec                                                                                                                                               
 Timing buffered disk reads: 190 MB in  0.09 seconds = 2177.97 MB/sec                                                                                                                                             
jkalmar@supercomp:~> sudo hdparm -tT /dev/nvme0n1p2

/dev/nvme0n1p2:                                                                                                                                                                                                   
 Timing cached reads:   24356 MB in  2.00 seconds = 12191.47 MB/sec                                                                                                                                               
 Timing buffered disk reads: 5424 MB in  3.00 seconds = 1807.88 MB/sec                                                                                                                                            
jkalmar@supercomp:~> sudo hdparm -tT /dev/nvme0n1p3

/dev/nvme0n1p3:
 Timing cached reads:   24770 MB in  2.00 seconds = 12398.57 MB/sec
 Timing buffered disk reads: 7590 MB in  3.00 seconds = 2529.50 MB/sec
jkalmar@supercomp:~> sudo hdparm -tT /dev/nvme0n1p4

/dev/nvme0n1p4:
 Timing cached reads:   24532 MB in  2.00 seconds = 12279.30 MB/sec
 Timing buffered disk reads: 6960 MB in  3.00 seconds = 2319.36 MB/sec

您可以看到修剪有助于除了最后一个分区实际上更慢,但速度相当不错。不好的是第二次分区的速度。

挂载选项:

/dev/nvme0n1p1 on /boot/efi type vfat (rw,relatime,fmask=0002,dmask=0002,allow_utime=0020,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/dev/nvme0n1p2 on / type ext4 (rw,relatime,data=ordered)
/dev/nvme0n1p3 on /home type ext4 (rw,relatime,data=ordered)
/dev/nvme0n1p4 on /zaloha type ext4 (rw,relatime,data=ordered)

df -h

Filesystem      Size  Used Avail Use% Mounted on
/dev/nvme0n1p2   23G  8,1G   14G  38% /
/dev/nvme0n1p1  188M  4,6M  183M   3% /boot/efi
/dev/nvme0n1p3  110G   27G   82G  25% /home
/dev/nvme0n1p4   82G   16G   65G  20% /zaloha

智能数据

=== START OF SMART DATA SECTION ===
SMART/Health Information (NVMe Log 0x02, NSID 0xffffffff)
Critical Warning:                   0x00
Temperature:                        34 Celsius
Available Spare:                    100%
Available Spare Threshold:          10%
Percentage Used:                    0%
Data Units Read:                    1 168 294 [598 GB]
Data Units Written:                 470 952 [241 GB]
Host Read Commands:                 6 529 515
Host Write Commands:                4 815 912
Controller Busy Time:               22
Power Cycles:                       63
Power On Hours:                     59
Unsafe Shutdowns:                   9
Media and Data Integrity Errors:    0
Error Information Log Entries:      0
Warning  Comp. Temperature Time:    0
Critical Comp. Temperature Time:    0
Temperature Sensor 1:               34 Celsius
Temperature Sensor 2:               35 Celsius

根据智能数据,您可以看到驱动器是全新的。

分手

(parted) print                                                           
Model: NVMe Device (nvme)
Disk /dev/nvme0n1: 488397168s
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start       End         Size        File system  Name  Flags
 1      2048s       391167s     389120s     fat32              boot, esp
 2      391168s     49219583s   48828416s   ext4
 3      49219584s   283594751s  234375168s  ext4
 4      283594752s  457674751s  174080000s  ext4

(parted) align-check optimal 1                                            
1 aligned
(parted) align-check optimal 2
2 aligned
(parted) align-check optimal 3
3 aligned
(parted) align-check optimal 4
4 aligned

一切看起来都不错,但分区2的速度比其他的慢。有没有人知道为什么以及如果可以修复它怎么解决?


1
man hdparm 说的 -t-T:“对于有意义的结果,此操作应在其他非活动系统上重复2-3次(没有其他活动进程)”。我可以看到你的 /dev/nvme0n1p2 安装为 /。我不知道它是否会干扰但是你可能应该从live CD启动并重复你的测试,没有安装任何分区。
Kamil Maciorowski

我做了几次重复测试,结果差异在~50MB / s但没有尝试卸载磁盘。我会尝试并报告。谢谢
Jan

所以我启动了systemrescuecd并在磁盘上运行hdparm -tT(它没有安装),结果是p2约为1780MB / s,但对于p1,p3和p4,它只有大约1950MB / s,所以实际上它比磁盘已安装
Jan
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.