Skip Navigation

Installing Guix as a Complete GNU/Linux System - System Crafters

systemcrafters.net

Installing Guix as a Complete GNU/Linux System - System Crafters

Trying out Guix for the first time! Waiting for packages to download.

I'm a long time Arch user. Any tips?!

I've heard there aren't as many packages for Guix as other distros, but I was thinking Flatpak and distrobox will help bridge the gap for me.

31 comments
  • Expect a steep learning curve even if you know Linux inside out. Don't assume things work the way they did on Arch (or most other distros). If your hardware doesn't work well, or you otherwise need some proprietary stuff, check out https://gitlab.com/nonguix/nonguix. Good luck!

    • Yep. Totally using nonguix. I'm trying out Guix for the reproducibility and system management, not (just) for the FOSS software.

      From my initial research, I thought that Guix was only going to allow 100% FOSS software. But I've learned that's not the case. It's actually pretty easy to add additional channels in order to install non-FOSS software. The third-party channels integrate nicely!

      I added nonguix and also a channel for Tailscale!

       
          
      (list (channel
              (name 'nonguix)
              (url "https://gitlab.com/nonguix/nonguix")
              (branch "master")
              (introduction
                (make-channel-introduction
                  "897c1a470da759236cc11798f4e0a5f7d4d59fbc"
                  (openpgp-fingerprint
                    "2A39 3FFF 68F4 EF7A 3D29  12AF 6F51 20A0 22FB B2D5"))))
            (channel
              (name 'tailscale)
              (url "https://github.com/umanwizard/guix-tailscale")
              (branch "main")
              (introduction
                (make-channel-introduction
                  "c72e15e84c4a9d199303aa40a81a95939db0cfee"
                  (openpgp-fingerprint
                    "9E53FC33B8328C745E7B31F70226C10D7877B741"))))
            (channel
              (name 'guix)
              (url "https://git.savannah.gnu.org/git/guix.git")
              (branch "master")
              (introduction
                (make-channel-introduction
                  "9edb3f66fd807b096b48283debdcddccfea34bad"
                  (openpgp-fingerprint
                    "BBB0 2DDF 2CEA F6A8 0D1D  E643 A2A0 6DF2 A33A 54FA")))))
      
        
  • I quit on day two with two takeaways:

    – Hardware must be well supported in fully-libre-land - I was trying to install on a Mac Mini and had to go nonguix pretty much right away. That kind of spoiled the whole effort.

    – Profound meditation and enlightenment on the essence of Scheme is a must. I had one of those 'no, this is where you don't want a closing brace' moments and my zen was blown out of the water.

    I would have soldiered on, but personally I like Arch first and foremost because I can (and do) have a local repo by rsyncing a rotation of mirrors couple of times a week. Just in case the Internet dies one day, you know. I realised Guix was not really suitable for the apocalypse use case, so after that brace episode I decided to stick with what my spine already knows.

    After all that is said – I really hope you fare better :D

    • Hardware must be well supported in fully-libre-land ... had to go nonguix pretty much right away.

      Yep, same here. I started with nonguix. I didn't realize it was easy to add additional channels.

      Profound meditation and enlightenment on the essence of Scheme is a must. I had one of those ‘no, this is where you don’t want a closing brace’ moments and my zen was blown out of the water.

      Aaaah. I juuuust had this happen to me. Took me a bit to balance the parens again! 😂 Although, so far Scheme seems nicer than Nixlang. I've also had curiosity to learn a functional language, so Guix gives me a reason to learn about functional programming.

    • personally I like Arch first and foremost because I can (and do) have a local repo by rsyncing a rotation of mirrors couple of times a week.

      Are these mirrors for prebuilt packages? If not, you should be able to pull from other channels, create your own channel and include all your packages while building them locally.

      • Sure, but then I'd be downloading every single source 'package' and compiling for both x86 and ARM - not exactly feasible. Keeping just the sources might be an option though. The point is to have the whole repo, not just the packages I use, so that in the SHTF scenario I can help others install Arch and any software they may need on their machines. Muhahaha, Arch will prevail 👻

    • I've also wanted to try out Guix for a while.. part of the reason I'm leaving a comment is just so I can recheck these posts later :P

      But when I do I for sure will start out from nonguix because I'm quite confident that my hardware won't be supported (I even have a recently purchased Wifi 7 card that relies on ath12k module that I'm quite sure won't be in the official Guix repo.. maybe I'd even need to compile it myself..)

      I see in the nonguix readme that there's a way to generate an iso that includes already a nonguix kernel, so I'll have a look at that.

      It even looks like you can create a writeable image to run from a USB thumbdrive, which looks very interesting, I gotta try that!

       
          
      guix system image --image-size=7.2GiB /path/to/this/channel/nongnu/system/install.scm
      dd if=/path/to/disk-image of=/dev/sdb-or-whichever-drive-is-usb bs=4M status=progress oflag=sync
      
        

      I've been burnt by Arch before which is what has got me into exploring other distros. I might ultimately end up again in Arch like you, who knows, but it looks like the way Guix works is well suited for hosting your own repo too.. I think I've seen before someone hosting their own Guix repo in github, including also a bunch of configuration for their system, which got me curious.

  • I want to love Guix (both the package manager and the distro). I want to love Scheme. But I can never find any good tutorials for Scheme and using it with Guix. The GNU documentation is more of a reference than a tutorial. I use Emacs on the daily, and I just can't get into Scheme.

    • I use Emacs on the daily, and I just can’t get into Scheme.

      Do you find that Elisp and Scheme are too different? I don't know either, so they look almost the same to me.

  • Btw, here's how you install distrobox on Guix.

    First, install rootless Podman: https://guix.gnu.org/manual/devel/en/html_node/Miscellaneous-Services.html#Rootless-Podman-Service.

    You need to edit your /etc/config.scm or where ever you store your system config. Import the right modules/services, add your user to cgroup, add iptables-service-type to your services, add rootless-podman-service-type and configure it.

     
        
    (use-service-modules containers networking …)
    (use-modules (gnu system accounts))  ;for 'subid-range'
    
    (operating-system
      ;; …
      (users (cons (user-account
                    (name "alice")
                    (comment "Bob's sister")
                    (group "users")
    
                    ;; Adding the account to the "cgroup" group
                    ;; makes it possible to run podman commands.
                    (supplementary-groups '("cgroup" "wheel"
                                            "audio" "video")))
                   %base-user-accounts))
      (services
        (append (list (service iptables-service-type)
                      (service rootless-podman-service-type
                               (rootless-podman-configuration
                                 (subgids
                                   (list (subid-range (name "alice"))))
                                 (subuids
                                   (list (subid-range (name "alice")))))))
                %base-services)))
    
    
      

    Then of course you run guix system reconfigure /etc/config.scm.

    Now you can do a simple guix install distrobox. If you install distrobox first, you don't end up using rootless podman and you run into more problems that way. (You have to use distrobox --root.)

    After that command, everything should work like normal. Enjoy. 🍻

     txt
        
    distrobox create --image docker.io/library/archlinux:latest --name arch-dev
    distrobox enter arch-dev
    
      
  • Btw, here's how you configure HiDPI for GNOME. Unfortunately, my laptop has a hydeepeeay display, so it's not fully compatible with Linux. (It's 3840x2160, so at least 2x scaling is possible, hypothetically.)

    Commands from the Arch Wiki, but also adds cursor scaling:

     
        
    $ gsettings set org.gnome.settings-daemon.plugins.xsettings overrides "[{'Gdk/WindowScalingFactor', <2>}, {'Gtk/CursorThemeSize', <48>}]"
    $ gsettings set org.gnome.desktop.interface scaling-factor 2
    
      

    The default GNOME configuration is some how missing that. I didn't have to do that in Arch, but I do in Guix. IDK. Anyway, if you don't run those commands certain apps will be tiny, including a tiny mouse cursor.

31 comments