Browse guides
Keep the system up to date
Install security fixes and enable essential automatic updates.
Beginner7 min readUpdated July 18, 2026
1
Update packages
Refresh the package index, review available updates, then install them during a maintenance window.
Terminal
sudo apt update
apt list --upgradable
sudo apt upgrade2
Automate security fixes
unattended-upgrades automatically installs security updates according to your distribution settings.
Terminal
sudo apt install unattended-upgrades
sudo dpkg-reconfigure -plow unattended-upgrades
systemctl status unattended-upgrades3
Manage reboots
Terminal
if [ -f /var/run/reboot-required ]; then cat /var/run/reboot-required; fi
sudo apt autoremoveBefore rebooting
Confirm that a recent backup exists and your services start automatically.