← Help center · VPS and servers
First steps on a new Linux VPS: a security checklist
A new server is reachable by everyone on the internet. Do these steps first.
Checklist
- Update the system
apt update && apt upgrade -y
(On AlmaLinux or CentOS use dnf update -y.)
- Change the root password: guide.
- Create a normal user and give it sudo rights:
adduser deploy
usermod -aG sudo deploy
- Use SSH keys and turn off password login: guide.
- Turn on a firewall: UFW guide.
- Turn on automatic security updates (
unattended-upgradeson Ubuntu). - Make backups and keep a copy away from the server.
Do not install software you do not need. Less software means fewer ways in.
More in VPS and servers
- How to connect to your Linux VPS with PuTTY (Windows)
- How to connect to a Linux VPS from Mac or Linux with SSH
- Where to find your server IP address and password
- How to change your root password on Linux
- How to set up a firewall on Ubuntu with UFW
Still stuck? Open a support ticket.