Installing DietPi on an Apple Mac mini

An Apple Mac mini is a robust and stable PC based hardware with a low power consumption which can be used to install DietPi. Compared to Raspberry Pi SBCs, the PC based hardware gives enough options for larger memory, higher computational power and built in storage options.
This blog described how DietPi is installed on this hardware and how the WiFi can be activated.

IMG_4242
Mac mini 2012 front view
Mac mini 2012 rear view

The following use cases are examples which might be covered by an Apple Mac mini system:

  • Cloud storage (e.g. Nextcloud)
  • Backup storage
  • GUI systems
  • General software and memory intensive applications

Used/tested Mac mini models

The following Mac mini models, which can be used for installing DietPi, were tested:

Mac mini modelRecommendationCPURAM (max)Disk interface
Mac mini Mid 2011no (higher power consumption)Intel Core i5 and i7 2nd generation8 GB (official)SATA
2 x 2,5″ disks
Mac mini Late 2012recommendedIntel Core i5 and i7 3rd generation16 GB
(expandable)
SATA
2 x 2,5″ disks
Mac mini Late 2014recommendedIntel Core i5 and i7 4th generation16 GB
(fix onboard)
SATA
2 x 2,5″ disks
Mac mini model overview (Mid 2011 – Late 2014)

Power consumption of the Late 2012 and Late 2014 hardware is typically < 25 Watt.

Older Mac mini variants were not tested, but could be used. The 2018 Mac mini may have problems to boot Linux (at least it has a complex installation procedure), so this is also not recommended. The “Apple Silicon” Mac mini (M1) with its ARM architecture was not investigated.

Installation overview

The installation is executed in these steps:

  1. DietPi base installation with a LAN connection
  2. Additional settings via dietpi-config
  3. Optional: WiFi driver installation and usage of WiFi

Remark: The base installation must be done with a LAN connection. The installation image does not support a WiFi connection via ‘dietpi-wifi.txt’ (WiFi driver is installed in a second step).

Due to the fact that the standard DietPi Native PC installation image does not cover the WiFi chip of the Mac mini, the installation with a WiFi connection via ‘dietpi-wifi.txt’ is not supported.
If WiFi shall be used, the WiFi driver is installed in a second step.

Base installation

The base installation of DietPi on a PC based system is described in the DietPi docs: See the installation documentation, select the tab “Native PC” and follow the “UEFI installer image” instructions.

The difference to the documentation is that there is no need to change any BIOS settings to boot from the USB disk, USB stick or SD card: Just press the ‘Option’ or ‘Alt’ key during the boot (see there for explanations) and select the medium with the installer image. Then follow the instructions of the installer.

The result should be a system where you also did the first boot procedure (e.g. license acknowledge, basic settings via ‘dietpi-config‘ resp. ‘dietpi-software‘).

Additional settings

The following additional settings have to be made via dietpi-config:

  • Display options -> Display driver -> Install the ‘Intel GPU driver’
  • Advanced options -> RTC mode -> Hardware

WiFi usage (driver installation)

Remark: In the case that you only want to use a LAN connection and no WiFi, this step can be omitted.

The DietPi basic installation does not contain the WiFi driver package, dietpi-config shows in this case “Not Found”:

dietpi-config output without WiFi driver installed (Ethernet connected)

The Mac mini models contain e.g. these WiFi devices which are covered by the same driver:

  • Mac mini Late 2012: Broadcom Inc. and subsidiaries BCM4331 802.11a/b/g/n (rev 02)
  • Mac mini Late 2014: Broadcom Inc. and subsidiaries BCM4360 802.11ac Wireless Network Adapter (rev 03)

The installation procedure for the needed WiFi driver can be done with the following steps:

sudo apt-get update
sudo apt-get -y install linux-headers-amd64
sudo apt-get -y install broadcom-sta-dkms
sudo modprobe -r b44 b43 b43legacy ssb brcmsmac bcma
sudo modprobe wl

After this steps have been conducted, reboot your system and activate WiFi via dietpi-config in these steps:

  1. Detach the LAN cable
  2. Start dietpi-config
  3. Activate WiFi (do not forget to set the WiFi country code)
  4. Check the WiFi connection
  5. Disable Ethernet in dietpi-config

If this procedure fails, try to disable and enable WiFi again or reboot.

If all went well, dietpi-config should show

dietpi-config output with WiFi connected (Ethernet disabled)

Result

The htop screenshot of a base installation with graphical desktop on an 4 GB 2014 i5 Mac mini is shown below.
It shows a memory consumption of only about 460 MB.

References

  • https://wiki.debian.org/wl
Installing DietPi on an Apple Mac mini

Leave a Reply

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

Scroll to top