Inexpensive SSD for SLOG Device?

Notice: Page may contain affiliate links for which we may earn a small commission through services like Amazon Affiliates or Skimlinks.

eroji

Active Member
Dec 1, 2015
276
52
28
40
Looking to updating my secondary FreeNAS server that is currently hosting a couple VMs via iSCSI but has not SLOG device. I had turned off the sync write on the dataset to ensure speedy performance but ultimately I want to find something cheap (yet fast) as SLOG device and add it to the volume. I seen some posts in the deals section for retired enterprise PCIe SSDs that may do the trick but I'm hoping to get some suggestions before I pull the trigger.
 

cperalt1

Active Member
Feb 23, 2015
180
55
28
43
First Question is what is your Pool composed of, spinners, SSDs? Also what speed are you trying to target? Network Speed? Choices would be trusty S3700, NVME drive, etc...
 

T_Minus

Build. Break. Fix. Repeat
Feb 15, 2015
7,625
2,043
113
S3700
S3710
HGST HUSML
HGST HUSSL
Fusion-IO SLC
Fusion-IO MLC
Fusion IO-Drive 2
ZeusRAM
 

eroji

Active Member
Dec 1, 2015
276
52
28
40
It's currently 12 7200 RPM drives in stripe+mirror. I plan to eventually grow it to 24.

Sent from my Pixel using Tapatalk
 

BackupProphet

Well-Known Member
Jul 2, 2014
1,083
640
113
Stavanger, Norway
olavgg.com
A fast slog needs to fast write sync performance.

This is what I get with:

Intel S3710 400gb
olav@olav-MS-7817:~$ sudo /usr/lib/postgresql/9.5/bin/pg_test_fsync -f /mnt/testdisk/testfile
5 seconds per test
O_DIRECT supported on this platform for open_datasync and open_sync.

