How to convert an old ChromeBook into a NixBook
I have a confession. I kinda like Chromebooks.
Yes, I know they’re usually cheap and crappy hardware. Yes, I know ChromeOS is super limiting and its the kind of machine you’d give to your parents or kid. However, in trying to be the perfect computer for those people, they get a few things right at the same time.
- They ARE cheap which means you can throw them in your bag and head out anywhere you want for the weekend and don’t have to be overly worried that you’re going to damage your $3,000 MacBook Pro.
- They’re usually built pretty sturdy. Remember, these are kinda aimed at schools and kids, which means they need to be durable. So maybe even skip the case and literally toss it on the passenger seat of your car. It won’t care.
- Low power usage. Yes, this is because of the low end processor in there, but as a result most are fanless, and get more battery life than most of the ultra books that sell for 10x that much.
In fact, the biggest PROBLEM that Chromebooks have is that they’re tied to ChromeOS. I’m not anti-google or even anti-chrome, but I DO hate having to log into my google account to simply get into my computer. And once you’re in, everything you want to do is in the cloud. There isn’t much you can do without an internet connection.
Then there is the bigger problem. Google only supports these machines for a number of years, and then they’re basically abandoned hardware, and Google wants you to throw it in the trash and get a new one :(
BUT what if you didn’t HAVE to throw a perfectly good piece of hardware in the trash? What if you could put a modern, up-to-date, secure, and rock stable operating system on it. One that wouldn’t just bring it back to life, but allow it to do things it could have never done on ChromeOS.
What if we could put Linux on it? Not just any Linux, but an immutable, flexible, bullet-proof Linux.
What if…. we made it a NixBook??!?!
The Hardware
For this tutorial, I got my hands on a Lenovo N42 at a discount electronics store for about $30 on sale. Even NOT on sale, you can pick one of these up for about $50. But in theory, this tutorial should work on most ChromeBooks. I purposely choose one with an x86 Intel processor and suggest you do the same. Depending on what hardware you use, your mileage may vary.
Step One — Jailbreak It
We don’t just want to install Linux ON TOP of ChromeOS, we want to completely replace ChromeOS. For that we’ll need to do some tricks to replace the firmware to allow us to boot to our own OS.
When you’re logged in, press Esc + Refresh + Power all at the same time. The screen will go black and then after a few seconds you’ll see this lovely screen welcoming you to recovery mode.
Once you see that yellow exclamation point, press Ctrl + D, which will get you into DEVELOPER MODE and will take off the child safety locks so we can really play!
At this screen it’s warning you that you’re turning the OS verification OFF and your Chromebook will be completely reset, only this time in DEVELOPER MODE! You can handle it, so press Enter and let’s go!
On reboot, it will once again warn you about the dangers of outside Operating Systems. Don’t fall for the bait. Don’t press space! Just stare at it until it accepts your decision.
Hey look, another warning! After a bit more of this, the Google lawyers should be satisfied, and you’ll log back in with your Google Account like it’s a new Chromebook.
Once logged in, open up Chrome, and press Ctrl + Alt + T which will bring you to a shell. But this is one of those fake “chrosh” shells. We want the real thing, so type in “shell” and press enter. Oh yeah, that’s it!
In a different chrome tab, go to mrchromebox.tech, and click on the “Firmware Utility Script”. You’ll see the line of code you can copy into terminal prompt. This basically just downloads and runs the script that will allow you to unlock your bootloader. I know it’s not always a great idea to go copy and pasting shell scripts from the internet, but this one has my stamp of approval. And I know what I’m doing…. kinda.
Once you copy and paste that script in, it will do things, and finally bring you to here:
Now, this is the step that might differ for you depending on what model Chromebook you have. This screen will show you information about your hardware and if there is any Write Protection for your machine. Some of these Chromebooks you have to take apart and remove a screw, but this one has no such issues, and is writable out of the box. If you see any RED [WP] flags here, you’ll need to google your exact model and see how to remove the write protection (usually a screw).
But once option 2) is green and clear for take off, go ahead and type 2.
Are you really really really really super duper mega sure? [Y/n]
Once you are, it will do more things, take a while then ask you to reboot into your NEW UNLOCKED Chromebook!
The first boot takes a while, but will show up. You’ll see the fun little rabbit, and hit ESC and you’ll see a more familiar looking BIOS screen with options you might see on a regular computer. Congrats! Now we can start setting this up.
Step Two— Nix It
Now that we have an open boot loader, let’s get NixOS on here ASAP. Go download the ISO and put it on a thumb drive. You can check out my Getting Started with NixOS article if you want details on where to go to get the ISO.
Once you have it on a USB drive and stick it in, boot up the Chromebook, hit Esc, go into the boot menu, and select your drive.
Isn’t this beautiful? Just select the normal installer option like normal.
The installer is in Gnome, which is pretty heavy for this hardware, but don’t worry, we’ll be using a different desktop environment for the real thing. Once it fully boots up, close the installer, then connect to wifi in the upper right corner.
Once you’re connected to wifi, click on “Activities” in the upper left then select Install System from the dock.
Go through the usual steps of location, keyboard and setting up your user. And for the Desktop part, choose “No desktop”
You can be hardcore about totally free software if you want. But most of us will just check off “Allow unfree software”
You’ll want to choose Erase disk, and I always do Swap (no Hiberate). If you’re REALLY strapped for space, maybe choose no swap if you have enough RAM. This system has a very pathetically small 16g eMMC, but I’m still able to enable swap and use it.
And that’s it! Just check restart now, and restart into NixOS! (did you think installing NixOS would be hard?)
Once you reboot, you have to just login at a terminal because we have no GUI yet. But this is where things get fun! Once you’re logged in, type “nmtui” and connect to wifi.
Once you’re connected to wifi, let’s edit our nix config file and make this thing usable. Sadly, nano is the default editor, so we can just use that. (if you’re super offended by nano, you CAN just type “nix-shell -p neovim” and edit this file like a gentleman)
sudo nano /etc/nixos/configuration.nix
Believe it or not, we only have to add a handful of lines to this file to get everything we want. I’m going to choose Cinnamon as a Desktop environment and install just a few apps, but you can get the package names for nearly anything here ( https://search.nixos.org/packages )
I always look for the # Allow Unfree section and just add this code right under that, but you can really put this anywhere in the file.
services.xserver.enable = true;
services.xserver.desktopManager.cinnamon.enable = true;
services.xserver.displayManager.lightdm.enable = true;
Then, find “environment.systemPackages = with pkgs; [“ and add your packages under it. This is really all you need for a basic Chromebook clone. Chrome, zoom and office.
environment.systemPackages = with pkgs; [
google-chrome
zoom-us
libreoffice
];
Save that file, and then type the magic words:
sudo nixos-rebuild boot
NixOS will pull down your packages, build out your whole system, then drop you at the terminal. Type “reboot”, and just like that, you’ll be in!
I purposely chose the Cinnamon Desktop environment, as it’s pretty light, while still being slick and modern looking. The design is also very familiar to anyone who’s used windows or a Chromebook. You can customize it quite a bit to fit your needs. If you need to install more software, you can simply edit that file from above, add your software, and you can even avoid a reboot by simply running:
sudo nixos-rebuild switch
To update the system, just run the above command, but add “ — upgrade”
sudo nixos-rebuild switch --upgrade
You’ll also notice on reboots, you can choose to reboot into older versions. To clean those up and just keep your current working version, run
sudo nix-collect-garbage -d
As you can see, it’s possible to take that old Chromebook and make it useful again. Following this guide gets you a system that’s modern and usable with only using ~500m of ram on boot.
This was also a super basic crash course on NixOS, but there is SO MUCH more you can do if you want. I was also keeping things super lean here, but it’s also trivial to enable flatpak and have all of flathub at your fingertips too. (https://flatpak.org/setup/NixOS)
On a personal note, I did this upcycle a couple months ago, and when I was finished playing with the Chromebook and taking pictures, I donated it to someone locally who really needed a computer. I recently checked in with him and he’s using the computer daily to finish online classes and is even using it to find work, and stay in touch with friends and family. All this from a machine that “too old to be useful”