I want to use Linux on mac

Preface

I wrote it when an acquaintance asked me to teach me how to dual boot on a mac. I wrote an article because it was a big deal.

Step 1: Download rEFInd

Download rEFInd and place it in any directory.

Step 2: Install rEFInd

To install rEFInd, first start your mac in recovery mode (hold down cmd + R) After booting into recovery mode, open a terminal and run csrutil disable.

--Tips: There are restrictions on what you can do with sudo privileges, and this is a command that removes those restrictions.

When run, it will display Succesfully disabled System Intergrity Protection..

Then start your mac and change to the directory where you downloaded rEFInd.

tikuwa@tikuwanoMacBook-Air ~/Downloads/refind-bin-0.11.4 $ ls -al ~/Downloads/refind-bin-0.11.4
total 472
drwxrwxr-x@ 17 tikuwa  staff    544 11 12  2018 ./
drwx------+ 53 tikuwa  staff   1696  2 21 12:13 ../
-rw-rw-r--@  1 tikuwa  staff  35147 11 29  2015 COPYING.txt
-rw-rw-r--@  1 tikuwa  staff   4891  8  7  2017 CREDITS.txt
-rw-rw-r--@  1 tikuwa  staff   2204 11 29  2015 LICENSE.txt
-rw-rw-r--@  1 tikuwa  staff  99811 11 12  2018 NEWS.txt
-rw-rw-r--@  1 tikuwa  staff   4010  5 25  2017 README.txt
drwxr-xr-x@  5 tikuwa  staff    160 11 29  2015 banners/
drwxr-xr-x@  5 tikuwa  staff    160 10 22  2018 docs/
drwxr-xr-x@ 18 tikuwa  staff    576  7 22  2018 fonts/
drwxr-xr-x@ 22 tikuwa  staff    704  1 20  2016 keys/
-rwxrwxr-x@  1 tikuwa  staff   2436  7 22  2018 mkrlconf*
-rwxrwxr-x@  1 tikuwa  staff   2564  8 24  2018 mountesp*
-rwxrwxr-x@  1 tikuwa  staff  10362 10 23  2018 mvrEFInd*
drwxrwxr-x@ 13 tikuwa  staff    416 11 12  2018 rEFInd/
-rwxrwxr-x@  1 tikuwa  staff  56558 11 12  2018 rEFInd-install*
-rwxrwxr-x@  1 tikuwa  staff   7173  4 23  2016 rEFInd-mkdefault*

Run sudo ./rEFInd-install in that directory and reboot. If rEFInd starts, it's successful.

tikuwa@tikuwanoMacBook-Air ~/Downloads/refind-bin-0.11.4 $ sudo ./refind-install                                             [ruby-2.6.3p62]
Password:
ShimSource is none
Installing rEFInd on OS X....
Installing rEFInd to the partition mounted at /Volumes/ESP
Found rEFInd installation in /Volumes/ESP/EFI/rEFInd; upgrading it.
Found suspected Linux partition(s); installing ext4fs driver.
Installing driver for ext4 (ext4_x64.efi)
Copied rEFInd binary files

Notice: Backed up existing icons directory as icons-backup.
Existing rEFInd.conf file found; copying sample file as rEFInd.conf-sample
to avoid overwriting your customizations.

Step 3: Create Linux installation media

Please prepare a USB flash memory. It depends on the OS you install, but ideally it should be at least 8GB. This time, install Ubuntu.

Download the Ubuntu DVD image. After the download is complete, place it in a convenient location.

Then download balenaetcher. You can install it with brew cask install balenaetcher.

Start balenaetcher and select an image with Select image. Then select the installation media with Select target. Finally, select Flash! To start the installation.

Step 4: Create partition for Linux

To install Linux, you need two partitions, one for the / and one for the Swap area.

The partition used for / works if it is 10GB or more, but it is better to set it to 100GB or more because it will be installed. Swap space should be about twice as much as RAM.

Step 5: Install Linux

With the media created in step 3 stuck, restart your mac and start rEFInd. When rEFInd starts, you can select the installation media. Then follow the instructions on the screen to install.

Step 6: Set rEFInd to start

