
TL;DR
Table of Contents
- NixOS is a declarative Linux distribution that uses the Nix package manager to build an immutable Nix store and reproducible system configurations.
- Install with the Calamari GUI installer (or minimal ISO) and manage your entire system through /etc/nixos/configuration.nix.
- Every change is a new generation: sudo nixos-rebuild switch creates a fresh, atomic upgrade that you can roll back instantly.
- GNOME Software is only useful for Flatpaks on NixOS; system packages live in the Nix store.
- For daily use, NixOS behaves like a normal desktop but gives you full reproducibility, atomic upgrades, and a single source of truth for your machine.
Why This Matters
I’m a Linux hobbyist who has spent years juggling manual apt install, editing etc/apt/sources.list, and dealing with “dependency hell” on Ubuntu. Each new OS I tried (Fedora, Mint, even Debian) required a fresh set of manual tweaks to get my workflow running. When I stumbled across NixOS, the promise of a declarative configuration model – one file that dictates everything from installed packages to services – seemed like a dream. That promise translated into a system that’s reproducible across machines, atomic upgrades, and the ability to roll back to a previous state with a single command.
The pain points I faced before NixOS – time-consuming package installs, configuration drift, broken upgrades – disappeared as soon as I started editing configuration.nix. My desktop behaved exactly as I defined it, and I could share that definition with a friend or a server environment with confidence.
Core Concepts
Declarative Configuration
NixOS’s hallmark is a declarative configuration model that treats the entire system as code. Every setting – from kernel modules to user accounts – is described in /etc/nixos/configuration.nix and applied via sudo nixos-rebuild switch NixOS Wiki — Overview of the NixOS Linux distribution (2026). This is a pure functional approach: the same input yields the same output, guaranteeing reproducibility.
The Nix Store
All packages are built into the Nix store at /nix/store. Each package is immutable and stored under a unique hash, ensuring that once a package is built, it never changes. The store is isolated from /home, /var, and /etc, keeping system state separate from user data Nix Store — Nix Reference Manual (2026). This immutability is the bedrock of NixOS’s atomic upgrades.
Atomic Upgrades & Rollbacks
Running sudo nixos-rebuild switch creates a new system generation in the Nix store. The bootloader points to this new generation, and the previous one remains available for instant rollback. If a new configuration fails, I can boot the old system by selecting it from the boot menu or by running sudo nixos-rebuild switch –rollback Nixos-rebuild — NixOS Wiki (2026). Each generation is a snapshot, and you can keep dozens of snapshots without any overhead.
Functional Package Management
The Nix package manager (nix-env and nixpkgs) is a functional system: packages are built from pure functions without side effects. The result is a declarative, reproducible package set that can be shared across environments.
How to Apply It
Below is my step-by-step workflow, from ISO download to a working desktop. I use the Calamari GUI installer for a smooth experience.
- Download the ISO – choose the graphical ISO from the official download page: https://nixos.org/download/.
- Boot the ISO – the Calamari installer launches automatically. I select the GNOME desktop during the installation wizard.
- Configure partitioning – Calamari handles partitioning for me; I simply confirm the default layout.
- Generate the base configuration – Calamari writes a minimal configuration.nix in /etc/nixos and runs nixos-rebuild switch.
- Edit configuration.nix – add my preferred packages:
{ pkgs, ... }: { environment.systemPackages = with pkgs; [ vim htop git ]; services.gnome.gnome-display-manager.enable = true; } - Rebuild – sudo nixos-rebuild switch applies the changes atomically.
- Enjoy GNOME – the desktop launches with the packages I declared.
If you prefer a minimal image (no GUI installer), download the minimal ISO and install manually:
- Extract the ISO to a USB.
- Boot, run nixos-generate-config –root /mnt.
- Edit the generated /mnt/etc/nixos/configuration.nix.
- Reboot into the new system.
The key takeaway: any change is a commit in the configuration file, and the rebuild step ensures that the system transitions cleanly and can be reverted instantly.
Pitfalls & Edge Cases
| Pitfall | Why it happens | Mitigation |
|---|---|---|
| Driver updates breaking hardware | New kernel modules may not be in the store | Pin the kernel package via boot.kernelPackages = pkgs.linuxPackages_xxx; |
| Networking mis-configuration | NixOS requires explicit service settings | Use networking.firewall.enable = false; or consult the networking module documentation |
| CI pipeline integration | CI environments need reproducible builds | Use Nix CI or GitHub Actions with nix-build to produce reproducible artifacts |
| Enterprise deployment | Managing many machines | Use nixos-deploy or Ansible with NixOS modules |
| Security concerns | Using immutable store vs. user space | Separate user packages with home-manager to keep user data in ~/.config/nixpkgs |
| Migration from other distros | Existing configs not compatible | Use nixos-infect or nixos-in-place to convert existing systems |
These edge cases often surface when you start pushing NixOS into production or a multi-user environment. The community has robust tooling to address them, but the learning curve can be steep for beginners.
Quick FAQ
Q1: What is the difference between the Nix store and /etc/nixos? A1: The Nix store (/nix/store) holds immutable, pre-built packages; /etc/nixos contains the declarative configuration that tells the system which packages to use.
Q2: Can I use GNOME Software to install system packages? A2: On NixOS, GNOME Software is primarily a Flatpak manager; system packages are installed via configuration.nix Flatpak — NixOS Wiki (2026).
Q3: How do I roll back to a previous system state? A3: sudo nixos-rebuild switch –rollback or select the previous generation from the boot menu.
Q4: Does NixOS support Flatpak? A4: Yes – enable services.flatpak.enable = true; in configuration.nix and use GNOME Software or the flatpak CLI.
Q5: Is NixOS suitable for a daily driver? A5: Absolutely – many developers use NixOS as a daily desktop with GNOME or Xfce, enjoying reproducibility and atomic upgrades.
Q6: Can I install NixOS on an existing Ubuntu installation? A6: Use nixos-infect or nixos-in-place to convert an existing system into NixOS.
Q7: What about driver updates and hardware support? A7: Pin kernel packages or add the appropriate hardware modules via boot.kernelModules. NixOS has strong community support for most hardware.
Conclusion
If you’re tired of manual package installs, configuration drift, and scary upgrade failures, NixOS offers a paradigm shift. Its declarative model, immutable Nix store, and atomic rebuilds give you confidence that your system will behave exactly as you describe it. The learning curve is real, but the payoff – reproducibility, instant rollbacks, and a single source of truth – outweighs the initial effort.
Who should use NixOS? System administrators, developers, and power users who want reproducible environments. Who shouldn’t? If you’re content with the traditional package manager workflow and don’t want to learn a new configuration language, NixOS might feel like overkill.
The next step? Grab the ISO, install Calamari, write your first configuration.nix, and let the system build itself for you. You’ll quickly discover that the declarative approach isn’t just theoretical – it’s a practical tool that can transform how you interact with your machine.
References
- NixOS Wiki — Overview of the NixOS Linux distribution (2026) – https://wiki.nixos.org/wiki/Overview_of_the_NixOS_Linux_distribution
- Nix Store — Nix Reference Manual (2026) – https://nix.dev/manual/nix/2.24/store/
- Nixos-rebuild — NixOS Wiki (2026) – https://wiki.nixos.org/wiki/Nixos-rebuild
- Calamari Installer — NixOS Discussion (2026) – https://silky.github.io/posts/nixos-latest-kernel.html
- Flatpak — NixOS Wiki (2026) – https://wiki.nixos.org/wiki/Flatpak


