Course page
Log in

You are watching a free preview. Enroll to open all 24 lessons, track progress and ask the course tutor.

Enroll for $59.99

Section 1: The first hour on a new server

Installing Ubuntu Server and what to choose

Video 10 min Lesson 1 of 24 Sample clip Preview

Ubuntu Server releases a long term support (LTS) version every two years, in April of even years. Each LTS receives standard security updates for five years, with extended coverage available through Ubuntu Pro. For servers, always choose an LTS release.

Where to install

  • Local virtual machine: Multipass from Canonical creates Ubuntu VMs with one command, multipass launch --name lab 24.04. VirtualBox or UTM also work.
  • Cloud server: any provider's Ubuntu LTS image. You usually get a default user and SSH key access from the start.
  • Physical machine: the ISO installer guides you through disks, network and an optional OpenSSH server.

Installer choices that matter

  • Storage layout: choose LVM. It makes resizing and adding disks much easier later, as we see in section five.
  • OpenSSH server: install it, and import your public key from GitHub or Launchpad if offered, so password login is never needed.
  • Featured snaps: skip them for now. Install what you need deliberately later.
  • Host name: choose a meaningful name such as web-01; it appears in every prompt and log line.

First login checks

lsb_release -a         # or: cat /etc/os-release
uname -r               # kernel version
hostnamectl
ip -brief address
df -h
free -h
timedatectl

Confirm the release, addresses, disk space and memory are what you expect, and that the clock is synchronised. Ubuntu uses systemd-timesyncd or chrony for time sync; correct time matters for logs, TLS certificates and authentication.

Update before anything else

sudo apt update
sudo apt full-upgrade
sudo reboot            # if a new kernel was installed

apt update refreshes the package lists; apt full-upgrade installs available updates, including ones that add or remove dependencies. If the file /var/run/reboot-required exists afterwards, reboot.

Write things down

Start a short server log: what you installed, which ports you opened, why you changed a setting. Future you, and colleagues, will need it. Better still, as you grow, keep this in configuration management such as Ansible. For now, a text file in a private repository is a great start.

The next three lessons cover the rest of the first hour: users, SSH and the firewall.

← → switch lessons