Why everyone is switching to NixOS ?

Hi everyone!

I saw that NixOS is getting popularity recently. I really have no idea why and how this OS works. Can you guys help me understanding all of this ?

Thanks !

151 points · 198 comments · view on lemmy.world

198 Comments

JASN_DE@feddit.de · 51 pts · 3y (2 replies)

everyone

Now that's what I'd call a stretch...

barsoap@lemm.ee · 19 pts · 3y

Indeed, why would I switch, already have been running NixOS for 10+ years.

L0Wigh@sh.itjust.works · 5 pts · 3y

I'll edit. That was clearly a stretch

Veritas@lemmy.ml · 26 pts · 3y (39 replies)
[ removed ]
cypherpunks@lemmy.ml · 30 pts · 3y (32 replies)

this comment reads suspiciously like it was written by an LLM (eg ChatGPT). was it? please don't do that!

flustered@kbin.social · 5 pts · 3y

I tried asking for sources before, and they were all wrong, either non-existant or not even about the topic, some were just random urls.

lowdownfool@kbin.social · 3 pts · 3y (4 replies)

Do LLMs give citations? Otherwise, I could agree.

cypherpunks@lemmy.ml · 11 pts · 3y

Do LLMs give citations?

do they ever!

(The citations in this comment appear to be all real links about NixOS, but they are not particularly relevant to the places in the comment where they're cited.)

Clairvoidance@kbin.social · 4 pts · 3y

Bing 'chat mode' (read: hooked GPT-4 to their search engine) does in essentially this format.

SlurryBravo@kbin.social · 1 pts · 3y

Yes, you can ask for them.

DevCakes@kbin.social · 0 pts · 3y

Yes, and it’s actually a problem. They sometime generate realistic looking, fake citations.

Veritas@lemmy.ml · -35 pts · 3y (25 replies)

@dessalines@lemmy.ml @AgreeableLandscape@lemmy.ml @wazowski@lemmy.ml @k_o_t@lemmy.ml @nutomic@lemmy.ml @kixiQu@lemmy.ml an admin is telling me not to use LLMs. Is this the official stance of this instance? If so, please let me know so I can find another instance and add it to the rules, if not please choose admins that actually enforce the instance rules without making them up.

RosalynKirk@kbin.social · 35 pts · 3y (15 replies)

If OP wanted a response from an LLM, they would have typed their question into an LLM. The least you could do is label it as such.

Veritas@lemmy.ml · -25 pts · 3y (14 replies)

I use an LLM to edit everything I write. Does this mean I have to label everything as LLM-generated? I am the one doing the job, but in the end, I'm just copy-pasting the output from the LLM.

20gramsWrench@lemmy.dbzer0.com · 18 pts · 3y

Rule or not, it's pretty lame, look at the size of your post compared to how much info it gives, had you copied a article from some basic linux news stite, it would have given mostly the same output, now think about what linking a page to an article about nixos as a response to op trying to start a conversation about it would look like, rude.

133arc585@lemmy.ml · 16 pts · 3y (9 replies)

I think you should.

Veritas@lemmy.ml · -19 pts · 3y (8 replies)

Why don't you label your name in every answer, so we can check if you are hallucinating or making things up?

AgreeableLandscape@lemmy.ml · 22 pts · 3y

Why don’t you label your name in every answer

You mean like a username that is listed in the header of every post and comment?

133arc585@lemmy.ml · 12 pts · 3y

Why don’t you label your name in every answer, so we can check if you are hallucinating or making things up?

What?

I'm also curious why you feel the need to have an LLM edit your writing. What did you do before an LLM? And what benefit do you feel the LLM writing your comments is offering you and those reading your comments?

RosalynKirk@kbin.social · 13 pts · 3y (1 reply)

Using an LLM to autocorrect your own words is not the same as copy-pasting an LLM response.

sin_free_for_00_days@lemmy.one · 7 pts · 3y

I swear, LLMs are really giving people the You made this...I made this meme a rebirth.

Zamboniman@lemmy.ca · 12 pts · 3y

I use an LLM to edit everything I write.

May I invite you to consider the pitfalls of such an approach?

Does this mean I have to label everything as LLM-generated?

Yes, that would be reasonable imo

cypherpunks@lemmy.ml · 26 pts · 3y

thanks for clarifying. i'm deleting your generated comment per rule 4 (spamming); if another admin wants to undelete it i would be surprised.

please do not post LLM-authored comments without clearly labeling them as such. imo this is common sense, and doesn't need its own rule, rule 4 is sufficient.

AgreeableLandscape@lemmy.ml · 17 pts · 3y (1 reply)

The admins did not remove the comment, a community mod did. Mods can impose further restrictions on their communities on top of instance wide rules (within reason of course), including banning LLMs. Lemmy.ml at least does not have a blanket ban on LLMs, but generally it's expected that, 1, you should not post LLMs excessively, we mainly want to host discussions by humans, 2, you should disclose it's from an LLM and which one it's from, and preferably add to what it says with your own comments or analysis. If it's a mix of LLM and your own writing, say so at the start of the comment, but if the community directly disallows LLMs then you shouldn't post it there at all.

Veritas@lemmy.ml · -18 pts · 3y

So basically promote software for free? No thanks, bye. I won't attribute everything I write to an LLM.

r00ty@kbin.social · 16 pts · 3y

I don't know whether just using an LLM is a problem. But in your case I would say the fact you used one and didn't indicate you did. If you indicated the answer came from an LLM, then the trust in the answer could be weighted accordingly by each user.

That's my opinion at any rate.

barsoap@lemm.ee · 6 pts · 3y (3 replies)

Under the soon to be enacted EU AI laws such a bot would be limited-risk application (interaction with humans), the requirements for a text bot aren't particularly high but also non-negotiable from a best practice POV: Stating front and centre that it's an AI generated post. It's also best practice to fulfil criteria necessary for high-risk systems voluntarily, the more you can fulfil I bet the less hostile people are going to be.

The library of congress has an executive summary of the thing.

(EU sources alas are a bit iffy at the moment there's the commission version and the parliament amendments, haven't seen a consolidated version yet. When will politicians start using proper VCS)

Veritas@lemmy.ml · -13 pts · 3y (2 replies)

I use an LLM to edit everything I write. Does this mean I have to label everything as LLM-generated? I am the one doing the job, but in the end, I'm just copy-pasting the output from the LLM.

sin_free_for_00_days@lemmy.one · 12 pts · 3y

Try not using an LLM to write what you..uh..write.

barsoap@lemm.ee · 12 pts · 3y

If your sources don't match the claims no you're not doing "the job" necessary to classify things as LLM-assisted instead of LLM-generated.

Woovie@kbin.social · 1 pts · 3y

You suck

NathanUp@lemmy.ml · 3 pts · 3y

I would love to have #4 on Arch / EndeavourOS.I recently had my Scribus install (SVN from the AUR) break due to Arch moving to some newer library. There really isn't an easy way to solve this AFAIK.

ItsYourBoyHalo@lemmy.world · 2 pts · 3y (1 reply)

Do you use Nix, personally? Also, it's crazy that I found this post while thinking about distro hopping.

FleaCatcher@lemmy.world · 24 pts · 3y

The above poster seems to use more ChatGPT than Nix, personally.

Geometric7792@kbin.social · 1 pts · 3y

This is clearly a chatgpt post that you made references for

operator@kbin.social · 0 pts · 3y

Nice summary, appreciate the links. Sounds like Bing AI thought ;)

