CAM-ATA
意外に、さらっとできた。GPT-ZFSのみなので、fstabをいじる必要もないし。
config作成
こんな感じで。
# cat /sys/i386/conf/CAMATA include GENERIC ident CAMATA nomakeoptions DEBUG nooptions INVARIANTS nooptions INVARIANT_SUPPORT nooptions WITNESS nooptions WITNESS_SKIPSPIN options KVA_PAGES=512 options PANIC_REBOOT_WAIT_TIME=16 # ATA and ATAPI devices nodevice ata nodevice atadisk # ATA disk drives nodevice ataraid # ATA RAID drives nodevice atapicd # ATAPI CDROM drives nodevice atapifd # ATAPI floppy drives nodevice atapist # ATAPI tape drives nooptions ATA_STATIC_ID # Static device numbering device ahci device mvs device siis options ATA_CAM # Modular ATA device atacore # Core ATA functionality #device atacard # CARDBUS support #device atabus # PC98 cbus support #device ataisa # ISA bus support device atapci # PCI bus support; only generic chipset support # PCI ATA chipsets device ataahci # AHCI SATA device ataacard # ACARD device ataacerlabs # Acer Labs Inc. (ALI) device ataadaptec # Adaptec device ataamd # American Micro Devices (AMD) device ataati # ATI device atacenatek # Cenatek device atacypress # Cypress device atacyrix # Cyrix device atahighpoint # HighPoint device ataintel # Intel device ataite # Integrated Technology Inc. (ITE) device atajmicron # JMicron device atamarvell # Marvell device atamicron # Micron device atanational # National device atanetcell # NetCell device atanvidia # nVidia device atapromise # Promise device ataserverworks # ServerWorks device atasiliconimage # Silicon Image Inc. (SiI) (formerly CMD) device atasis # Silicon Integrated Systems Corp.(SiS) device atavia # VIA Technologies Inc.
buildkernel&reboot
通常通りに。
# cd /usr/src # make buildkernel KERNCONF=CAMATA # make installkernel KERNCONF=CAMATA # shutdown -r now
reboot後
どっかでsingle user modeに落ちるかなあと思って見てたけど、特に何も起きず。。。
adがadaに変わったくらい。
atapci0: <Intel ICH7 UDMA100 controller> port 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0x2090-0x209f irq 18 at device 31.1 on pci0 ata0: <ATA channel 0> on atapci0 ata0: [ITHREAD] atapci1: <Intel ICH7 SATA300 controller> port 0x20a8-0x20af,0x20cc-0x20cf,0x20a0-0x20a7,0x20c8-0x20cb,0x2080-0x208f irq 19 at device 31.2 on pci0 atapci1: [ITHREAD] ata2: <ATA channel 0> on atapci1 ata2: [ITHREAD] ata3: <ATA channel 1> on atapci1 ata3: [ITHREAD] ada0 at ata2 bus 0 scbus1 target 0 lun 0 ada0: <WDC WD20EARS-00S8B1 80.00A80> ATA-8 SATA 2.x device ada0: 150.000MB/s transfers (SATA, UDMA5, PIO 8192bytes) ada0: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C) ada1 at ata3 bus 0 scbus2 target 0 lun 0 ada1: <WDC WD20EARS-00S8B1 80.00A80> ATA-8 SATA 2.x device ada1: 150.000MB/s transfers (SATA, UDMA5, PIO 8192bytes) ada1: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
やっぱり512 byte sectorなのか。。。
デバイス名が変わって、zpoolの結果が面倒なことに。
$ zpool status pool: pool1 state: ONLINE status: The pool is formatted using an older on-disk format. The pool can still be used, but some features are unavailable. action: Upgrade the pool using 'zpool upgrade'. Once this is done, the pool will no longer be accessible on older software versions. scrub: none requested config: NAME STATE READ WRITE CKSUM pool1 ONLINE 0 0 0 mirror ONLINE 0 0 0 gptid/05a6235c-6f71-11df-9275-001cc070e776 ONLINE 0 0 0 gptid/18c22c5c-7032-11df-8f20-001cc070e776 ONLINE 0 0 0 errors: No known data errors
逆にいえば、デバイス名が変わっても、GPTのID(?)をもとにちゃんと使えてるので、なんというか便利だ。labelが付け直せるかは、あとで調べる。
camcontrol
結果はこのような。
# camcontrol identify 1:0:0 pass0: <WDC WD20EARS-00S8B1 80.00A80> ATA-8 SATA 2.x device pass0: 150.000MB/s transfers (SATA, UDMA5, PIO 8192bytes) protocol ATA/ATAPI-8 SATA 2.x device model WDC WD20EARS-00S8B1 firmware revision 80.00A80 serial number WD-xxxxxxxxxxxx WWN xxxxxxxxxxxxxxxx cylinders 16383 heads 16 sectors/track 63 sector size logical 512, physical 512, offset 0 LBA supported 268435455 sectors LBA48 supported 3907029168 sectors PIO supported PIO4 DMA supported WDMA2 UDMA6 Feature Support Enable Value Vendor read ahead yes yes write cache yes yes flush cache yes yes overlap no Tagged Command Queuing (TCQ) no no Native Command Queuing (NCQ) yes 32 tags SMART yes yes microcode download yes yes security yes no power management yes yes advanced power management no no 0/0x00 automatic acoustic management yes no 254/0xFE 128/0x80 media status notification no no power-up in Standby yes no write-read-verify no no 0/0x0 unload no no free-fall no no data set management (TRIM) no
sector sizeの、physicalが4096になるのを期待したんだけど、ダメかー。まあ、なったところで何かが変わるかというと分からんが、少なくともここで4096にならなければ、変わらんわなあ。
150MB/s transferっていうのもなあ。ICH7がさぼってるのか。DMA supportedはUDMA6まであるのに、pass0はUDMA5とおっしゃっている、そういうものなのか?