TrueNAS: reliable storage for your homelab
Every homelab needs storage. You can get away with local drives on each machine for a while, but eventually you want a central place for files, backups, media, and VM storage. TrueNAS is the best free option I have found for this.
What TrueNAS is
TrueNAS is a free, open-source network-attached storage (NAS) operating system. You install it on a dedicated machine, add some drives, and it serves storage over the network via SMB, NFS, iSCSI, or S3. It is built on top of OpenZFS, which gives you features that consumer NAS devices from Synology or QNAP charge a premium for.
There are two versions: TrueNAS SCALE (Linux-based, supports Docker) and TrueNAS CORE (FreeBSD-based, more mature). I run SCALE because it can also run Docker containers directly on the NAS, which reduces the number of machines I need.
Why ZFS matters
ZFS is the reason TrueNAS exists. It is a filesystem that handles things other filesystems leave to you:
Data integrity. ZFS checksums every block of data. If a bit flips due to hardware issues (this happens more often than you think), ZFS detects and corrects it automatically. With a standard filesystem, you would never know your files were silently corrupted.
Snapshots. ZFS can take instant, space-efficient snapshots of your data. Accidentally deleted a file? Roll back to a snapshot from an hour ago. This has saved me multiple times.
RAID without a RAID card. ZFS handles redundancy in software. A mirror (equivalent to RAID 1) protects against a drive failure. RAIDZ (equivalent to RAID 5) gives you more usable space with one drive of redundancy. No hardware RAID controller needed.
Hardware recommendations
TrueNAS needs ECC RAM if you want the full benefit of ZFS data integrity. That said, non-ECC works fine for a homelab. Do not let the ECC requirement stop you from getting started.
For drives, use NAS-rated drives (WD Red Plus, Seagate IronWolf) for reliability. Desktop drives work but are not designed for 24/7 operation.
A minimum setup:
- Any x86 machine with 8GB+ RAM
- Two drives (mirrored for redundancy)
- A small SSD or USB drive for the boot OS
Setting it up
Download TrueNAS SCALE from the official site, flash it to a USB drive, and install it to a separate boot device (a small SSD or another USB drive). The installer is straightforward.
After installation, access the web UI at http://your-nas-ip. The first thing to do is create a storage pool:
- Go to Storage > Create Pool
- Select your drives
- Choose a layout (mirror for two drives, RAIDZ1 for three or more)
- Give it a name and create
Then create datasets (like folders with their own settings) and shares:
- Create a dataset under your pool (e.g.,
tank/documents,tank/backups) - Set up an SMB share pointing to the dataset
- Configure permissions for your user
Your NAS is now accessible from any machine on the network at \\your-nas-ip\share-name.
Snapshots and replication
Set up automatic snapshots under Data Protection > Periodic Snapshot Tasks. I run hourly snapshots with a 24-hour retention and daily snapshots with a 30-day retention. The space overhead is minimal because ZFS snapshots only store the differences.
For offsite backup, TrueNAS can replicate snapshots to another TrueNAS machine or any ZFS system over SSH. This is how I protect against hardware failure or disasters. One NAS at home, replicated snapshots to a friend's machine.
Running apps on SCALE
TrueNAS SCALE can run Docker containers through its app catalog or custom Docker Compose files. I run a few lightweight services directly on the NAS: a Samba file server (built in), a MinIO instance for S3-compatible storage, and a monitoring agent.
For heavier workloads, I keep those on my Proxmox server and use the NAS purely for storage via NFS mounts.
What I store on mine
My TrueNAS handles documents, photos, project backups, VM disk images (served over NFS to Proxmox), and media. Total usable storage is around 8TB in a mirrored configuration, which gives me 4TB of redundant storage. Plenty for a homelab.
The peace of mind from knowing my data is checksummed, snapshotted, and replicated is worth the setup effort.
Sources
Related posts
Uptime Kuma told me everything was fine. It wasn't.
Green checkmarks are not observability. Here is what I learned building a real monitoring stack.
Proxmox Backup Server: incremental backups done right
Why I use Proxmox Backup Server for my homelab backups, how incremental backups save massive amounts of storage, and how to set it up.
Automating your homelab with Ansible
How I use Ansible to automate server setup, configuration, and maintenance across my homelab machines.
Enjoying the blog? Subscribe via RSS to get new posts in your reader.
Subscribe via RSS