From the archive
Running Arch Linux on iMac late 2013 (27 inch)
What did I do with my iMac?
Finally, I got bored with macOS.
I bought my first Mac computer in March 2014, which is a 27-inch iMac. I liked it, so I bought another MacBook Pro, and I’ve been using macOS since, until about a week ago.
I installed Arch Linux on my iMac, and here are some highlights:
- It uses EFI boot, using GPT partitioning on one 1T HDD.
- It is running ZFS on the root partition.
- It is using dm-crypt for full-disk encryption.
- It is using an Nvidia 775M, driving 2 external 1440p monitors, so 3 x 1440p monitors in total.
The installation process
It was challenging and fun
I am not going to list a step-by-step guide, as the way I did it may not be the way you want your system to be, and I believe as an Arch Linux user you are not expecting a step-by-step guide, are you?
To be able to install them properly, I would suggest you carefully read the Arch Linux wiki pages about these few things:
- ZFS (https://wiki.archlinux.org/index.php/ZFS), especially the root on ZFS section.
- dm-crypt (https://wiki.archlinux.org/index.php/Dm-crypt), this is used to encrypt your disk.
- rEFInd (https://wiki.archlinux.org/index.php/REFInd), to help you understand how EFI booting works.
Also you may want to learn a little bit more about ZFS before you start:
- The Z File System by Allan Jude (http://www.allanjude.com/bsd/zfs.html)
- ZFS Primer by FreeNAS team (https://doc.freenas.org/9.3/zfsprimer.html)
The idea is like this
- You want to use rEFInd to boot to a FAT32 partition, looking for a config file
/boot/refind_linux.conf. - The config file will tell dm-crypt that this is an encrypted drive, so the kernel will load dm-crypt and you will be asked to enter your password.
- Then after dm-crypt maps the drive to a virtual device like
/dev/mapper/something, ZFS will start to import the pool, and mount different partitions accordingly based onmountpointsettings. - After ZFS mounts your root, your system will then boot successfully.
The result
In general it’s pretty good.
- I am running Gnome. I was going to try KDE, but it crashed every time I wanted to unlock a panel… Therefore…
zfs rollback ... - Most of the devices just work, including Wi-Fi, Bluetooth, camera, microphone and speaker. Even the 3-monitor config works
out of the box if you install the
nvidiadriver that ships with Arch Linux. - Suspend and wake-on-LAN are both working out of the box.
Only one thing before I can say it’s perfect:
- Switching between the speaker and headphones does not work perfectly. Sometimes I try to unplug the headphones but the speaker still does not make any sound (even though Test Speakers works), but after a while it’ll be back again.
In conclusion
I know I am running Arch Linux (lovely rolling release distro) on an iMac (super Linux “friendly” hardware),
but I’ve got ZFS, so if the update ruins anything, zfs rollback ....