What is TrueNAS writing all the time to disk?
from acockworkorange@mander.xyz to selfhosted@lemmy.world on 03 May 12:11
https://mander.xyz/post/12602020

I have a TrueNAS install with SMB turned on and nothing else. Even when it’s idle and nothing is accessing it, there’s constant disk activity. Very low bandwidth, but it’s like some log is in verbose mode.

TrueNAS is installed in a NVMe disk with plenty of room, and there’s only one pool. I’ve checked my snapshot configuration, nothing enabled faster than daily.

What could be causing it? How do I stop it or redirect it to the NVMe drive? I’m willing to create a partition on the NVMe drive if that’s what will do it.

Edit: thanks everyone for all the feedback, I’ll try these out and report back.

#selfhosted

threaded - newest

friend_of_satan@lemmy.world on 03 May 12:19 next collapse

Have you run lsof? See also: www.brendangregg.com/linuxperf.html

JASN_DE@lemmy.world on 03 May 12:30 next collapse

That’s most likely the syslog. Check the settings, you can choose the volume to use for it.

catloaf@lemm.ee on 03 May 14:08 collapse

Or set up a ramdisk, or turn off log to disk entirely somehow. But if you do that, you’ll lose logs between reboots or crashes, making troubleshooting harder.

Darkassassin07@lemmy.ca on 03 May 13:40 next collapse

Dirty secrets about you.

<img alt="" src="https://lemmy.ca/pictrs/image/aa177e27-1dfe-4849-9ebf-01f3d87104c6.jpeg">

tinsuke@lemmy.world on 03 May 17:00 next collapse

Every 4-5 seconds? Yeah, logging.

You can either move the system dataset to your boot drive/pool or syslog to /var/log:

www.truenas.com/docs/…/settingthesystemdataset/

I’ve seem many users recommend a reboot after changing those settings.

pyrosis@lemmy.world on 03 May 17:55 next collapse

Probably these directories…

/tmp /var/tmp /var/log

Two are easy to migrate to tmpfs if you are trying to reduce disk writes. Logs can be a little tricky because of the permissions. It is worth getting it right if you are concerned about all those little writes on an SSD. Especially if you have plenty of memory.

This is filesystem agnostic btw so the procedure can apply to other filesystems on Linux operating systems.

CondorWonder@lemmy.ca on 04 May 03:01 collapse

If it’s logs, there’s a package called log2ram - it’s designed for small form factor systems to reduce writes to SD cards but does apply anywhere you want to log but not hit disk immediately. It syncs logs to disk on a regular basis so you don’t lose much if the system crashes.

acockworkorange@mander.xyz on 04 May 04:48 collapse

Ooh that sounds promising, thank you!