The Ultimate Linux Workstation on an Apple M1 (ARM64) Processor

My introduction to Asahi Linux began in March of last year when Asahi’s alpha version was released. I immediately installed it on my Mac Mini with an 8-core Apple M1 (ARM64). Asahi is a Linux distribution that runs natively on Apple Silicon Macs thanks to clever hacks and reverse engineering from the Open Source community. What’s more, Asahi’s launch is completely legal, as Apple officially allows non-macOS operating systems to be loaded on its Apple Silicon platform.

The word Asahi translates as “morning sun”. And this is not only a well-known brand of Japanese beer, but also a Linux distribution, which is named so in order to emphasize the primacy of the development team in mastering the Mac platform.


When I installed Asahi, only basic hardware drivers were available for it (xNVMe, keyboard, trackpad, Wi-Fi, Ethernet, USB, etc.). However, I installed the distribution and was surprised how fast the system turned out to be,
blogging about your experience. By the end of the year, almost all the necessary drivers were released (Bluetooth, audio, graphics were added). As a result, all the packages that I needed were adapted for 16K memory pages in Apple Silicon.

Asahi’s performance on the M1 is simply impressive. Compiling Chromium 102 on Fedora Linux on a Core i9 took just over an hour – and only 12 minutes on Asahi.

As for graphical tasks, Asahi excels here as well. I have never seen KDE, GNOME, LibreOffice, Gimp, Inkscape, Firefox run so fast before. Games (SuperTuxKart) just fly, VLC videos and YouTube work perfectly too.

That’s when I got the idea to run Asahi Linux on Apple’s fastest Apple Silicon Mac. This would be the perfect ARM64 Linux workstation, I thought, and decided that I would definitely do it.

Take it to the next level with Asahi Linux

This past January, I installed Asahi Linux on Apple’s most powerful ARM64 system, a Mac Studio with a 20-core M1 Ultra processor and 128GB of RAM. It pairs with Dell’s stunning 34″ Widescreen Curved Monitor via HDMI.

That’s when I decided to switch from the i3 window manager (which should run on the legacy X Window System) to the sway compositor for the new Wayland. It turned out that sway works better and uses a more efficient configuration.

Below is a high resolution screenshot of my sway desktop on Mac Studio (right click available in original resolution). You can find my custom configuration sway dotfiles in the GitHub repository.



sway

Is there anything that doesn’t work in Asahi?

This question can be answered with the words of Hamlet in the third act of the tragedy of the same name, line 87:

“No”

.

Everything you need works… and works great. The hardware (Bluetooth, audio, HDMI, USB, 10G Ethernet, WiFi and graphics) work flawlessly with the drivers created by the Asahi development team last year, and there is not a single software package that I need that doesn’t work on my system. .

Most of the software I installed comes from the Arch repository, as Asahi Linux is based on the Arch Linux package base and built using the stock Arch Linux repositories.

But some (such as Visual Studio Code) are installed as isolated modules using the Flatpak utility, which provides a dedicated environment for running applications isolated from the main host system, which makes it possible to use them regardless of system changes. For more complex software systems, I use ready-made Linux container images, as is the case with NextCloud. From the htop output in the screenshot above, you will also notice that I am using a minimalistic build of Kubernetes to test the k3s microservices I am developing.

Since I use containers for most of my work projects, there is no need to run other Linux virtual machines. However, you have to work with web applications that require FreeBSD. Especially for her, I installed a QEMU virtual machine using eight cores and 64 GB of RAM. Below is a photo of the vm console running in the terminal on the sway desktop. You can find my QEMU script in the GitHub repository.


FreeBSD virtual machine

The fastest Linux desktop in my life

Thanks to Asahi Linux, I have the fastest Linux desktop in my life. Everything – and I mean absolutely everything – works incredibly fast. The software launches instantly, and application splash screens don’t seem to exist at all.

In some cases this happens too much fast. When I installed K3s, all containers in the kube-system namespace, dedicated to objects created by Kubernetes, were constantly going into a terrible CrashLoopBackOff state. After a little investigation, I found that Mac Studio was too fast for syncing Kubernetes resources. To fix the situation, I had to add restrictions for each module.

One of the main reasons I chose Linux/ARM64 is that the startup I’m currently working with runs a heavy, high-load application with microservices that runs on an AWS c6g.12xlarge Graviton instance with 48 ARM64 cores. We built our own load modeling and performance monitoring microservices into it.

I ran the application and boot simulation in my Mac Studio running Asahi to see how it all works in our staging environment on AWS. Well, the Mac Studio desktop is head and shoulders above the 48-core Graviton instance. The latency at the same load was about 20% lower on average, and the calculations were 36% faster.

In the end, it turned out that I had an almost perfect ARM64 Linux workstation in my hands. And I love her.

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *