18
submitted 2 weeks ago* (last edited 2 weeks ago) by spinning_disk_engineer@lemmy.ca to c/selfhosted@lemmy.world

EDIT: turns out I needed to set mountpoint=legacy, (sudo zfs set mountpoint=legacy <filesystem>) which is the standard way to use ZFS on nixos. Legacy in this context means that the mountpoint is decided by the system rather than ZFS; I guess ZFS was previously refusing to receive the mountpoint because it already had one, but I didn't notice because they happened to be the same.

I'm using ZFS on nixos, with an ext4 boot drive, and a ZFS pool whose key is loaded from the boot disk.

Despite mounting correctly, zfs also causes the system to fail and go into emergency mode. Even if zfs were to fail though, things like sshd and dbus shouldn't depend on it.

In particular, the system waits for about half a second after

         Starting Mount ZFS filesystems...

and the next line is

[FAILED] Failed to mount /ZFSmountpoint.

and then

[DEPEND] Dependency failed for Local File Systems.

A few lines later I get

[  OK  ] Finished Mount ZFS filesystems.

The next line is about emergency mode.

How can ZFS both fail and finish? And why does this affect the remainder of startup?

you are viewing a single comment's thread
view the rest of the comments
[-] Zwuzelmaus@feddit.org 2 points 2 weeks ago

To be precise, I think that it does not "both fail and finish".

You get the success message a little late, and some job control has decided earlier that it has failed, when in truth it just took longer than expected. The 'fail' message comes from this job control, while the 'success' message comes from ZFS itself.

this post was submitted on 27 Jun 2026
18 points (95.0% liked)

Selfhosted

60723 readers
311 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

Detailed Rules Post

  1. Be civil.

  2. No spam.

  3. Posts are to be related to self-hosting.

  4. Don't duplicate the full text of your blog or readme if you're providing a link.

  5. Submission headline should match the article title.

  6. No trolling.

  7. Promotion posts require active participation, with an account that is at least 30 days old. F/LOSS without a paywall has exceptions, with requirements. See the rules link for details. Tags [CBH] or [AIP] are required, see the links in Rule 8 for details.

  8. AI-related discussions and AI-involved promotional posts have additional requirements for tagging, as noted in Rule 7 and the AI & Promotional Post Expanded Rules post, and find example disclosures here.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 3 years ago
MODERATORS