Install Ubuntu Server 24.04 LTS step by step
A detailed Ubuntu Server 24.04 installation, from ISO and disk layout to first login and an optional static IP.
Ubuntu Server 24.04 LTS provides a command-line oriented base for hosting and other server projects. This walkthrough uses a virtual machine with a 40 GB disk, interface ens33, example address 192.168.0.100 and gateway 192.168.0.1. Replace these values with your own. Back up any data on the target disk.
Requirements and installation media
Download the Ubuntu Server 24.04 ISO for your architecture from https://ubuntu.com/download/server. An internet connection is useful for package updates. Write the ISO to a USB drive for a physical machine, or mount it as a virtual DVD in VMware or VirtualBox. Boot from that medium.
Installer start
The installer starts from the boot medium. Choose the installation option shown on your system.
The initial menus lead to the language selector. Choose the language for installation.
Choose the keyboard layout that matches the physical keyboard. Use Tab and Enter to navigate, then choose Done.
Review the selected keyboard layout and continue.
Choose standard or minimized Ubuntu Server. This example uses minimized and installs other software later.
Networking, mirror and storage
Check the detected network interface. DHCP assigns an address automatically if available; a static configuration can be entered here or after installation.
Enter a proxy only if your network requires one.
Keep the default Ubuntu archive mirror or select an appropriate mirror.
This example selects the entire 40 GB disk. A custom storage layout is available if you need separate partitions. Verify the selected device carefully.
With LVM, the installer may initially allocate only part of the volume group to the root logical volume. The amount depends on installer choices and disk size.
Select ubuntu-lv or the relevant logical volume to change its size.
Edit the logical volume.
Set the size to the available maximum if you want the root filesystem to use the remaining free space.
Review the resulting storage layout and consider whether separate /home or /var volumes would better fit your use case.
Confirm disk changes only after checking the target and layout; this step can erase existing data.
User account and optional packages
Enter a host name, user name and strong password. The account created during installation can administer the system with sudo.
Ubuntu Pro is optional; continue without attaching a subscription if you do not need it.
Select Install OpenSSH server if remote administration is needed. Import a public key when possible.
Skip optional featured server snaps in this minimal example; services can be installed later.
Wait for the installer to finish.
Reboot when installation completes and remove the installation medium if requested.
The system now boots into the new Ubuntu Server installation.
First login
Sign in locally or via SSH as the user you created.
A successful login opens the command-line shell.
Use sudo for individual administrative commands. A temporary root shell is possible with sudo -s, but enabling direct root login with a root password is unnecessary for this guide.
If you did not install SSH in the installer, install OpenSSH Server and check its status:
sudo apt update
sudo apt install openssh-server
systemctl status ssh
Install a text editor if needed; nano is beginner-friendly and vim-nox is another option.
sudo apt install nano vim-nox
Configure a static address when needed
Ubuntu Server uses Netplan; the active YAML filename varies by installer, VM or cloud image. Inspect /etc/netplan/ first. Cloud-init can manage networking on cloud images, so use the provider’s supported configuration method there. Do not blindly disable cloud-init networking on a remote VPS.
The following local VM example uses ens33 and a private address. Adapt interface, IP, gateway and DNS, then save the YAML in the appropriate Netplan file. Keep a console available when changing remote network access.
network:
version: 2
renderer: networkd
ethernets:
ens33:
dhcp4: false
addresses: [192.168.0.100/24]
routes:
- to: default
via: 192.168.0.1
nameservers:
addresses: [8.8.8.8, 8.8.4.4]
Run netplan try to validate and revert automatically unless you confirm. Verify the new address and route before closing your existing connection.
sudo netplan try
ip address show ens33
ip route
Add a local hostname mapping to /etc/hosts if you need the FQDN server1.example.com to resolve to 192.168.0.100, and set the short host name using hostnamectl.
sudo hostnamectl set-hostname server1
sudo nano /etc/hosts
Check the short host name and FQDN; the latter depends on working DNS or /etc/hosts configuration. You can reconfigure the keyboard separately if needed.
hostname
hostname -f
sudo dpkg-reconfigure keyboard-configuration
The base server is ready for further configuration; add updates, firewall rules, backups and monitoring for its intended use.
Share
What's Your Reaction?
Like
0
Dislike
0
Love
0
Funny
0
Angry
0
Sad
0
Wow
0