mac-install-ubuntu

install ubuntu on mac

#

  • example (2017 05)

better install the latest lts or the latest!! here the example i need
another old version ubuntu for some outdated short support
(.. and at present vbox almost cannot work..),
later will upgrade to the latest!!

* ubuntu 14.04.5 desktop amd64
* macbookpro

install

download ubuntu

http://mirrors.163.com/ubuntu-releases/14.04.5/ubuntu-14.04.5-desktop-amd64.iso

create startup disk / udisk

use “startup disk creator”

mac partition in recovery mode

  • press command + R to recovery mode when boot
  • repair disk error in recovery mode
  • partition

install ubuntu

  • plug startup udisk to mac
  • press option/alt to choose boot media: usb
  • install ubuntu and not reboot when finish

config efi boot

sudo apt-get install efibootmgr
sudo efibootmgr

# let boot to ubuntu
sudo efibootmgr -o 0, 80

reboot to ubuntu

config macos boot

  • edit /etc/grub.d/40_custom, add:
menuentry "macos" { exit }
  • edit: /etc/default/grub
    • original:
GRUB_DEFAULT=0
GRUB_HIDDEN_TIMEOUT=0
  • modified
GRUB_DEFAULT=2
#GRUB_HIDDEN_TIMEOUT=0
  • or modified (mac default)
GRUB_DEFAULT=2
#GRUB_HIDDEN_TIMEOUT=0

apply macos boot config

sudo update-grub

# here install to /dev/sda
sudo grub-install /dev/sda

reboot and done

troubleshoot

if wireless fail because use ‘bcmwl-kernel-source’, try below to fix:

  • full remove bcmwl-kernel-source
sudo apt-get purge bcmwl-kernel-source
  • force shutdown
  • power on and boot
  • so maybe not try to enable the broadcom addtional driver!!

fix ~

  • add below to /etc/rc.local
echo 0 > /sys/module/hid_apple/parameters/iso_layout

see also