prosp3kt@lemmy.world · -1 pts · 3y
[ removed ]
Tilted@programming.dev · 26 pts · 3y (12 replies)

I used NixOS for a couple of years. My experience is like this:

  1. It is a rolling release (mostly)
  2. You write a declarative configuration for your system, e.g., my config will say I want Neovim with certain plugins, and I can also include my Neovim configuration
  3. It is stable, and when it breaks it is easy to go back
  4. Packages are mostly bleeding edge
priapus@lemmy.one · 8 pts · 3y

Important to note that NixOS has both a rolling release and point release version.

Atemu@lemmy.ml · 7 pts · 3y

Note that there's both the rolling unstable channel and a bi-annual stable release channel.

L0Wigh@sh.itjust.works · 6 pts · 3y (2 replies)

The configuration stuff seems great. I guess it reduce the struggle of porting a full config from one pc to another right ?

Tilted@programming.dev · 8 pts · 3y

Yes absolutely. It is really great. It is also a source of frustration, e.g., missing configuration options, non-obvious options and so on. Overall it works well.

SrEstegosaurio@lemmy.ml · 1 pts · 3y

You can even define configurations for different systems/hosts/users from a single place. I'ev atomized my config and I can reuse lots of parts for my different machines. Also my user config is nearly identical (except hardware specific things).

SirNuke@kbin.social · 2 pts · 3y (5 replies)

Are you still using it and happy with it? I've been increasingly setting single purpose dev VMs in server, and a declarative configuration system would make the process of spinning them up faster and more robust. My current shell script system is clunky, and I've been looking at Ansible.

Tilted@programming.dev · 6 pts · 3y (4 replies)

Not using it anymore. Although I'm thinking about going back to it. The NixOS learning curve is a bit more steep than most other distros.

pfpoitras@lemmy.ml · 2 pts · 3y (1 reply)

What are you using instead?

Tilted@programming.dev · 1 pts · 3y

I have been using Arch and Fedora. Considering Fedora Silverblue too. Everything is working well, so not in a rush to distro hop.

fazo96@lemmy.trippy.pizza · 2 pts · 3y (1 reply)

Why did you stop using it?

Tilted@programming.dev · 1 pts · 3y
  1. Some level of frustration with the nix language and the configuration
  2. Wanting to try various obscure Python packages

Nothing too major. Just already knowing how to make things work in other distros vs investing more time into learning to do it the NixOS way.

Gentoo1337@sh.itjust.works · 0 pts · 3y

Wow, that sounds really cool (specially the config thing). I'll have to try it sometime.

federico3@lemmy.ml · 25 pts · 3y (2 replies)

It's in no way "everyone", just a vocal minority.

Eufalconimorph@lemmy.ml · 16 pts · 3y (1 reply)

I use Arch NixOS BTW.

pingveno@lemmy.ml · 2 pts · 3y

Why do I get nothing but first dates?

By the way, I use NixOS.

featherfurl@lemmy.ml · 19 pts · 3y (2 replies)

Here's the straightforward version of why I use it:

  1. The entire state of your operating system is defined in a config file, and changes are made by changing the config file. This makes it super easy to reproduce your exact system many times and to know where all the many different configuration elements that describe your system are located.

  2. Updates are applied atomically, so you don't have to worry about interrupting the update process and if it fails, the previous state of your system is still bootable. By default every time you change something, you get another option in the boot menu to roll back to.

  3. Making container-like sub systems is super easy when you're familiar with nix, so you can have as many different enclaves as you like for different software versions, development environments, desktop setups, whatever without taking a performance hit. Old versions of stuff are very accessible without breaking your new stuff.

  4. The package manager has a lot of software and accessing nonfree stuff is straightforward. Guix looks rad, but nix ended up being the more practical compromise for my usecase. I didn't want to have to package a heap of software the moment I made the switch.

tetris11@lemmy.ml · 5 pts · 3y

You forgot to mention: cross-compiling binaries for other architectures has never been so easy. You can even make them static builds.

It's breathed new life into my old synology NAS which is stuck on an old Linux 3 kernel.

SolemnAttic@feddit.de · 2 pts · 3y

This very much. I used to have lots of unchecked config and state files everywhere on Arch. Now everything is checked in and wiped on boot so if something breaks after a reboot i know what broke.

Like how the opengl rendering did due to nixpkgs version differences

fazo96@lemmy.trippy.pizza · 18 pts · 3y (1 reply)

I have been using for years on servers. My lemmy instance is hosted on it.

Although for desktop I had too many issues back in 2019 so I ended up back to Arch Linux and then EndeavourOS

Would be fun to try again to use it on desktop

dbemol@lemmy.dbzer0.com · 2 pts · 3y

I think I will give it a try on a server first, I don’t have a playbook or script for a reproducible set up (yet), so I may as well use Nix to see if it’s worth the hype

le_saucisson_masque@lemmy.world · 17 pts · 3y (2 replies)

I keep seeing trends with Linux distribution like teenager looking for new fashion.

I think it’s mostly the very young Linux user who hope from one distribution to the another over and over whereas many just stick with what they got : Ubuntu, Debian, mint, maybe fedora.

NixOS is certainly interesting tho.

donnachaidh@lemmy.world · 3 pts · 3y

I'm pretty stable — I've just gone between Ubuntu and Arch — and other distros don't really seem different enough to actually change how I use my computer. I'd just install the WM of my choice, then just use RPM instead of pacman or whatever. The actual premise of NixOS is intriguingly different. Saying what you want the system to be, rather than saying how to change the system.

choroalp@programming.dev · 1 pts · 3y

Atleast NixOS isnt one of the countless Arch based distros emerged since pandemic

mrh@mander.xyz · 15 pts · 3y (6 replies)

I daily drive GNU Guix instead, and I would strongly recommend any emacs and/or lisp enthusiasts interested in the benefits of functional, reproducible, declarative, and hackable system management to give it a try!

ncrranger@sh.itjust.works · 4 pts · 3y (3 replies)

Do you run the gnu guix distro or just use the package manager? Because iirc it uses only free software, even for drivers. So I imagine it is not that easy to find compatible hardware.

mrh@mander.xyz · 4 pts · 3y (2 replies)

I run the complete system. It's true that the standard iso comes with the linux-libre kernel and the standard channel (think repo) contains only free software. However there is the nonguix channel which comes with the full linux kernel, and all the proprietary drivers you could ask for.

Nonguix offer an ISO with the full kernel too in case you have a proprietary wifi card and don't have ethernet for the initial setup. The nonguix README I think is pretty clear, but Systemcrafters also made an excellent guide for doing this.

My wifi card unfortunately requires proprietary drivers and I have personally never had an issue with guix + nonguix for all my software needs, proprietary and otherwise.

Hope that helps profligate!

noisytoot@lemmy.ml · 1 pts · 3y (1 reply)

Does it actually require proprietary drivers or just proprietary firmware? I don't know of any wifi cards that actually require proprietary drivers on Linux.

rrobin@lemmy.world · 1 pts · 3y

I run the GUIX system distribution in all my machines - other than the initial install being a bit harder it is great.

Firmware blobs yes. The default GUIX kernel patches out all proprietary blobs, but the nonguix kernel has them. I do have one machine where I also build the kernel package with my own config because the the wifi driver is not build by default in the linux kernel.

Did a quick search here, besides firmware, nonguix has packages for the nonfree nvidia drivers, brother printer driver, unrar.

In addition nonguix also packages software that GUIX does not, e.g. firefox, or third party binaries:

https://gitlab.com/nonguix/nonguix/-/tree/master/nongnu/packages

dario@feddit.it · 0 pts · 3y (1 reply)
[ removed ]
mrh@mander.xyz · 1 pts · 3y

It's a source-based distribution like Arch so packages are as up to date as the package maintainers keep them. Of course anybody can go in and submit a newer version of a package if the original packager has been slacking on updating. You can also use your own custom version of the package by just copying the package definition, bumping up the version number, and then installing it with guix package -f my-custom-package.scm

Arctichawk1@lemmy.ml · 13 pts · 3y (1 reply)
[ removed ]
CalcProgrammer1@lemmy.ml · 5 pts · 3y

I will continue to use Arch btw...

moldyringwald@kbin.social · 11 pts · 3y (6 replies)

It's insanely stable but you have to have a lot of linux/programming knowledge to do even the simplest things like installing/updating your software or making little tweaks. I played with it for hours the other day and I'm just too dumb to figure it out lol I think it's just a super stable highly customizable distro for power users and a lot of people like that. If you can get over the learning curve it's a pretty powerful and unique os

Chobbes@lemmy.world · 4 pts · 3y

It's kind of funny because I'd put NixOS on a complete newbies computer for sure, and recommend it to an expert... But I'm less sure if I'd tell a random mid-intermediate Linux user to switch.

Like if Grandma wants Linux on their computer to do some internet browsing for some reason... I'd absolutely put NixOS on it because it's easy to manage the system for them... But somebody who is a little familiar with Linux already might be more confused about the differences. It's kind of the ultimate beginner distro and the ultimate power-user distro, but a bit awkward between those extremes, haha.

Glome@kbin.social · 1 pts · 3y

It's true that it can be a powerful distro but I've also heard from some users that the advanced-level documentation is lacking and only limited to forums and source code. I think maybe if the documentation was more thorough I would try nixos.

RosalynKirk@kbin.social · -10 pts · 3y (3 replies)

you have to have a lot of linux/programming knowledge to do even the simplest things like installing/updating your software

So, pretty much like any other distro

priapus@lemmy.one · 10 pts · 3y (1 reply)

Most mainstream distro's can do all of that without a CLI.

RosalynKirk@kbin.social · 0 pts · 3y

Weird, every distro I've tried either has no management, or doesn't work. Just spins around loading. "Uninstalling" packages does nothing but remove them from the package manager.

jalda@sopuli.xyz · 1 pts · 3y

Not even remotely close

chris@lem.cochrun.xyz · 9 pts · 3y

I've been using it for over a year and love it. A config file for your entire system, and built in rollbacks anytime something goes wrong. One language to configure everything, although in practice that doesn't always work. But I love it.

Some others have started why it works, here is some how. Nixos completely disregards the fhs. Packages don't install to anywhere standard, every package and configuration change gets it's on directory in /nix/store but through smart use of tracking everything there, it symlinks all those files to proper places and sets up the environment for them to know where libraries are.

This is then also why you don't need sudo privileges to install things. Your profile has an environment that is aware of your users packages and configurations, the system itself isn't effected because everything is symlinked.

Then because every update means new directories in /nix/store you can role back to your last configuration because plasma broke something or whatever.

However, it's a LOT to learn. Best place I know of is https://piped.video/watch?v=AGVXJ-TIv3Y&t=0

This guy did a good job for me. Hope this helps!

joshthetechie@lemmy.world · 8 pts · 3y

People love Nix because of the OS configuration based around a single config file. Essentially, you define your system configuration in this file, including installed programs, then you rebuild your system based on that configuration.

The beauty here is that you can easily move this file to another machine running NixOS and reproduce your configuration there. You can also roll back changes by simply rebooting and choosing the last known good build and you're back in business.

ambrosia@kbin.social · 7 pts · 3y

because it's good as hell and i don't want to have to spend time having to rebuild and reconfigure fresh OS installs or risk breakage when I could just use a config file that I know already works

