Quick answer: On Ubuntu/Debian run sudo apt update && sudo apt -y upgrade; on AlmaLinux/Rocky run sudo dnf -y upgrade. Do it regularly — most compromises exploit known, already-patched vulnerabilities — and reboot after kernel updates.

Overview

Package updates deliver security patches, bug fixes and performance improvements. On an unmanaged Cloud2Y server, updating is your responsibility. This article covers manual updates on both major package families and enabling automatic security updates.

Before you start

  • Root or sudo access via SSH (how to connect).
  • For production: a recent backup or snapshot, and a maintenance window for possible service restarts.

Step-by-step guide

Ubuntu / Debian (apt):

sudo apt update          # refresh package lists
apt list --upgradable    # review what will change
sudo apt -y upgrade      # apply updates
sudo apt autoremove      # drop unused dependencies

AlmaLinux / Rocky (dnf):

sudo dnf check-update
sudo dnf -y upgrade
sudo dnf autoremove

Automatic security updates:

# Ubuntu/Debian
sudo apt install unattended-upgrades
sudo dpkg-reconfigure -plow unattended-upgrades

# AlmaLinux/Rocky
sudo dnf install dnf-automatic
sudo systemctl enable --now dnf-automatic.timer

Check whether a reboot is needed: on Debian-family, the file /var/run/reboot-required appears after kernel/libc updates; on RHEL-family run sudo dnf needs-restarting -r.

Common issues

  • Held/broken packages (apt): try sudo apt -f install; read the error before forcing anything.
  • Kernel updated but old one still running: reboot; verify with uname -r.
  • Services not restarted after library updates: restart affected services or reboot — otherwise old vulnerable code keeps running in memory.

When to contact support

If the server does not boot after an update, use the KVM Console on your service page to inspect the boot screen, and open a ticket if you cannot recover it yourself.

Frequently asked questions

How often should I update packages on my server?

Apply security updates at least weekly, or enable unattended-upgrades or dnf-automatic so critical patches install themselves daily without your involvement.

Do I need to reboot after every update?

Only after kernel or core library updates. Debian-family systems create /var/run/reboot-required; on RHEL-family run "dnf needs-restarting -r" to check.

Can updates break my applications?

Within one distribution release updates are conservative and rarely break things. For production, keep backups and read the list of upgradable packages before applying.

Related articles

Need a hand? Contact Cloud2Y support →

Was this answer helpful? 0 Users Found This Useful (0 Votes)