我正在使用带有三星 840 EVO SSD 的 LSI 9211-8i SAS 适配器运行 Ubuntu 13.10。做一些性能测试时,我注意到写入速度显着下降,所以我一直试图让 TRIM 与这个适配器一起工作。SSD 支持 TRIM:
# hdparm -I /dev/sdc | grep "TRIM supported"
* Data Set Management TRIM supported (limit 8 blocks)
Run Code Online (Sandbox Code Playgroud)
如果我将 SSD 移动到具有不同控制器的另一个系统,运行 fstrim 并将它们移回该系统,则预期性能将恢复。
据 LSI 称,他们的发起者-目标 (IT) 固件支持trim。但是修剪支持不起作用:
# cat /sys/block/sdc/queue/discard_granularity
0
# fstrim /srv/node/disk2p1
fstrim: /srv/node/disk2p1: FITRIM ioctl failed: Operation not supported
Run Code Online (Sandbox Code Playgroud)
我没有为这些文件系统使用 LVM 或加密。我已经尝试过 xfs 和 ufs4 格式,但我打算使用 xfs。这是一个示例 fstab 行:
LABEL=disk2p1 /srv/node/disk2p1 xfs noatime,nodiratime,nobarrier,logbufs=8,discard 0 0
Run Code Online (Sandbox Code Playgroud)
对于控制器固件,我尝试了 LSI 的 P14、P16 和 P18(最新)固件。我还构建了 LSI 提供的 mpt2sas 驱动程序 P18,它需要一个小补丁来删除 __devexit,但编译并运行正常。我还尝试使用常用的 mpt2sas 驱动程序构建 Trusty 的每日快照。
以下是删除了时间的 mpt2sas dmesg 行:
mpt2sas version 18.00.00.00 loaded
mpt2sas0: 64 BIT PCI BUS DMA ADDRESSING SUPPORTED, total mem (16418600 kB)
mpt2sas0: _base_get_ioc_facts: IOC_STATE(0x22000000)
sd 3:0:0:0: [sda] 7815168 512-byte logical blocks: (4.00 GB/3.72 GiB)
sd 3:0:0:0: [sda] Write Protect is off
sd 3:0:0:0: [sda] Mode Sense: 43 00 00 00
sd 3:0:0:0: [sda] No Caching mode page found
sd 3:0:0:0: [sda] Assuming drive cache: write through
sd 3:0:0:0: [sda] No Caching mode page found
sd 3:0:0:0: [sda] Assuming drive cache: write through
sda: sda1
sd 3:0:0:0: [sda] No Caching mode page found
sd 3:0:0:0: [sda] Assuming drive cache: write through
sd 3:0:0:0: [sda] Attached SCSI removable disk
mpt2sas0: _base_get_ioc_facts: failed going to ready state (ioc_state=0x20000000)
mpt2sas0: MSI-X vectors supported: 1, no of cores: 16, max_msix_vectors: -1
mpt2sas 0000:04:00.0: irq 79 for MSI/MSI-X
mpt2sas0-msix0: PCI-MSI-X enabled: IRQ 79
mpt2sas0: iomem(0x00000000df2b0000), mapped(0xffffc90011c80000), size(65536)
mpt2sas0: ioport(0x000000000000fc00), size(256)
mpt2sas0: _base_get_ioc_facts: IOC_STATE(0x22000000)
mpt2sas0: _base_get_ioc_facts: failed going to ready state (ioc_state=0x20000000)
mpt2sas0: sending message unit reset !!
mpt2sas0: message unit reset: SUCCESS
mpt2sas0: Allocated physical memory: size(7445 kB)
mpt2sas0: Current Controller Queue Depth(3307), Max Controller Queue Depth(3432)
mpt2sas0: Scatter Gather Elements per IO(128)
mpt2sas0: overriding NVDATA EEDPTagMode setting
mpt2sas0: LSISAS2008: FWVersion(18.00.00.00), ChipRevision(0x03), BiosVersion(07.35.00.00)
mpt2sas0: Dell 6Gbps SAS HBA: Vendor(0x1000), Device(0x0072), SSVID(0x1028), SSDID(0x1F1C)
mpt2sas0: Protocol=(Initiator,Target), Capabilities=(TLR,EEDP,Snapshot Buffer,Diag Trace Buffer,Task Set Full,NCQ)
mpt2sas0: sending port enable !!
mpt2sas0: host_add: handle(0x0001), sas_addr(0x590b11c027281600), phys(8)
mpt2sas0: port enable: SUCCESS
sd 2:0:1:0: [sdc] 976773168 512-byte logical blocks: (500 GB/465 GiB)
sd 2:0:0:0: [sdb] 143374000 512-byte logical blocks: (73.4 GB/68.3 GiB)
sd 2:0:2:0: [sdd] 976773168 512-byte logical blocks: (500 GB/465 GiB)
sd 2:0:3:0: [sde] 976773168 512-byte logical blocks: (500 GB/465 GiB)
sd 2:0:4:0: [sdf] 976773168 512-byte logical blocks: (500 GB/465 GiB)
sd 2:0:0:0: [sdb] Write Protect is off
sd 2:0:0:0: [sdb] Mode Sense: d7 00 00 08
sd 2:0:5:0: [sdg] 976773168 512-byte logical blocks: (500 GB/465 GiB)
sd 2:0:0:0: [sdb] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
sd 2:0:1:0: [sdc] Write Protect is off
sd 2:0:1:0: [sdc] Mode Sense: 7f 00 10 08
sd 2:0:1:0: [sdc] Write cache: enabled, read cache: enabled, supports DPO and FUA
sd 2:0:2:0: [sdd] Write Protect is off
sd 2:0:2:0: [sdd] Mode Sense: 7f 00 10 08
sd 2:0:2:0: [sdd] Write cache: enabled, read cache: enabled, supports DPO and FUA
sd 2:0:3:0: [sde] Write Protect is off
sd 2:0:3:0: [sde] Mode Sense: 7f 00 10 08
sd 2:0:3:0: [sde] Write cache: enabled, read cache: enabled, supports DPO and FUA
sd 2:0:4:0: [sdf] Write Protect is off
sd 2:0:4:0: [sdf] Mode Sense: 7f 00 10 08
sd 2:0:4:0: [sdf] Write cache: enabled, read cache: enabled, supports DPO and FUA
sd 2:0:5:0: [sdg] Write Protect is off
sd 2:0:5:0: [sdg] Mode Sense: 7f 00 10 08
sd 2:0:5:0: [sdg] Write cache: enabled, read cache: enabled, supports DPO and FUA
Run Code Online (Sandbox Code Playgroud)
只是 mpt2sas 不支持 TRIM (SAS UNMAP) 吗?如果这个控制器不支持,有人可以为机架安装系统或 JBOD 推荐一个工作控制器吗?我需要在机架安装系统或 JBOD 中使用 8 - 16 个 SATA SSD(非 RAID 配置)以及支持 TRIM 的控制器。
| 归档时间: |
|
| 查看次数: |
4920 次 |
| 最近记录: |