Published: 24.09.2026
A new VPS is ready within minutes, and a fresh server is soon found by automated scanners. The first hour is a good time to set the basics in a fixed order: update the system, create a working user, add your SSH key, limit access, set the time zone and confirm the firewall. The commands below suit Debian and Ubuntu, and other distributions follow the same ideas with their own tools.

Minutes 0 to 10: log in and update
Log in with the access details shown in the client area. If an SSH login fails, the web console in the client area gives you direct access to the server. Refresh the list of available packages with apt update, then install the updates with apt upgrade. If you log in as root, run the commands as they are. If you use a normal user with administrator rights, put sudo in front of each command. Reboot the server when the update asks for it, especially after a kernel update.
Minutes 10 to 25: create a working user
Working as root all the time is risky, because every mistake has full power. Create a normal account for daily work and give it administrator rights through the sudo group. On Debian and Ubuntu, the adduser command with a user name creates the account. The usermod command with the options -aG, the group name sudo and the user name adds the rights. Open a second terminal and test the new login before you close the first one.
Minutes 25 to 40: add your SSH key
A key pair is safer than a password. Create the key on your own computer, copy the public part to the server for the new user and test a login with the key. Only then should you turn off password login.
- Generate a key on your computer with the ssh-keygen command.
- Copy the public key to the server with ssh-copy-id, using the new user name and the server address. On Windows, where ssh-copy-id may be missing, add the public key to the account's authorized keys file by hand.
- Open a second window and log in with the key, checking that no password is requested.
- Disable password login and root login in the SSH configuration file, check the file with sshd -t, and restart the ssh service, which is named ssh on Debian and Ubuntu. Keep your first session open until the new settings are proven.
Minutes 40 to 50: firewall rules
Allow SSH before you enable any firewall, otherwise you can lock yourself out. On Ubuntu and Debian the ufw tool includes an application profile called OpenSSH, and the command ufw app list shows the available profile names. Allow OpenSSH, enable the firewall and check the result with ufw status verbose. Open only the ports your services need. If you also use the free firewall in the client area, its rules and the rules on the server must both allow the traffic you need.
Minutes 50 to 60: time zone, host name and notes
Set the time zone so that logs and scheduled jobs use the time you expect. List the names with the timedatectl command and the list-timezones option, then set your choice with timedatectl and the set-timezone option. Set a clear host name with hostnamectl and the set-hostname option. Check the clock with timedatectl again, and write down the date, the user you created and the changes you made.
After the first hour
Create a snapshot or backup from the client area while the server is still clean, so you have a known good point to return to. On Debian and Ubuntu, the unattended-upgrades package can install security updates automatically. Add monitoring, so that you notice trouble early, and keep this checklist in a notes file for the next server you build.
Frequently asked questions
Do I need all of this if the server is already installed? Yes. On a new server most of these steps are your responsibility, because the system is yours to configure.
What if I lock myself out? Use the web console in the client area to log in directly and correct the SSH or firewall setting. Rescue mode is available for deeper repairs.
Which distribution should I choose? Several Linux distributions can be chosen when you order. Pick one you are able to maintain, and prefer a long-term-support release if you want updates over a longer period.