Herbstzeitlose@feddit.de · 7 pts · 3y (5 replies)

Because it’s the latest Cool Nerd Thing™ like Arch before it, and Gentoo before that. Most of the people raving about it probably don’t have much use for its features.

IDe@lemmy.one · 10 pts · 3y

The features themselves are very useful for basically any user. Whether they are worth the non-standardness and issues that come with it is another question.

zerdekahu@lemmy.world · 3 pts · 3y
[ removed ]
beyond@linkage.ds8.zone · 1 pts · 3y

I'm using GNU Guix System which is similar to NixOS and I think I can safely say I do appreciate Guix's features that set it apart from a traditional GNU/Linux distro or package manager.

___hulk@kbin.social · -1 pts · 3y (1 reply)

Solution without a problem. A cool solution but yeah.

commandar@kbin.social · 5 pts · 3y

I don't think that's accurate, personally.

Declarative orchestration systems have been around for years and have a very real use case when needing to stand up servers in a replicable way. Nix is applying that approach at the system level.

I'm not entirely sold on wanting to put that level of effort into a personal desktop, but I don't think it's at all fair to say that it's not addressing real problems.

lloram239@feddit.de · 6 pts · 3y
[ removed ]
Raphael@lemmy.world · 6 pts · 3y (3 replies)

They're not but nixos users are REALLY loud, as in, they can't spend a single day without talking about it.

New Arch. Both still worse than Silverblue.

that_leaflet@lemmy.world · 5 pts · 3y (2 replies)
[ removed ]
PainInTheAES@lemmy.world · 2 pts · 3y

Yup, I did the same thing. I really wanted to make it work but I think it just needs some time to mature. Once it has some clean documentation and polishing it'll be really cool.

I really liked how NixOS has a hardware config repo. I have a Framework, used the config, and everything just worked. I mean it usually does on other distros too but it's nice to know that if there's a config it'll be guaranteed to work.

I'm currently really enjoying kinoite. I think it also has some documentation issues but it's also not as radically different from your average distro as NixOS..

Faresh@lemmy.ml · 1 pts · 3y

Never heard about Silverblue, but you may want look at GNU Guix. It is also a functional package manager and I've heard from some people that they liked the guix documentation more (not sure if that's true). Also it uses scheme for configuration rather than some special-purpose language.

IDe@lemmy.one · 6 pts · 3y

It's been around for like a decade, but was recently make more approachable by offering a graphical installer.

IncidentalIncidence@feddit.de · 6 pts · 3y

I didn't get it either, but this video does a pretty good job explaining why it's different: https://www.youtube.com/watch?v=DMQWirkx5EY

DAT@feddit.de · 5 pts · 3y

nah

didn't have enough time during the last half a decade to learn yet another thing

might be better fit than my current debian setup - but how would I ever know, since my current thing is good enough?

thenonymousrexius@lemmy.dbzer0.com · 5 pts · 3y (6 replies)

Oh boy my two cents time!

I love the concept of NixOS. A fully declarative , reproduceable system from a single config repo! Sounds theoretically like it would be my kind of thing.

Sure, theoretically, I could have a fully reproduceable system. The time spent declaring that fully reproduceable system though... I remember the first time I was trying to get my usual disk setup of, a luks encrypted btrfs partition with multi-factor enabled decryption/authentication.

On a normal install it would take like a day at worse to install your distro. My first attempt with NixOS took me almost 4 days of screwing around in configs. 2 of those days were probably cumulatively spent waiting for the config option list of the nixos manual to search for text. And the number of redundant config options which all do the same thing! Or, are supposed to all do the same thing but in actuality, only one of them does the thing they are supposed to.

I really want to love NixOS but it always ends up feeling like an exercise in my patience and time to do even the simplest of things. As such I find myself asking the question of, am I going to spend so much time reinstalling my distro that it's ever worth this initial investment?

Anyways, rant over. I actually have been debating switching back over for another try again myself I just have some very frustrating memories of my first attempts with the distro.

Laser@feddit.de · 2 pts · 3y

Interesting, my first install of NixOS was done in a few hours and included a feature that I had not used in my previous Arch install, namely secure boot. It proved to be no issue whatsoever.

I do agree though that you're looking of lost without search.nixos.org, and documentation is lacking. E.g. did you know that enabling Plasma sets your main font to Noto, regardless if you're actually using Plasma or just have it as an option in your display manager? Or when to enable a program or service rather than adding it to your system packages? Or that if you install plain obs and some plugins, the plugins won't actually work?

I do understand why this is the way it is and I do think it's the better approach. But it's not perfect.

On the other hand, my system works very well in daily usage.

Chobbes@lemmy.world · 1 pts · 3y

I'd disagree with this. There's an initial learning curve for the Nix language and configuration, but i've found it's much easier to configure a NixOS system than pretty much anything else. For instance, I wanted to try pipewire instead of pulseaudio, and the switch was as easy as services.pipewire.enable = true... The NixOS configuration will automatically pick up that it's mutually exclusive with pulseaudio, let you know that you should disable that option in the config, and then boom. It's often the case that you can just enable services in NixOS and it will set them up for you completely. It's kind of great. Another example is that I can just say "hey, make my keyboard layout Dvorak" and it will automatically configure that everywhere, even in Grub... Which is just amazing, I tried to figure out how to configure that in Grub before and just failed --- didn't think it was even possible.

But beyond that, it's super worth it if you manage multiple machines. Keeping packages and custom configurations in sync between desktops, servers, and laptops was a huge pain before NixOS for me, and any reinstall would be a few weeks of "ugh, how did I set up this thing again?" Now I just point it at my version controlled config and say "make me a computer" and it does it... The learning investment for me was paid off within a few weeks easily, but I'd understand if you only have a single machine and don't really need to worry about that so much. This plus all of the other advantages in Nix (like easy rollbacks, dev environments, distributed builds, etc...) just make it such a no brainer for me. It really is a fairly elegant solution to many problems, and it's hard to believe you lived without it once you get into it.

That said, I did personally bounce off of Nix a decade or so ago. It used to not have much polish, reproducibility was a huge pain before flakes, and nixpkgs didn't have that many packages. It's improved a lot in the past few years, though. Flakes are great, nixpkgs has everything under the sun, and even the config options that you complained about seem to be getting cleaned up... So it's worth another gander if you're interested in the ideas behind it, but had troubles before... Plus I think it might just take a couple attempts to really grok it for some reason.

