02. Installing Ubuntu Server
We're going to start on our main computer (not the Pi)
First you'll need to download Ubuntu Server. To do this I prefer to use the rpi-imager tool. Install this by typing: sudo snap install rpi-imager
Once installed, click:
Choose OS > Other general purpose OS > Ubuntu > Ubuntu Server 20.04.3 LTS
Insert your SD card in your computer/hub/whatever and click Choose Storage
and select the card.
Click Write
and rpi-imager will download the OS and flash it to the SD card.
Super easy, cool.
Make sure you have a keyboard/monitor plugged in to your Raspberry Pi.
Insert the SD card in to the Pi and connect the power.
From ubuntu.com:
Warning During your first boot a tool called cloud-init is doing configuration. WAIT for it to finish before trying to log in. It typically takes less than 2 minutes but there is a break between the log-in prompt and cloud-init completing. If you interrupt the process you have to start again. You’ll know it’s done when it outputs some more lines after the log-in prompt has appeared.
Once all that is taken care of, login with the username
ubuntu
and passwordubuntu
You will be asked to update the password for the ubuntu user. Do that.
If your Pi is connected to the internet with an ethernet cable and the internet isn't working, try typing
sudo dhclient eth0
If you're going to use wifi we need to make an edit to a file on the system
sudo nano /etc/netplan/50-cloud-init.yaml
make this file look like this with the exact indenting (4 spaces)
network:
ethernets:
eth0:
dhcp4: true
optional: true
version: 2
wifis:
wlan0:
dhcp4: true
optional: true
access-points:
"SSID_name":
password: "WiFi_password"
Then save and exit Ctrl + O
, Enter
Ctrl + X
Generate some stuff with
sudo netplan generate
Apply that stuff
sudo netplan apply
Reboot the Raspberry Pi:
reboot
Once it starts up again, check to see if you're connected to the internet
ip a
and in the sectionwlan0
you should see your local ip address, something like192.168.X.XXX
Update everything:
sudo apt update && sudo apt upgrade
If that last command gave you an error:
Try running
sudo apt update
and then when it's done runsudo apt upgrade
Reboot:
reboot
and try the commands again.
Last updated