Connect to your Linux VPS or VDS with SSH
By the end: You will have connected to your server and checked the account and operating system. Terminal or PowerShell starts on your computer; after SSH connects, commands typed into that window run on the server.
Use this guide to make your first SSH connection once your Linux server is ready. SSH provides encrypted access to the server's command line. It is separate from the customer portal and hosting control panel; those passwords are not necessarily valid for SSH.
Applies to: Ubuntu 24.04 LTS and Debian 13 servers running OpenSSH, and Linux, macOS or Windows computers with an OpenSSH client. This guide does not cover Remote Desktop access to Windows servers.
Check where you are typing the command at each step.
- Your computer
Open Terminal or PowerShell; prepare the IP, username and SSH port.
- SSH connection
Verify the server fingerprint, then sign in using an allowed method.
- Server session
Commands now run on the server. Check the account with whoami.
The DCHost customer portal and SSH are separate sign-ins; do not assume the passwords match.
Before you start
Keep three details ready:
| Example in this guide | Replace with |
|---|---|
203.0.113.10 | Your server's IP address |
server_user | Your assigned SSH username |
22 | The SSH port in your service details |
Before continuing: Confirm all three values from your own service information.
Check the service in the DCHost customer portal and confirm that technical provisioning is complete. Obtain the server's IP address, SSH port and assigned username from your own service details. The username is not necessarily root or ubuntu.
203.0.113.10, server_user and 22 below are examples. Replace them with your service details. If access information is missing, request it from support instead of starting a new installation or reinstalling the server.
1. Check the SSH client on your computer
How to run it: Type the single line below in your computer's command window, then press Enter. -V asks for the SSH client's version; it does not connect to the server.
Open Terminal on Linux or macOS, or PowerShell on Windows. Run this command on your computer:
ssh -V
You should see an OpenSSH version. If ssh is unavailable, install your operating system's OpenSSH client; you do not need the server component. On a company computer, follow your administrator's software installation policy.
2. Connect to the correct server
Run this example on your computer after replacing the service details.
ssh -p 22 server_user@203.0.113.10- Starts the SSH client
- Selects the SSH port; use your assigned port
- The account on the server
- The server IP follows the @ symbol
- Replace the details
Use the IP, account and port from your own service instead of the example values.
- Verify the connection
Check the fingerprint; after signing in, use whoami to confirm the account.
Enter the command on one line. 203.0.113.10 and server_user are examples; replace them with your own service details.
Where? On your own computer. Replace the example values and run the command, then follow the identity checks below.
ssh -p 22 server_user@203.0.113.10
Your first connection may ask you to accept the server's host key. Compare its SHA256 fingerprint with trusted provisioning information. If no fingerprint was provided, ask support to verify it before accepting. If a previously used server reports a changed key, follow the SSH troubleshooting guide.
If password authentication is available, enter the password when prompted. It is normal for typed characters to remain invisible. Do not put the password in the command. If your service accepts only key authentication, you need a key already authorized for that account.
Check: A new command prompt may mean the connection has opened. Verify the account and server in the next step.
3. Verify the session
Run each line separately and check its output:
| Command | What should appear? |
|---|---|
whoami | The account you signed in with |
hostname | The server's system name; it need not match your domain |
cat /etc/os-release | Linux distribution and version |
date -Is | Server date, time and time zone offset |
After connecting, these commands run on the server. They do not change settings:
whoami
hostname
cat /etc/os-release
date -Is
Check the username, hostname, operating system version and time. Stop before installing software if they do not match the expected service. If you need sudo, confirm that your assigned account has that permission; avoid changing privileges just to work around an unexplained access issue.
Small glossary: sudo lets an authorized account run a command with administrator privileges. Signing in through SSH does not, by itself, grant that permission.
4. Prepare the next steps
Set up SSH key access, then establish a server backup plan and update routine. DCHost's VPS and VDS pages list the same virtual server packages. Check your service terms to understand responsibility for the operating system and applications.
Keep the current session open whenever you change SSH settings, users or firewall rules. Before closing it, confirm that a separate new connection works. Do not assume the portal includes a console or rescue screen; establish the recovery method available for your service before making changes that could affect access.
If the connection fails
Connection timed out, Connection refused and Permission denied indicate different failure stages. Use the SSH connection error guide to separate them. Reinstalling the server or disabling its firewall is not an appropriate first diagnostic step.
Include the service ID, time and time zone, target port and exact error in a support ticket. Never include passwords or private keys. If you only connected and read system information, there is no server change to undo; use exit to close the session.
Exit check: Typing exit on the server closes SSH and returns you to your computer's command line.