
This is especially true since Linux writes over the macOS Recovery partition.įor that reason, we recommend you dual boot Linux on your Mac. However, if you ever change your mind, it's difficult and time-consuming to restore macOS again in the future.

That way, none of your storage is used up by its system files. If you don't plan to ever use macOS again, you might want to completely replace it with Linux. The main difference between a dual boot system and a virtual machine is that you can only use one OS at a time while dual-booting, but you get better performance. You can just hold Option while your computer boots up to choose which operating system to use. With a dual boot system, both macOS and Linux are installed on your Mac. Since it's so popular, there are also lots of active support communities available if you ever need help. Ubuntu is the best option for Linux newcomers. There are many different versions of Linux available, but for the purposes of this tutorial, we suggest installing Ubuntu on your Mac. Ubuntu Is Our Linux Distribution of Choice Rather than letting your old Mac turn into an expensive paperweight, install the latest version of Linux and keep it going for years to come. What's more, Linux breathes life into old Macs that are no longer eligible for macOS updates. The hardware on a Mac is difficult to match, which makes it an incredibly powerful machine for running Linux. In our example we will login to a Raspberry Pi then run the poweroff command to power down the Pi.Your Mac offers excellent performance, superb battery life, and good durability. Use SSH to log in to the remote machine, add “-t” to the end of the command, then insert the command that you wish to run and press Enter. Using the -t argument we can log in, run a command, wait for the output and then logout.Ģ. For example this could be a Raspberry Pi that we need to shutdown.
Sometimes we just need to run a single command on a remote machine. How to run a command and close an SSH connection It is important to close an SSH session when not in use so you don’t accidentally send commands to it or leave it open should your computer be hacked. When finished with the SSH session, exit using CTRL+D or type exit and press Enter. ssh Type Yes if prompted to confirm the connection for the first time.ĥ.

Enter the SSH command followed by the example below, our user was “pi” and the hostname was “raspberrypi.local”.
