首页 > 维修 > 硬盘 > 正文

ssd固态硬盘怎么分区合理!专家解答!

2022-04-16 19:18:58
字体:
来源:转载
供稿:网友

ssd固态硬盘怎么分区合理!专家来给您ssd固态硬盘合理分区解答!

  224 heads (32*7)
  56 sectors per track (8*7)

  这样每个柱面包含12544个扇区(256*49),每个磁道使用56个扇区,大小为56*512字节,即每磁道28762字节,这和每柱面4KB的7个块是一样的,因此每柱面4KB页面的数量是一个整数,这样任何分区

都是协调一致的,下面是如何实现这种效果的一个例子:

  [[email protected] ~]# fdisk -H 224 -S 56 /dev/sdd
  The number of cylinders for this disk is set to 9345.
  There is nothing wrong with that, but this is larger than 1024,
  and could in certain setups cause problems with:
  1) software that runs at boot time (e.g., old versions of LILO)
  2) booting and partitioning software from other OSs
  (e.g., dos FDISK, OS/2 FDISK)
  Command (m for help): n
  Command action
  e extended
  p primary partition (1-4)
  p
  Partition number (1-4): 1
  First cylinder (1-9345, default 1): 2
  Last cylinder or +size or +sizeM or +sizeK (2-9345, default 9345):
  Using default value 9345
  Command (m for help): w
  The partition table has been altered!
  Calling ioctl() to re-read partition table.
  Syncing disks.

  注意,我是从第二个柱面开始的,以保证分区/dev/sdd1从柱面边界开始。

  可以在fdisk后面跟上“-l”参数检查分区。

  [[email protected] ~]# fdisk -l /dev/sdd
  Disk /dev/sdd: 60.0 GB, 60022480896 bytes
  224 heads, 56 sectors/track, 9345 cylinders
  Units = cylinders of 12544 * 512 = 6422528 bytes
  Device Boot Start End Blocks Id System
  /dev/sdd1 2 9345 58605568 83 Linux

  我们也可以使用“-lu”参数查看扇区的数量。

  [[email protected] ~]# fdisk -lu /dev/sdd
  Disk /dev/sdd: 60.0 GB, 60022480896 bytes
  224 heads, 56 sectors/track, 9345 cylinders, total 117231408 sectors
  Units = sectors of 1 * 512 = 512 bytes
  Device Boot Start End Blocks Id System
  /dev/sdd1 12544 117223679 58605568 83 Linux

  分区从12544扇区(256*9)开始,在设备的末尾结束。

  在OCZ技术社区有人提供了另一种建议,使用的几何参数略有不同。

  32 heads
  32 sectors per track

  这样每柱面包含1024个扇区(32*32),512字节大小的扇区形成512KB的柱面(每柱面128个4KB页面),还是以/dev/sdd为例,这种几何划分法的命令如下:

  [[email protected] ~]# fdisk -H 32 -S 32 /dev/sdd
  The number of cylinders for this disk is set to 114483.
  There is nothing wrong with that, but this is larger than 1024,
  and could in certain setups cause problems with:
  1) software that runs at boot time (e.g., old versions of LILO)
  2) booting and partitioning software from other OSs
  (e.g., dos FDISK, OS/2 FDISK)
  Command (m for help): n
  Command action
  e extended
  p primary partition (1-4)
  p
  Partition number (1-4): 1
  First cylinder (1-114483, default 1): 2
  Last cylinder or +size or +sizeM or +sizeK (2-114483, default 114483):
  Using default value 114483
  Command (m for help): w
  The partition table has been altered!
  Calling ioctl() to re-read partition table.
  Syncing disks.

  Fdisk加上“-l”参数可以检查分区。

  [[email protected] ~]# fdisk -l /dev/sdd
  Disk /dev/sdd: 60.0 GB, 60022480896 bytes
  32 heads, 32 sectors/track, 114483 cylinders
  Units = cylinders of 1024 * 512 = 524288 bytes
  Device Boot Start End Blocks Id System
  /dev/sdd1 2 114483 58614784 83 Linux

  注意,这种几何划分方法的“单位”是512KB(524288字节),它比第一种方法的柱面数更多,我们可以使用fdisk –lu命令查看扇区布局。

  [[email protected] ~]# fdisk -lu /dev/sdd
  Disk /dev/sdd: 60.0 GB, 60022480896 bytes
  32 heads, 32 sectors/track, 114483 cylinders, total 117231408 sectors
  Units = sectors of 1 * 512 = 512 bytes
  Device Boot Start End Blocks Id System
  /dev/sdd1 1024 117230591 58614784 83 Linux

  注意,我们从扇区1024开始,使用512字节的扇区,意味着分区匹配512KB。

  哪种方式最好让SSD固态硬盘分区合理呢?晓龙编辑(www.VeVb.com)认为这取决于许多因素,特别是SSD的内部结构和固件工作原理,假如您不打算给你的SSD分区,如使用整个设备作为一个分区,

那么你不需要担心这些问题,但如果你打算分区,这两个方法你就得选择一个,最重要的一条原则是,确保分区和边界保持对齐,这样有助于发挥SSD的性能,并延长它的使用SSD固态硬盘的寿命。

 

发表评论 共有条评论
用户名: 密码:
验证码: 匿名发表