Raphael@lemmy.world · 0 pts · 3y

You're talking to a NixOS evangelist, logic won't work

thenonymousrexius@lemmy.dbzer0.com · 0 pts · 3y

Also to keep playing the devils advocate and because I love this article. Though the original blog post doesn't seem to exist anymore, I found myself agreeing with a lot of these points as things to consider.

http://web.archive.org/web/20210730005950/https://hands-on.cloud/why-you-should-never-ever-use-nixos/

JRepin@lemmy.ml · 5 pts · 3y (3 replies)

I tried it about a year ago and I don't know it did not convince me. Yeah it might be great for some niche developer oriented needs or deployment but for a normal OS usage, meh. I kind of see it as a current hype, just like crypto/NFT before, and AI now. For normal everyday usage I find openSUSE Tumblweed much more suitable and much more widely applicable.

choroalp@programming.dev · 1 pts · 3y

Its getting better which each release

JakoJakoJako13@lemmy.world · 1 pts · 3y

What's the update process like? Do you have to reconfigure every configuration myself on update? I see this stuff about declaring packages and having multiple versions of stuff, but I don't get how it's sustainable unless you're on top of managing packages yourself. Like what if I have a version of network-manager and program-x that hasn't been updated in over a year that requires an old version of network-manager. Then that program gets updated, asking for the newest network-manager dependency meaning I have two instances of network-manager. Then there are other programs that are looking for a more up to date version of network-manager but not the bleeding edge one. That seems like it'll lead to a sort of quasy digital hoarding. And if you're on NixOS long enough you're just destined to run into dependency hell. Does Nix do anything to ward that off?

Syudagye@pawb.social · 5 pts · 3y (4 replies)

SYMLINKS

SYMLINKS EVERYWHERE

(also 6000 packages intalled on my system for some reason lol)

Atemu@lemmy.ml · 2 pts · 3y

Well, Nix has a very liberal definition of a "package". Your web browser, its wrapper script, a service file, a config file; those are all technically "packages" (or "derivation" as Nix calls them).

Faresh@lemmy.ml · 1 pts · 3y (2 replies)

Doesn't it have a garbage collector like guix does (guix gc), which cleans up everything in the store that isn't needed anymore?

zwerdlds@lemmy.ml · 2 pts · 3y

Yep, Nix-store -gc or some such will do something like this.

SrEstegosaurio@lemmy.ml · 1 pts · 3y

nix-collect-garbage I configured it to run every 7 days.

hyperspace@kbin.social · 4 pts · 3y (8 replies)

What about Nix's financial issues? Have they been resolved yet?

Atemu@lemmy.ml · 2 pts · 3y (7 replies)

To get it out of the way first: There are no financial issues. There are more than enough funds to continue operations as they are for a sufficiently long time.

What is actually happening is that a long time sponsor has indicated that they (understandably) no longer want to foot the huge bill of hosting the entire archive of binary caches ($9000/mo). Finding a more sustainable setup is what the community is currently concerned with.
There is no risk of operations shutting down any time soon, the NixOS foundation has funds set aside to continue even this unsustainable setup for at least a year. We just want to be more efficient with our and others resources going forwards.

That's what all this you might have heard of is about.

Btw, even if the binary cache were to go poof, we don't technically need it. NixOS is a source-based distro like Gentoo and source hosting is not a concern. The binary cache is immensely helpful though which is why we'd obviously prefer to keep it.

choroalp@programming.dev · 1 pts · 3y (6 replies)

I think AWS Gave them 12 months of free credit to host cache

Atemu@lemmy.ml · 2 pts · 3y (4 replies)

Yes, AWS gracefully sponsored 12 months of our S3 bill which gives us even more time to enact change.

That's just the short term resolution though, the Nix community is still looking into more sustainable long-term solutions.

root@precious.net · 1 pts · 3y (3 replies)

$9,000/mo? Have you considered not using the most ridiculously expensive method possible?

Atemu@lemmy.ml · 1 pts · 3y

the Nix community is still looking into more sustainable long-term solutions.

root@precious.net · 1 pts · 3y (1 reply)

Thinking about this further..

I can purchase 10GE fiber, at home, for $299/mo.

I can purchase a solid 16 bay Supermixro server for around $5k

16TB drives are $168. There's $3,700 left so let's buy 21 drives (336TB, 235TB usable under raidz3 zfs). We'll leave that last $170 for .. electricity.

Leasing all of this from a regular hosting provider woul be much more cost effective. I work for one, what the heck are you doing man?

Atemu@lemmy.ml · 1 pts · 3y

You aren't a reputable public hoster with AWS-class uptime. That has a price too. AWS is likely overpriced though, hence the nix community still looking for better alternatives.

Atemu@lemmy.ml · 1 pts · 3y
[ removed ]
curtismchale@lemmy.ca · 4 pts · 3y (3 replies)

I've been looking at it after numerous times I update Fedora only to have some tool break that I use daily. Then I spend a chunk of the day getting Virtualbox working again so I can do my job (write code for websites).

I haven't made the jump, but it looks very interesting.

tetris11@lemmy.ml · 2 pts · 3y (2 replies)

I've made the jump twice, and jumped back twice.

Conda and any other reproducible computing library that relies on LHS Linux filesystem just doesn't work on it (okay it does, but more as an obstacle)

I'm okay with having nix the package manager on my default arch system though, since it is incredibly useful for cross compiling, and it let's me modify my system however I want.

phil_m@lemmy.ml · 2 pts · 3y (1 reply)

Have you tried putting it into a buildFHSUserEnv?

I also often put the "dirty" packaged AI/python stuff (which is unfortunately quite a lot) into Dockerfiles if I don't want to package it cleanly with Nix.

tetris11@lemmy.ml · 1 pts · 3y

I did, but it still doesn't quite act right, especially if I need to build extra packages within the environment

buckyogi@kbin.social · 4 pts · 3y

I ran it in a VM for several months and was underwhelmed. Sticking with Fedora.

datendefekt@lemmy.ml · 4 pts · 3y (4 replies)

Glancing over the website, I thought it's an immutable OS, like Fedora Silverblue. I could imagine that it might be cool to use with Ansible and stuff. But for an average user? I can't really see the advantages in respect to the work you have to put in.

quantenzitrone@feddit.de · 3 pts · 3y

NixOS is not immutable in the way Fodora Silverblue is, and way more declarative and reproducible than Ansible. But yeah it is not something you "need". Other distros work too, but NixOS is way more fun.

nani8ot@lemmy.ml · 2 pts · 3y

It is an immutable distro, altough it isn't image-based like Fedora's rpm-ostree.

NixOS basically replaces Ansible because the Nix package manager achieves the same goals already (configuration, deployment, ...).

But I agree, the work necessary to put into this non-standard distro makes it hard to recommend for a casual user.

ItsYourBoyHalo@lemmy.world · 1 pts · 3y

I mostly agree. I have been using NixOS for quite some time now. I am a home user with some Linux knowledge :)

NathanUp@lemmy.ml · 1 pts · 3y

Same. If I wanted to set up multiple PCs at once, I would definitely consider it, but for my workstation? I'd rather have the newer packages offered by the Arch repos. Even with that said, you can use KDE's apper to quickly install a bunch of packages.

JSens1998@lemmy.ml · 4 pts · 3y (3 replies)

Hmm, I've never heard of NixOS. Is it suppose to be like blendOS or CurtainOS? A blend of different desktop environments?

knoff@lemmy.ml · 4 pts · 3y (2 replies)

It's unlike most other Linux systems I've ever used. The central idea is declarative structures. So your entire operating system, all of the apps and systems services and other custom things you need, are declarative in one place and hopefully easy to activate.

So instead of flatpak install, you add the program to a 'text file' and rebuild your system.

Everything is using the nix package manager which has been around since long before the distro nixos.

That's only the start of the rabbit hole, but if anything sounds interesting i encourage you to check it out!

JSens1998@lemmy.ml · 0 pts · 3y (1 reply)

Hmm, a very interesting approach indeed.

When you say rebuild, does it have to rebuilt everything? If so, is it quick to do so?

knoff@lemmy.ml · 1 pts · 3y

It checks everything that has changed since last build and it changes only what is needed, I'd say 30 seconds or less normally. When updateing, you can end up updating all of the packages on your system at once, which of course is dependent on your network speed / sometimes compile time, but for me it can take around 10-15 minutes in that case. On a slow network, with a laptop CPU.

But you get atomic rollbacks so any breaking changes can be rolled back just by rebooting and selecting a different build.

TrippyTortuga@lemmy.ml · 4 pts · 3y (2 replies)

I will switch as soon as I can get proprietary Nvidia drivers to work on my laptop.

Speedmaster@lemmy.ml · 0 pts · 3y (1 reply)

That is the main reason I can't use my laptop with linux. It has a 3060 in it. I work as a dev and need to use 2-3 external displays with my laptop. The driver combined with x or wayland is atrocious, I tried 20 distros and I can't get it to work. The saddest thing is that none of the tech is exotic in any way. It's just HDMIs and AOC 24 inch monitors...

TrippyTortuga@lemmy.ml · 1 pts · 3y

To clarify, Manjaro Linux with proprietary drivers works just fine with my 3070m. It's NixOS that doesn't work for some reason.

Atemu@lemmy.ml · 3 pts · 3y

Answering that question fully would require a PHD thesis.

Perhaps you could narrow down your question a little?

count0@lemmy.dbzer0.com · 3 pts · 3y (6 replies)

For those who like a video format, I found this introduction quite informative.

Clairvoidance@kbin.social · 4 pts · 3y (1 reply)

Having the option to have multiple versions of a dependency without needing to have duplicates of the same version alá flatpak seems like it should've been a no-brainer on any linux distro.
With that said I'm very comfortable with my current system, so definitely not until I get majorly fucked by my life-choices
Definitely sounds like a competent player in comparison to most distros though.
And I feel like the terminal isn't as big a barrier as everyone makes it out to be (part of why I say that is because I think the entire concept of "beginner friendly distros" only makes the terminal seem more impenetrable through that wording)
All-in-one config is definitely something I would've hoped Arch had as well, and as a bonus I would love a system that kept all things related to the user in /home (I'm not completely sure Nix does but I may as well throw that in) (homed does not do that as it still has entities outside of /home that you better back up, in fact you'll risk being locked out of your user if you don't)

Atemu@lemmy.ml · 2 pts · 3y

as a bonus I would love a system that kept all things related to the user in /home

https://github.com/nix-community/home-manager ;)

quaddo@kbin.social · 4 pts · 3y (2 replies)

Thanks for this, it was definitely a nice overview. Not the first time I'd heard of NixOS, but I do seem to be seeing more frequent and more substantial discussions of it.

What I'm getting from all this, is that it looks to be a great way to set up reproducible desktop environments. And servers too, I suppose.

What I'm not getting from this: a compelling reason to switch from established players like RHEL and Ubuntu in combination with cloud-init and Terraform and the likes of Chef/Puppet/Ansible/Salt to spin up a cluster in the cloud, reconfigure, tear down, etc.

In case anyone is misreading me: this is not a dig at NixOS. It definitely looks interesting. Like, to the point that I'll at least spin up a VM on my Manjaro laptop and see whether I should perhaps consider wiping and reinstalling with NixOS. The "configuration through code" is extremely appealing here.

My concern here is corporate inertia. And before anyone gets gets ready to launch a diatribe about how corporations don't decide what the best tech is, I will agree with you. I've been around a while, and excitedly watched as Unix ramped up and displaced platforms like VAX/VMS and AOS/VS, using smaller and faster hardware. Then along came Linux and the battle for which distros would dominate.

As for configuration through code, I've been keeping a keen eye on things (tinkering when it's been possible to do so) since the days of cfengine and Jumpstart. I used to share this site with anyone that would listen to me; it's dated now, but the underlying principles are (were?) solid: http://infrastructures.org/

So for now, I think I'll have to limit my professional NixOS usage to tinkering and potentially useful side projects. For personal usage? Yeah, it might become my daily driver, but I need to find the time to tinker.

I will say that I'm presently involved in an effort to test something out that has my company's product available using rpm-tree. Not my decision, this is all being driven by a customer that has a lot of clout; they really, really want to use rpm-tree. It's proven to be a bit onerous at times.

What this NixOS discussion has managed to do for me is to have me wondering whether a NixOS approach would have worked out better; my sense is that yeah, maybe it would have. But my feelings here might simply be the result of "woo, shiny new object", which has definitely colored my opinions of things in my career of ~35 years. Something that I've had to restrain my excitement over, pending corporate sanity checks.

count0@lemmy.dbzer0.com · 1 pts · 3y (1 reply)

Great points and perspective!

I think NixOS at this point is great to know and have an eye on for new projects that happen to require some preconfigured OS "underneath". I wouldn't think about migrate existing, working infrastructure into NixOS either, 'just because'.

quaddo@kbin.social · 1 pts · 3y

It occurred to me that NixOS might have a hard time doing something like this:

  • create a 6 node Docker Swarm cluster, where 3 of the nodes are managers

I can see NixOS doing a fine job of templating a standard build that includes the Docker engine. But working out which one gets to init the swarm, which ones get to join as managers, which ones get to join as workers? Yeah, that's probably better off left to something like Ansible.

Clairvoidance@kbin.social · 3 pts · 3y

I was zzz until i heard having the ability to have different versions of packages installed at the same time without having the flatpak issue of having to have duplicates of the same package.
All-in-one config is definitely something I would've hoped Arch had (I just like the idea of everything user-related stored within /home because that makes fucking sense, no, homed doesnt do exactly that) so I'll definitely check it out if my harddrive ever crashes or something.

torafugu@kbin.social · 3 pts · 3y (1 reply)

I don't get the hype. I'm staying with Arch, as Nix seems to be mainly for developers.

nani8ot@lemmy.ml · 8 pts · 3y

NixOS has benefits not just for developers, altough being familiar with programming is helpful.

For me the main benefit of NixOS is being able to keep multiple systems in sync. For that I have 3 config files, the first containing all general config and packages I want to have installed. The other two are for my laptop and pc respectively, which allows me to make system-specific changes. E.g. tlp is only enabled and configured on my laptop.

And NixOS isn't just rolling release, it also has bi-annual stable releases, which is great for servers.

Rollbacks are also awesome, altough I used btrfs snapshots a few years back with Arch for a similar result. With a bit of setup they are bootable from grub.

halo5@lemmy.world · 3 pts · 3y

I actually read somewhere that Void Linux is the (not so) new up-and-comer...

blackstrat@lemmy.fwgx.uk · 2 pts · 3y (5 replies)

All I year about from the linux community is NixOS and btrfs, neither of which I have any interest in. It almost feels like someone with an agenda is promoting these two with how prevelant they are.

80KiloMett@discuss.tchncs.de · 13 pts · 3y (2 replies)

I like using btrfs with Arch because of the snapshots. If an update breaks something I can just boot into a snapshot from grub keep using my PC and solve the problem later. It's very useful... yes... very... you should try it... come... try btrfs... it's warm and cozy... INSTALL IT!

blackstrat@lemmy.fwgx.uk · 2 pts · 3y (1 reply)

I have tried btrfs in the past and when it goes wrong you are utterly shafted. You can't even mount it as a read only file system, it will just lock you out entirely. And the support isn't great, I ended up finding something that had a disclaimer along the lines of "only run this if you really know what you're doing", but obviously I didn't as the documentation didn't tell me enough to know. So the only people who could possibly know are the developers of the file system themselves. Anyway, I was 2 days in to trying to recover my data by this point so I gave it a go, nothing to lose - it refused to do anything. Great.

So in summary I'm not going to try it again.

chayleaf@lemmy.ml · 2 pts · 2y

can confirm, I've recently had my btrfs partition on NixOS go permanently read-only because it ran out of metadata space (which you can't extend without write access, even though btrfs does reserve 0.5GB of metadata space) so I've switched to bcachefs

HarriPotero@lemmy.world · 5 pts · 3y (1 reply)

Well, I've been sold on sold on btrfs for over a decade. If you're telling me NixOS is just as great I just might have to give it a try.

Chobbes@lemmy.world · 1 pts · 3y

I love both, but if I had to give up one... I'd give up btrfs over NixOS in a heart beat. Put me on a FAT32 NixOS system if you must...

slacktoid@lemmy.ml · 2 pts · 3y

Overlays. Good package management, and lot of stability stuff.

Lalelul@feddit.de · 2 pts · 3y

I switched around one and a half years ago. I must say, there are some hurdles to using NixOS. Mainly I dislike that it always takes around 20 times the effort to start and project. You make up for the initial time investment, because you end up with a far more stable setup, but still it does take some willpower to get things started.

binboupan@lemmy.kagura.eu · 2 pts · 3y (2 replies)

I'm using Void Linux and see no reason to move over to NixOS. The concept seems cool though.

Shareni@programming.dev · 5 pts · 3y (1 reply)

The nice thing about nix and guix is that they're package managers, and so you get most of the benefits even if you're using a different OS.

I'm currently transitioning from Doom Emacs to my own config that's using guix. So far I've got a single manifest that contains all of the Emacs and Linux packages that are needed to run the config.

The guix part is really simple, but it allows me to reproduce my config on any Linux distro by cloning a repo and running a guix one liner. A different one liner can run it in a containerised environment. Also, I can roll back to any previous time I've updated something through that manifest, or pin a specific version of a package.

And that's just scratching the surface of what you can do.

binboupan@lemmy.kagura.eu · 2 pts · 3y

Yeah, I'm using the Nix package manager for software that isn't in the repositories, on Void.

Chobbes@lemmy.world · 1 pts · 3y

Moving an existing config to flakes isn't very hard at all --- flakes are still nix, after all. Flakes try a little bit harder to be pure, so if you're doing some hacky stateful things in nix you might have a harder time, but it's probably pretty unlikely you're doing that :).

The main thing that flakes are to me is a way to pin down specific versions of packages --- you can kind of think of a nix flake as something akin to a requirements.txt file for pip in Python (if you're unfamiliar, it's just a file that lists a bunch of packages and the specific versions that should be installed for a project). It's a little more granular with flakes because you usually pin the whole nixpkgs repository to a specific revision, for instance, but it's the same idea :). There's a little more to it than just "pinning the version of nixpkgs" you're using because nixpkgs doesn't have to be the only "input" for a flake... You can depend on other flakes, and those will have their versions locked in the flake.lock file as well. There's not really much to flakes, they're basically just a specific structure for a nix expression with an inputs field that lists the dependencies for the flake, and an outputs field that lists the things produced by the flake (e.g., packages, dev environments, overlays, etc).

