Sometimes, when installing the Ubuntu 24.04 TLS Server ISO image, the process freezes at one of the stages. There are already many discussions about this problem online. The solution is to install the distribution with the network disabled.
To configure the network on the Linux Ubuntu 24.04 distribution after installation, you need to:
1. Log in as the root user
If the installation has just finished, log in as the user you created and set a password for the root user.
sudo passwd root
Impersonate the root user using the command and the password you set.
su -
2. Network configuration, static IP address
Create a configuration file
touch /etc/netplan/00-installer-config.yaml
vi /etc/netplan/00-installer-config.yaml
With the following content:
network:
version: 2
renderer: networkd
ethernets:
enp0s3:
addresses:
- 89.111.187.xxx/24
gateway4: 89.111.187.x
nameservers:
addresses: [8.8.8.8, 1.1.1.1]
Apply the configuration
netplan apply
Note 1
If errors occur, check the file for tabs
cat -A /etc/netplan/00-installer-config.yaml
If you see ^I - these are tabs. Replace them with spaces!
You can check with the ping command by external IP address and domain.
Note 2
If ping only works by IP address, check for the presence of the following lines in the file:
/etc/resolv.conf
nameserver 8.8.8.8
nameserver 1.1.1.1