Adding an NVMe Cache Drive and Logs Drive to the Same physical drive

UK SPEED

Member
Dec 23, 2023
62
1
8
Hello guys
I have a server with Micron 9400 NVMe drive, can I use the log and cache drive over the ZFS? also, can I use the same drive to create the log and cache from the same Nvme drive?
The scenario with 12TB of Micron 9400 in my head is

8TB as ZFS
2TB as cache (L2ARC) drive
2TB as a drive as a log (ZIL)


ALL this configuration on the same drive.
 
This is not at all Proxmox specific but an SLOG and L2ARC on the same drive is possible. Usually, you make sure that the redundancy for the SLOG is the same as the pool for which it buffers sync writes. Adding an SLOG and/or L2ARC for a pool that is on the same drive does not make any sense.
 
  • Like
Reactions: Kingneutron
So only add the logs?
I don't see how that follows from what I wrote. Or maybe I'm just misunderstanding the question? SLOG does not make sense on the same drive (as it only amplifies the writes). SLOG does not make much sense on a drive with PLP. SLOG usually does not help as much as a better drive (that has PLP) or a ZFS special device. Can you elaborate (or quote the part of my post to which your question refers)?
Do you have other suggestions if I have anther drive faster, M2 gen 5?
It's not clear to me what you are trying to achieve (and what drives your have), sorry. All of this is not specific to Proxmox and ZFS guides on the internet might also help.
 
Last edited:
I would like to add cache storage and logs, can I do that with the case above?
Sure you can do that. And you can do that in the way you proposed at the start of this thread. It will work. Please let me know if it improves performance (as I fear it will make it worse).
 
Last edited:
You CAN with the provision that you are sharing the bandwidth etc between the two purposes. If you need SLOG, you should really have 2 NVMe disks as having only 1 disk is a single point of failure. You can use NVMe namespaces to split the disk into 2 or more (for SLOG/L2ARC/special etc). Note that you don't really need 2TB of SLOG unless you have 2TB of RAM, the SLOG is only a copy of what is in RAM in case your system has a power failure, so at most make it equal to the amount of RAM you have. L2ARC can be larger than RAM, although each segment of L2ARC still does use a small bit of RAM for the pointer, so making a L2ARC too big has effects on the size of your ARC. In many workloads with sufficient (512GB+) RAM I have not seen the need for L2ARC, the hit ratio often being under 5%.
 
Last edited: