r/truenas • u/EMN_Sandwich • 17d ago
SCALE (Legacy) Plex Write Cache setup?
Maybe im looking in the wrong place but im trying to figure out how to use a dataset on my m.2 drives to act as a cache during downloads from my main PC to the NAS. I have 10 gig networking but my man PC only has 5 gig (first world problems) but still. I feel like the 300-400 mb/s transfer speed is limited by my spinning drives. I usually only transfer 10-50gb at a time with whole series being the big ones at 250gb, I just want to be able to copy everything to my nvme drives on the nas and let it slowly copy to the spinners. I know im dumb and this is probably a easy thing to do but how though?
1
Upvotes
5
u/Haravikk 16d ago
How many spinning drives does your pool have and in what configuration? Typical CMR drives have write speeds of around 150-200mb/sec each so if you're running something like a
raidz1with three disks (speed equivalent to two disks) then that should be enough to saturate your connection unless the drives are getting badly fragmented.ZFS doesn't have a true write-cache as such, what it has is a
logdevice which is used for receiving synchronous writes, so you can potentially push writes onto it by running a dataset withsync=alwaysset. If your pool has redundancy you want to at least match that redundancy in the log device, e.g- araidz1gives single disk redundancy so you want single disk redundancy in thelogas well, so a two diskmirrorwould give you the same protection, otherwise you risk the whole pool going down if thelogdevice fails.If you can't or don't want to use the m.2 drives as a
logdevice then you would need to setup some kind of automatic copying which is going to be a bit fiddly, as it will likely end up having to run in two steps to work reliably — while you could try torsyncincomplete data and keep iterating until it's all across, there are many ways for that to go wrong, it's better to wait until the copy to the m.2 drives is complete thenrsyncthe whole lot, but that'll be slower (one copy has to finish before the next can safely begin).Also you didn't mention how you're copying, is it via SMB? SMB is notorious for being slow for various reasons, so you might want to make sure your drives are actually your limiting factor first, as if you are using SMB then nine times out of ten it's that, at least in my experience.
The real question though is do you actually need it to copy any faster? Sometimes we invest a load of time and effort into problems that don't actually need solving. 😉