NSA_Server_04@lemmy.world · 1 pts · 3y

It's cool, but I'm a happy Pop OS user.

Heimchen@lemmy.ml · 1 pts · 3y

I am waiting for OpenSuse Leap 16.(mainly because of my wired GPU Setup I just couldn't get running on other Distributions)

stappern@lemmy.one · 0 pts · 3y
[ removed ]
authed@lemmy.ml · 0 pts · 3y

Never tried NixOS but I think I will try Qubes-Whonix next: https://www.whonix.org/wiki/Qubes

joneskind@lemmy.world · -2 pts · 3y

I don’t know NixOS. My Linux machine runs Pop_OS and Manjaro.

What are the pros and cons of NixOS ?

20gramsWrench@lemmy.dbzer0.com · -3 pts · 3y (9 replies)

I'm really not sure of where this would be anymore usefull than a simple bash script to install all packages you need since it doesn't do configs and that rollbacks are supported by some filesystems already. Also Having version specific dependencies is already a thing for flatpacks and such

priapus@lemmy.one · 7 pts · 3y (4 replies)

A simple bash script is not reproducible or deterministic. Also a filesystem rollback is not the same as NixOS's generation based rollback.

Also, NixOS doesn't just install packages, all system configuration is done declaratively, which would be a very bad idea to do via a bash script.

20gramsWrench@lemmy.dbzer0.com · 0 pts · 3y (3 replies)

I have to check a little harder on what it does since I saw in a vid that you still needed to add your own if statement to get it working I assumed a simple

pacman -Qk xorg-xrtrop 2> /dev/null && sudo pacman --noconfirm -S package1 package2 package3 || echo 'I aint got no x, idiot'

would do the job as well

priapus@lemmy.one · 3 pts · 3y (1 reply)

I'm not familiar enough with Pacman to know what that command does. It's definitely not as clean or easily manageable for servers as NixOS is. Especially not when you have multiple systems of which you would like some packages to be shared and others not. It also still doesn't allow you to manage global system configurations.

20gramsWrench@lemmy.dbzer0.com · 2 pts · 3y

this one just checks if xorg is installed and installs a few packages if it is, or call the user an idiot if it isn't Nix seems to be really good if you need more than a personal os

Atemu@lemmy.ml · 2 pts · 3y

I'd recommend reading some more; especially w.r.t. imperative vs. declarative.

In NixOS, you'd do something like this:

{ config, ... }:

{
  environment.systemPackages = if config.services.xserver.enabled then [
    package1
    package2
    package3
  ] else [
    # You could optionally make headless packages available here
  ];
}

You don't need to understand the exact semantics here but you can look at it like JSON but with functions. This is not a "program", the end-result is just data. You're not modifying some stateful system state with new state from an uncontrolled source (i.e. the Arch repos) but rather just "outputting" a different dataset.
NixOS then builds a concrete system out of this pure data specification. In this concrete system, those packages' executables are available in the "global" PATH.

You say "I want a system where x y z are installed" and it does it for you in a standardised manner. With the bash script, you explicitly tell it each step ("install x; install y; install z"). This pure data nature is what's meant by declarative.
This distinction rules out whole classes of issues you simply cannot run into with NixOS.

Another aspect is that, as long as you use the same revision of Nixpkgs and the same config file, you can re-create the exact same system (almost bit-for-bit). If you were to run your bash script in a year's time however, you'd get an entirely different system with totally different revisions of software and therefore possibly entirely different behaviour.
This is what's meant by reproducibility.

You can achieve some of the same things NixOS does using imperative tools but nowhere near the same quality.

sickday@kbin.social · 5 pts · 3y (2 replies)

Part of the purpose of NixOS is providing a means to build a reproducible environment that's easy to configure, migrate, and rollout. You can absolutely handle configuration of many different programs using either flakes or the native modules provided by nix. You can customize your entire system from firewall entries, to users and their shells, to the kernel itself and the kernel modules you'd want it to load, all in a single file or multiple files. If you want to try doing all those things in bash scripts, good luck and please share your experiences but don't expect it to be as easy as the Nix ecosystem.

20gramsWrench@lemmy.dbzer0.com · 4 pts · 3y (1 reply)

so it does handle more than just conditional packages like the other zealots make it sound like

NuclearDolphin@lemmy.ml · 3 pts · 3y

Wayyy more. You can move all of your dotfiles to Nix config. And deploy it with Nix based infrastructure.

kevincox@lemmy.ml · 3 pts · 3y

There is a world of difference between a bash script and something like NixOS. The most important difference is that with NixOS something that you don't specify won't be there. Whereas a bash script (or other config management tools like Puppet, Chef or Ansible) only mutate things listed.

So it is very easy to write a script like:

ensure_installed python3
write_file /etc/foo.cfg 'thing = 7'
chgrp users /mnt/backups

But if you remove ensure_installed python3 it will stay installed. You can try to be very careful and always add ensure_not_installed python3 but this is both error prone and dead code as soon as you run it. I used to have a script like this and I used each of configuration management tools mentioned above and always ran into these issues. The exact error flow would be something like this:

  1. Enable/setup some service A that pulls in package X.
  2. Disable service A or remove package X because it isn't needed anymore.
  3. Write configuration for service B.
  4. Forget to add ensure_installed X but it works anyways because X is still installed from step 1.

Now you have a non-reproducible config because if you try to re-install or setup service B on a new machine it won't work because X isn't present. This may sound like a niche problem but I ran into it almost every time I tried to bring up a new machine using my config.

It is still possible to do this in NixOS as it isn't completely reproducible (you can have mutable state) but in general it is much harder because any configuration that isn't specified doesn't exist. As soon as you remove package X or service Y from your config it is removed from your system. I've been using NixOS for 8 years now and this problem is mostly gone. It is definitely more reproducible than bash scripts and it has a tangible effect on my workflow.

I wrote a blog post about it a long time ago but the core is still relevant: https://kevincox.ca/2015/12/21/service-management-with-nixos/.

bloodfart@lemmy.ml · -3 pts · 3y

They don’t know about Debian stable.