After installing Linux, the boot loader used will be changed to GRUB for Linux. So run refind-install again.

Once that's done, reboot into recovery mode and then run csrutil enable to boot your mac.

--Tips: This command can be used without any problem, but it is better to execute it for security reasons.

Step 7: Remove GRUB

You can skip this step without any problems, so skip it if you don't mind. First, go to / Volume and run sudo mkdir efi. Then run sudo mount -t msdos / dev / disk0s1 ./efi.

Once mounted, go to ʻEFI inside ʻefi and remove ʻUBUNTU`. Then reboot and make sure it is deleted.

Bonus: Make rEFInd look cool

Search for "rEFInd themes" and download your favorite theme. This time, we will use "rEFInd minimal". Go to / Volumes / efi / EFI / refind and create a directory called themes. Put the downloaded theme in it and name it rEFInd-minimal.

Next, open refind.conf in / Volumes / efi / EFI / refind with a text editor and add ʻinclude themes / rEFInd-minimal / theme.conf`.

When you're done, reboot and make sure it's reflected.

References

Install bootloader rEFInd on mac When introducing rEFInd to El capitan How to change the theme of boot loader "rEFInd"

Recommended Posts

I want to use Linux on mac
I want to use OpenJDK 11 on Ubuntu Linux 18.04 LTS / 18.10
I want to log file I / O on Linux
I want to AWS Lambda with Python on Mac!
I installed Linux on my Mac
When you want to use python2.x on modern Gentoo Linux
I want to know how LINUX works!
I want to use jar from python
I want to use IPython Qt Console
I want to develop Android apps on Android
I want to use Mac / emacs key bindings (keyboard shortcuts) on Ubuntu xkeysnail recommendations
I want to know if you install Python on Mac ・ Iroha
I want to use MATLAB feval with python
I want to use Temporary Directory with Python2
I want to use ceres solver from python
I don't want to use -inf with np.log
I want to use ip vrf with SONiC
I want to do pyenv + pipenv on Windows
I want to use the activation function Mish
Preparing to use aws cli on Mac OS X
I want to use self in Backpropagation (tf.custom_gradient) (tensorflow)
How to use C216 Audio Controller on Arch Linux
Use Github Desktop on Linux
I tried to use Resultoon on Mac + AVT-C875, but I was frustrated on the way.
I want to find a popular package on PyPi
I want to solve Sudoku (Sudoku)
Update python on Mac to 3.7-> 3.8
Preparing to use Ansible on an existing Linux server
I tried to reintroduce Linux
Use matplot libwidget on mac
Use sshpass on Amazon linux2
When I try to use Jupiter notebook on Mac, I can only select python2
I want to realize something like AutoHotkey with AutoKey on Ubuntu (Kali Linux)
I want to restart CentOS 8 on time every day.
[Tips] How to use iPhone as webcam on Linux
I want to use the R dataset in python
Use Linux on Windows 10 (WSL2)
I want to do Wake On LAN fully automatically
I want to be notified when the command operation is completed on linux!
I want to use Linux commands at the command prompt! Use Linux commands at the command prompt instead of Git Bash
I want to use the latest gcc without sudo privileges! !!
I want to use R functions easily with ipython notebook
I want to move selenium for the time being [for mac]
[For beginners] How to use for statements on Linux (variables, etc.)
I want to use only the normalization process of SudachiPy
[Python] I want to use the -h option with argparse
I want to disable interrupts on Raspberry Pi (≒ DI / EI)
I want to announce my graduation thesis on IPython Notebook
I want to use a virtual environment with jupyter notebook!
[AWS EC2] Settings you want to do on Amazon Linux 2
What to do if you can't use WiFi on Linux
[Introduction to Mac] Convenient Mac apps and settings that I use
I want to use VS Code and Spyder without anaconda! !! !!
Use host.docker.internal on linux (docker-compose required)
Easy copy to clipboard on Linux
How to use Dataiku on Windows
Steps to install matplotlib on Mac
Convert wma to mp3 on Mac
I want to understand systemd roughly
Notes on how to use pywinauto
How to install VMware-Tools on Linux