July 17, 2025Jul 17 Is it somehow possible in Unraid to put ZFS SLOG and L2ARC on the same SSD (Optane P1600x 118GB).I am using it as just a SLOG rn and it's barely using any space.I believe this is possible on TrueNas but not sure if possible to do this on Unraid.My workload involves a lot of Databases so need the SLOG. Adding the SLOG makes almost a 10x difference.I have also maxed out my RAM for the ARC. Edited July 17, 2025Jul 17 by seamon
July 17, 2025Jul 17 Author Solution Okay I figured out a dirty way to do this.Follow this guide to partition your Optane Drive into 2 Partition (I did 10GB for SLOG and 100GB for L2ARC).SLOG is /dev/nvme0n1p1 and L2ARC is /dev/nvme0n1p2You can't start the array with SLOG and L2ARC enabled, they have to be added after array is started so I created a User Script that runs at Array Startup.zfs set compression=lz4 cache #zfs compression gets sets to on instead of lz4, this step is optionalzpool add cache log /dev/nvme0n1p1zpool add cache cache /dev/nvme0n1p2At Array Shutdown, the vdevs have to be removed.zpool import cache #if unraid was improperly shutdown, this script will instead import the zpool, remove and support vdevs and then you have to restart unraid again to make this work.zpool remove cache /dev/nvme0n1p1zpool remove cache /dev/nvme0n1p2Any help in refining this further would be appreciated. Edited July 17, 2025Jul 17 by seamon
July 17, 2025Jul 17 Community Expert Unraid is entirely based on "one thing per drive" so you'll likely have to stick with that.
July 17, 2025Jul 17 Author 43 minutes ago, Kilrah said:Unraid is entirely based on "one thing per drive" so you'll likely have to stick with that.But my solution works!
July 18, 2025Jul 18 Community Expert 11 hours ago, seamon said:But my solution works!Yes, but I would not expect Unraid to ever support that configuration via the GUI so you will have to keep your script without a way to 'tidy' up.
July 18, 2025Jul 18 Author 4 hours ago, itimpi said:Yes, but I would not expect Unraid to ever support that configuration via the GUI so you will have to keep your script without a way to 'tidy' up.I feel like that's Unraid in a nutshell with regard to a lot of other things over the years.
July 18, 2025Jul 18 12 minutes ago, seamon said:I feel like that's Unraid in a nutshell with regard to a lot of other things over the years.Well you've got a niche setup, that calls for a niche solution. ;-)
July 25, 2025Jul 25 Author I improved the scripts a little bit more:On Array Startupls /mnt/cacheif [ $? -ne 0 ]then echo "ERROR: Unsafe Shutdown detected!" zpool import cache sleep 15s zpool remove cache /dev/nvme0n1p1 zpool remove cache /dev/nvme0n1p2 shutdown -r nowelse echo "All operations normal!" zfs set compression=lz4 cache zpool add cache log /dev/nvme0n1p1 zpool add cache cache /dev/nvme0n1p2fiOn Array shutdownzpool remove cache /dev/nvme0n1p1zpool remove cache /dev/nvme0n1p2Also, note that each time a log device is removed from a zpool, it leaves a hole vdev in its place. This can be viewed with 'zdb -C'. This apparently is normal behavior for ZFS and completely harmless. It's just tracking vdev removals. Edited July 25, 2025Jul 25 by seamon
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.