Linux VPS for beginners: getting started

A VPS gives you full control over your own server, but if you have never worked with Linux it can feel overwhelming. This guide takes you through the first hours with your VPS step by step.

Step 1: logging in via SSH

After ordering your VPS you receive an IP address, a username (usually root) and a password. You use these to log in via SSH:

Windows: open PowerShell or Windows Terminal and type:

ssh root@123.45.67.89

macOS / Linux: open the terminal and use the same command.

Accept the fingerprint on the first connection and enter your password.

Step 2: updating the system

The first thing you do after logging in is updating the system:

apt update && apt upgrade -y

This installs the latest security patches and software updates.

Step 3: creating a regular user

Working as root is risky: a typo can damage the entire system. Create a regular user:

adduser myuser
usermod -aG sudo myuser

From now on, log in as this user and use sudo when you need administrator privileges.

Step 4: securing SSH

Change the default SSH port and disable password login in favor of SSH keys:

  1. Generate an SSH key pair on your own computer: ssh-keygen -t ed25519
  2. Copy the public key to your VPS: ssh-copy-id myuser@123.45.67.89
  3. Edit /etc/ssh/sshd_config: set PasswordAuthentication no and PermitRootLogin no
  4. Restart SSH: sudo systemctl restart sshd

Step 5: setting up a firewall

Install and configure ufw (Uncomplicated Firewall):

sudo ufw allow OpenSSH
sudo ufw enable

Then only open the ports you need. For a web server:

sudo ufw allow 80/tcp
sudo ufw allow 443/tcp

Step 6: installing software

The most common tasks on a VPS:

PurposeInstallation
Web serversudo apt install nginx
Databasesudo apt install mariadb-server
PHPsudo apt install php-fpm php-mysql
Node.jsVia NodeSource: curl -fsSL https://deb.nodesource.com/setup_22.x | sudo bash -
DockerVia the official Docker repository

Common mistakes

  • No backups: always make backups before making changes. Use snapshots if your provider offers them.
  • Forgetting the firewall: an open server is a target. Set up your firewall before running services.
  • Using root for everything: work with a regular user and sudo.
  • Skipping updates: set up automatic security updates with unattended-upgrades.

Which operating system should I choose?

For beginners, Ubuntu 24.04 LTS is the best choice: large community, extensive documentation, five years of security updates. Debian 12 is slightly lighter and more stable but less beginner-friendly.

How much RAM do I need?

For a single website or application, 2 GB is sufficient. If you run multiple services, choose 4 GB or more. At most providers you can upgrade later.

Get started with a VPS at HostValues: KVM virtualization, root access and instant delivery.


Still stuck? Open a support ticket and our team will help you out.

Back to the blog