Compare file sync methods using one 8kB write:
(in wal_sync_method preference order, except fdatasync is Linux's default)
open_datasync 6526.556 ops/sec 153 usecs/op
fdatasync 6423.496 ops/sec 156 usecs/op
fsync 6349.335 ops/sec 157 usecs/op
fsync_writethrough n/a
open_sync 6388.924 ops/sec 157 usecs/op

Compare file sync methods using two 8kB writes:
(in wal_sync_method preference order, except fdatasync is Linux's default)
open_datasync 3256.142 ops/sec 307 usecs/op
fdatasync 3540.772 ops/sec 282 usecs/op
fsync 3463.122 ops/sec 289 usecs/op
fsync_writethrough n/a
open_sync 3157.743 ops/sec 317 usecs/op

Compare open_sync with different write sizes:
(This is designed to compare the cost of writing 16kB in different write
open_sync sizes.)
1 * 16kB open_sync write 3474.978 ops/sec 288 usecs/op
2 * 8kB open_sync writes 3161.509 ops/sec 316 usecs/op
4 * 4kB open_sync writes 2522.673 ops/sec 396 usecs/op
8 * 2kB open_sync writes 116.569 ops/sec 8579 usecs/op
16 * 1kB open_sync writes 55.359 ops/sec 18064 usecs/op

Test if fsync on non-write file descriptor is honored:
(If the times are similar, fsync() can sync data written on a different
descriptor.)
write, fsync, close 6288.686 ops/sec 159 usecs/op
write, close, fsync 6267.458 ops/sec 160 usecs/op

Non-sync'ed 8kB writes:
write 630383.644 ops/sec 2 usecs/op
Intel 320 80gb
olav@olav-MS-7817:~$ sudo /usr/lib/postgresql/9.5/bin/pg_test_fsync -f /mnt/testdisk/testfile
5 seconds per test
O_DIRECT supported on this platform for open_datasync and open_sync.

Compare file sync methods using one 8kB write:
(in wal_sync_method preference order, except fdatasync is Linux's default)
open_datasync 7536.101 ops/sec 133 usecs/op
fdatasync 7689.040 ops/sec 130 usecs/op
fsync 6983.023 ops/sec 143 usecs/op
fsync_writethrough n/a
open_sync 7053.565 ops/sec 142 usecs/op

Compare file sync methods using two 8kB writes:
(in wal_sync_method preference order, except fdatasync is Linux's default)
open_datasync 3829.058 ops/sec 261 usecs/op
fdatasync 5226.290 ops/sec 191 usecs/op
fsync 4606.950 ops/sec 217 usecs/op
fsync_writethrough n/a
open_sync 3532.281 ops/sec 283 usecs/op

Compare open_sync with different write sizes:
(This is designed to compare the cost of writing 16kB in different write
open_sync sizes.)
1 * 16kB open_sync write 4602.549 ops/sec 217 usecs/op
2 * 8kB open_sync writes 3542.094 ops/sec 282 usecs/op
4 * 4kB open_sync writes 2146.523 ops/sec 466 usecs/op
8 * 2kB open_sync writes 1165.538 ops/sec 858 usecs/op
16 * 1kB open_sync writes 603.864 ops/sec 1656 usecs/op

Test if fsync on non-write file descriptor is honored:
(If the times are similar, fsync() can sync data written on a different
descriptor.)
write, fsync, close 6721.514 ops/sec 149 usecs/op
write, close, fsync 6663.931 ops/sec 150 usecs/op

Non-sync'ed 8kB writes:
write 621169.579 ops/sec 2 usecs/op
Micron 500DC
olav@olav-MS-7817:~$ sudo /usr/lib/postgresql/9.5/bin/pg_test_fsync -f /mnt/testdisk/testfile
5 seconds per test
O_DIRECT supported on this platform for open_datasync and open_sync.

Compare file sync methods using one 8kB write:
(in wal_sync_method preference order, except fdatasync is Linux's default)
open_datasync 10927.203 ops/sec 92 usecs/op
fdatasync 10677.827 ops/sec 94 usecs/op
fsync 10111.280 ops/sec 99 usecs/op
fsync_writethrough n/a
open_sync 10354.950 ops/sec 97 usecs/op

Compare file sync methods using two 8kB writes:
(in wal_sync_method preference order, except fdatasync is Linux's default)
open_datasync 5494.180 ops/sec 182 usecs/op
fdatasync 7756.420 ops/sec 129 usecs/op
fsync 7499.449 ops/sec 133 usecs/op
fsync_writethrough n/a
open_sync 5200.128 ops/sec 192 usecs/op

Compare open_sync with different write sizes:
(This is designed to compare the cost of writing 16kB in different write
open_sync sizes.)
1 * 16kB open_sync write 7742.726 ops/sec 129 usecs/op
2 * 8kB open_sync writes 5198.035 ops/sec 192 usecs/op
4 * 4kB open_sync writes 3081.131 ops/sec 325 usecs/op
8 * 2kB open_sync writes 923.314 ops/sec 1083 usecs/op
16 * 1kB open_sync writes 458.814 ops/sec 2180 usecs/op

Test if fsync on non-write file descriptor is honored:
(If the times are similar, fsync() can sync data written on a different
descriptor.)
write, fsync, close 9979.190 ops/sec 100 usecs/op
write, close, fsync 9978.986 ops/sec 100 usecs/op

Non-sync'ed 8kB writes:
write 637686.835 ops/sec 2 usecs/op
 

T_Minus

Build. Break. Fix. Repeat
Feb 15, 2015
7,625
2,043
113
A SLOG device should have all of these:
- High Write IOPs (low QD performance too)
- Low Write Latency
- Power Loss Protection
- Endurance
 

ruffy91

Member
Oct 6, 2012
71
11
8
Switzerland
I tought 3D Xpoint is like sram and doesn't need PLP, as all writes are directly to the Memory and there is no cache and no wear levelling.
 

eroji

Active Member
Dec 1, 2015
276
52
28
40
I tought 3D Xpoint is like sram and doesn't need PLP, as all writes are directly to the Memory and there is no cache and no wear levelling.
You may be right. Honestly I haven't read much into the technical details as I never expected Optane to be released in a non-enterprise/affordable form until years down the line.
 

Patriot

Moderator
Apr 18, 2011
1,450
789
113
It would be good for 1gbps, probably not as good as a p3700 for 10gbps though.
 

newabc

Active Member
Jan 20, 2019
465
243
43
Optane 32gb for caching a RAID1 SATA SSD pair is pretty slow on random write bandwidth. I am thinking to change it to a P3700 to gain some speed.