To enable SSH, first navigate to the boot directory:
cd /Volumes/boot
Now create an empty file called "ssh":
touch ssh
This will enable SSH when the Pi is booted.
In order to SSH into your Pi, you'll need to be connected to your local network. You can, of course, use Ethernet, but if you're using the Raspberry Pi 3, you've got WiFi built-in. So let's add our WiFi configuration to the Pi so it's available when we boot.
Navigate to the boot directory:
cd /Volumes/boot
And create a file called wpa_supplicant.conf
. Add the following to this file:
For Raspbian Jessie:
network={
ssid="YOUR_NETWORK_NAME"
psk="YOUR_PASSWORD"
key_mgmt=WPA-PSK
}
For Raspbian Stretch:
country=IE
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
ssid="YOUR_NETWORK_NAME"
psk="YOUR_PASSWORD"
key_mgmt=WPA-PSK
}
You'll need to add your wireless network name and password.
ssh pi@raspberrypi
sudo apt-get update
sudo apt-get install realvnc-vnc-server realvnc-vnc-viewer
You can enable VNC Server at the command line using raspi-config:
sudo raspi-config
Now, enable VNC Server by doing the following:
- Navigate to Interfacing Options.
- Scroll down and select
VNC
>Yes
.