Live data from Hacker News

NixOS 22.11 “Raccoon”

nixos.org

141–150 of 201 posts

Re: NixOS 22.11 “Raccoon”

#141

Earlier quoted context omitted.

Seconding this. I ran Silverblue until recently due to some bugs in Kinoite but switched as soon as possible because GNOME sucks. Its the first distro I've used in 20 years that doesn't feel like a stiff wind could cause the whole thing to collapse and catch fire in an unrecoverable way, while still allowing me to run any software I want instead of just what is in some limited curated repo. And unlike Nix, I didn't n…

Does Silverblue still support traditional package managers? An immutable OS seems nice and I like Bubblewrap's isolation, but I would never switch full-time to an all-Flatpak distro...

Never mind traditional package managers... you plug it in right, you can run Nix on Silverblue!

https://gitlab.com/ahayzen/silverblue-nix

NixOS people will prefer NixOS, but Silverblue seems like a nice complement to Nix if you need an FHS base system and want to retain some Nix-ish features like rollbacks and atomic upgrades.

Re: NixOS 22.11 “Raccoon”

#142
post #63

I might want to try some new Linux distribution so I wonder: what doesn't work in nix? What are its weaknesses? What about devices with non-free firmware?

> What are its weaknesses? I think is easier to see this with what is their main strength: A declarative/reproducible OS setup. Is AMAZING for server deployment (like what you put in a docker file but that not mutate after it). But I don't think will be so nice for day to day use. That is where a mutation OS is easier.

I ran NixOS on my living room emulation/gaming computer for years, until I stopped having one. It wasn't particularly high friction or server-y.

Re: NixOS 22.11 “Raccoon”

#143
post #28

Earlier quoted context omitted.

I wonder why Nix doesn't give every package a FHS env by default. In 2022 chroot and overlayfs should be available everywhere. Wouldn't that solve a ton of problems?

A FHS adds slight overhead to a package and to launch times. It also shadows part of the file system. For example /lib would probably be different for every other program which would be even more confusing.

They're also not implemented on macOS, since they rely on Linux sandboxing features.

Re: NixOS 22.11 “Raccoon”

#144
Something that isn't stated in this thread yet is how easy NixOS makes version upgrades.

I maintain multiple pet servers. When I used Ubuntu, doing release upgrades cost me ~6 hours per server per upgrade every 2 years. Most of that time went into merging updated upstream configuration files with my changed configuration files, often for silly stuff like upstream changing tabs to spaces in the config file syntax. With the Debian-style upgrader, you also have to wait 5 minutes until you're prompted for the next config file to merge, while other packages are "configuring" with `dpkg`. So you cannot do them all in a batch, but have to stare at the screen throughout the procedure, attending every 5 minutes.

So with multiple servers that was multiple days of upgrades per year.

With NixOS, these days are is reduced to minutes.

For example, on one of my servers I upgraded just now:

    18:07    -- starting NixOS 21.05 -> 21.11 upgrade command
    18:10    -- download finished
    18:10:15 -- rebooted into new running system
This server currently runs:

    * webserver
    * mailserver (with web UI, spamfilter, etc)
    * nameserver (with dynamic DNS updates)
    * VPN server
    * mumble voicechat server
    * XMPP server
    * Matrix server with signal bridge
    * vaultwarden server
    * some custom web services
This is possible because with NixOS, you do not mutate text files in `/etc` for configuration. Instead, you write a structured config similar to a JSON object (but in the Nix language, so you can use stuff like `map` and `filter` to solve repeated tasks over e.g. all the domains in your web server). This config only contains the differences from the default config. So concepts like "does the upstream Apache config file indent with tabs or spaces" no longer play any role.

For the server above, the config file is 800 lines long, of which 200 are comments.

So NixOS is saving me multiple days per year in sysadmin tasks, which is pretty good!

Re: NixOS 22.11 “Raccoon”

#145
post #10

I might want to try some new Linux distribution so I wonder: what doesn't work in nix? What are its weaknesses? What about devices with non-free firmware?

I would expect something like Steam gaming on my dual-GPU laptop might be one deep mineshaft of "nope" on NixOS.

NixOS actually handles NVIDIA hybrid graphics more easily than most distros. When I got a laptop with NVIDIA/Intel hybrid graphics a few years ago, it took less time to configure on NixOS than it had on openSUSE, which I was dual-booting at the time.

I don't have a laptop like that anymore, but check the NixOS manual and NixOS.wiki, and ask around if you get stuck!

(When I last used it, Bumblebee was the best option and worked well, but these days, native PRIME offloading should also work fine and it's what I would prefer.)

As for Steam, just add

  programs.steam.enable = true;
to your config. Works great!

(If you're accustomed to Flatpak Steam, you can alternatively enable Flatpak and just install Steam that way, like you would on your existing distro.)

Re: NixOS 22.11 “Raccoon”

#146
post #88

I might want to try some new Linux distribution so I wonder: what doesn't work in nix? What are its weaknesses? What about devices with non-free firmware?

Nix feels to me like a cool but somewhat hacky v1 of a really great idea. I'm hoping someone creates a much more elegant successor. If Nix is CVS or even Subversion, I'm hoping for Git.

What? Have you used the old nix cli? It absolutely dominates Git in the frequency of "how do I do that again?" /s

Re: NixOS 22.11 “Raccoon”

#147

So far no one mentioned that you can: - easily cross compile packages: pkgsCross.aarch64-multiplatform.hello - NixOS has modules to get complete services like Nextcloud, Mastodon or Matrix Synapse up and running within minutes including nginx configs - it is possible to switch Desktops and clean up all packages

You easily can, but its a pretty miserable user experience compared to non cross-compilation (e.g. build times are incredibly long since happy-path nix is mostly backed by binary cache).

Re: NixOS 22.11 “Raccoon”

#148

My experience with NixOS: Package installation is usually just from the official channel, system options can usually be done with `/etc/nixos/configuration.nix` and home-manager. Major problems: installing niche proprietary software that you may have to package yourself, and fighting Nix for languages with package manager, e.g. Python, which frequently uses packages not in nixpkgs.

> Major problems

I don't think I agree here. There are plenty of examples of how to package/update/fix anything custom you desire. The learning curve is there, definitely, but this is not major - I do this several times for my own OS and software that utilizes Nix.

Re: NixOS 22.11 “Raccoon”

#149
Recently installed nixos and was trying to get docker installed with little success - I tried googling for a while and came up short. Maybe it’s obvious to veteran nixos users. Does anyone know of a comprehensive nixos guide or YouTube series? I’d love you forever.

Re: NixOS 22.11 “Raccoon”

#150

How long are we going to sit on our hands and pretend flakes aren't the only way forward? Am I just missing something?

I've not bothered with flakes (yet?); mostly because I don't quite understand/appreciate what they're for/add.

They're apparently better than using channels, and env vars like NIX_PATH; but I don't bother with those either.

I just use `fetchgit`/`fetchFromGitHub` with specific commit IDs, and that seems mostly reproducible. I've got Nix repos dating back about 8 years, and the only reason some commits can't be reproduced is due to link rot (mostly GitHub repos being deleted in protest at Microsoft purchasing it). I don't think flakes solve that? (Seems more suitable for something like IPFS)

Post reply on HN