# Adding an SSD to a zpool



## Kuzbad (May 22, 2014)

This is my second question, as I just asked one about proper benchmarking. I have a zpool to which I've added a SSD cache device (and followed instructions using gnop etc to do 4K alignment). This server is still running 8.4 and currently has 14gb GB of memory (just had one stick die). I will soon be adding 16gb GB more, for a total of 28gb GB. Is this the best possible use of the SSD? What about slog? Any suggestions?

Here's the `zpool status`:


```
xeon# zpool status
  pool: zroot
 state: ONLINE
  scan: scrub repaired 256K in 15h14m with 0 errors on Sat May 17 08:13:11 2014
config:

	NAME           STATE     READ WRITE CKSUM
	zroot          ONLINE       0     0     0
	  mirror-0     ONLINE       0     0     0
	    gpt/disk0  ONLINE       0     0     0
	    gpt/disk1  ONLINE       0     0     0
	  mirror-1     ONLINE       0     0     0
	    gpt/disk2  ONLINE       0     0     0
	    gpt/disk3  ONLINE       0     0     0
	cache
	  gpt/cache0   ONLINE       0     0     0

errors: No known data errors
```

disk2 and disk3 were added a year or so after the pool was created.  And dmesg:


```
ada0 at ahcich0 bus 0 scbus0 target 0 lun 0
ada0: <WDC WD2003FYYS-02W0B0 01.01D01> ATA-8 SATA 2.x device
ada0: 300.000MB/s transfers (SATA 2.x, UDMA6, PIO 8192bytes)
ada0: Command Queueing enabled
ada0: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada1 at ahcich1 bus 0 scbus1 target 0 lun 0
ada1: <WDC WD2003FYYS-02W0B0 01.01D01> ATA-8 SATA 2.x device
ada1: 300.000MB/s transfers (SATA 2.x, UDMA6, PIO 8192bytes)
ada1: Command Queueing enabled
ada1: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada2 at ahcich2 bus 0 scbus2 target 0 lun 0
ada2: <WDC WD2002FYPS-02W3B1 04.01G02> ATA-8 SATA 2.x device
ada2: 300.000MB/s transfers (SATA 2.x, UDMA6, PIO 8192bytes)
ada2: Command Queueing enabled
ada2: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada3 at ahcich3 bus 0 scbus3 target 0 lun 0
ada3: <WDC WD2002FYPS-02W3B1 04.01G02> ATA-8 SATA 2.x device
ada3: 300.000MB/s transfers (SATA 2.x, UDMA6, PIO 8192bytes)
ada3: Command Queueing enabled
ada3: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada4 at ahcich5 bus 0 scbus5 target 0 lun 0
ada4: <SanDisk SDSSDXP480G R1311> ATA-8 SATA 3.x device
ada4: 300.000MB/s transfers (SATA 2.x, UDMA6, PIO 512bytes)
ada4: Command Queueing enabled
ada4: 457862MB (937703088 512 byte sectors: 16H 63S/T 16383C)
```


----------



## kpa (May 23, 2014)

The standard question in this case is do you expect that there will be lots of synchronous writes on the pool? If you know that the applications you use are not using synchronous writes you'll get absolutely zero benefit from a separate slog device. One application that will use synchronous writes is NFS when it requests writing the updated data back to the real storage so if you're using NFS and the usage pattern is write-heavy you want to have a separate fast slog device.


----------

