Live data from Hacker News

FreeBSD: Home NAS, part 1 – configuring ZFS mirror (RAID1)

rtfm.co.ua

31–40 of 54 posts

Re: FreeBSD: Home NAS, part 1 – configuring ZFS mirror (RAID1)

#32
post #11

Is zfs really worth the hassle, for someone who does not have time to play "home sysadmin" more than once or twice a year? I've just rebuilt my little home server (mostly for samba, plus a little bit of docker for kids to play with). It has a hardware raid1 enclosure, with 2TB formatted as ext4, and the really important stuff is sent to the cloud every night. Should I honestly bother learning zfs...? I see it popping…

> Is zfs really worth the hassle

Yes. Also: what hazzle? It's in many ways simpler than alternatives.

Re: FreeBSD: Home NAS, part 1 – configuring ZFS mirror (RAID1)

#33
post #19

Earlier quoted context omitted.

IMHO, there's not much hassle anymore, unless you seek it out. The FreeBSD installer will install to zfs just as well as ufs. This article seems to not take the least hassle path. Backups using zfs snapshots are pretty nice; you can pretty easily do incremental updates. zfs scrub is great to have. FreeBSD UFS also has snapshots, but doesn't have a mechanism to check data integrity: fsck checks for well formed metadat…

The difference is zfs does a lot of work and makes a lot of promises that it proved the data is good at every step of the way while it's being handled, that other filesystems do not do. So: "I copied the data and didn't really look at it much." and it ended up being corrupt, is different from: "I promise I proved this is solid with math and logic." and it ended up being corrupt, complete with valid checksum that "pro…

ZFS says "once I've committed to disk, if the data changes, I'll let you know".

This works, regardless of if you have ram errors or not.

I will say that the reported error rate of 5 bit errors per 8 GB per hour in 8% of installed RAM seems incredibly high compared to my experience running on a fleet of about one to three thousand machines with 64-768 GB of ECC RAM. Based on that rate, assuming a thousand machines with 64 GB ram each, we should have been seeing about 3000 bit errors per hour; but ECC reports were rare. Most machines went through their 3-5 year life without reporting any correctable errors. Of the small handful of machines that had errors, most of them went from no errors to a concerning amount of errors in a short time and were shut down to have their ram replaced; a few threw uncorrectable errors, most of those threw a second uncorrectable shortly thereafter and had their ram replaced; there was one or two that would do about one correctable error per day and we let those run. There was one, maybe two that were having so many correctable errors that the machine check exceptions caused operational problems that didn't make sense until the hourly ECC report came up with a huge number.

The real tricky one without ECC is that one bit error a day case... that's likely to corrupt data silently, without any other symptoms. If you have a lot of bit errors, chances are the computer will operate poorly; you'll probably end up with some corrupt data, but you'll also have a lot of crashing and hopefully run a memtest and figure it out.

Re: FreeBSD: Home NAS, part 1 – configuring ZFS mirror (RAID1)

#34
post #31
post #24

Anyone knows how to search HN comments using Algolia for "RAID". Is there some secret support for case sensitive search ?

Depending on exactly what you are looking for, maybe search for raid levels, like raid0, raidz?

So far my go to solution is to hit google with

  "RAID" site:news.ycombinator.com
This has its own problems.

Re: FreeBSD: Home NAS, part 1 – configuring ZFS mirror (RAID1)

#35
post #11

Is zfs really worth the hassle, for someone who does not have time to play "home sysadmin" more than once or twice a year? I've just rebuilt my little home server (mostly for samba, plus a little bit of docker for kids to play with). It has a hardware raid1 enclosure, with 2TB formatted as ext4, and the really important stuff is sent to the cloud every night. Should I honestly bother learning zfs...? I see it popping…

> can't see the benefits for occasional use

I've lost work and personal data to bit rot in NAS filesystems before. Archived VM images wouldn't boot anymore after months in storage. Multiple vacation photos became colorful static part way through on disk due to a bit flip in the middle of the JPEG stream. I've had zero issues since switching to ZFS (even without ECC.)

Another huge benefit of ZFS is the copy-on-write (CoW) snapshots, which saved me many times as an IT administrator. It was effortless to restore files when users accidentally deleted them, and recovering from a cryptolocker type attack is also instant. Without CoW, snapshots are possible, but they're expensive and slow. I saw a 20-user office try to snapshots on their 30TB Windows Server NAS hoping to avoid having to revert to tape backups to recover the occasional accidentally deleted file. While hourly snapshots would have been ideal, the NAS only had room for only two snapshots, and would crawl to a halt while it created them. But ZFS's performance won't suffer if you snapshot every minute.

When it's time to backup, ZFS' send/recv capability means you only ever move the differences when backing up, and they're pre-computed so you don't have to re-index an entire volume to determine that you only need to move 124KB, making small transfers are lightning fast. Once backup completes, you have verified that the snapshot on both sides is bit-for-bit identical. While this is the essential property of a backup, most filesystems cannot guarantee it.

ZFS has become a hard requirement for any storage system I build/buy.

Re: FreeBSD: Home NAS, part 1 – configuring ZFS mirror (RAID1)

#37

When setting up root-on-ZFS on FreeBSD, it's worth knowing about boot environments (a concept originally from Solaris): * https://klarasystems.com/articles/managing-boot-environments... * https://wiki.freebsd.org/BootEnvironments * https://man.freebsd.org/cgi/man.cgi?query=bectl * https://dan.langille.org/category/open-source/freebsd/bectl/ * https://vermaden.wordpress.com/2022/03/14/zfs-boot-environme... It lets you…

oh, i didnt knew the concept is taken from Solaris, which version of Solaris? and is there any official source that indicates it is from Solaris?

The original idea of boot environments in Solaris came from Live Upgrade, which worked at least as far back as Solaris 8. Live upgrade was not part of Solaris, rather it was an addon that came from the services or enterprise support parts of Sun.

Solaris 11 made boot environments a mandatory part of the OS, which was an obvious choice with the transition from UFS to ZFS for the root fs. This came into Solaris development a bit before Solaris 11, so it was present in OpenSolaris and lives on in many forms of illumos.

Re: FreeBSD: Home NAS, part 1 – configuring ZFS mirror (RAID1)

#39
With all respect to FreeBSD.

It seems weird in 2025/2026 we are still discussing the baseline of getting a storage working.

Feels we’re spending too much time discussing the trees and not enough time getting the forest going: * we need reliable local storage * integrated backup * apps installation / management * remote access and account management * app isolation, reliable updates

Re: FreeBSD: Home NAS, part 1 – configuring ZFS mirror (RAID1)

#40
I've run my own Home NAS on ZFS for 4 years or so. In the end I ended up with majority NVMe setup with long-term archival storage on HDDs. This made my NAS much more useful / ergonomic since I can search, move files at 10Gbps speeds. I really hated the pause when opening up directories, etc. Details here:

https://benhouston3d.com/blog/home-network-lessons

Post reply on HN