SSH (Secure Shell) is a protocol for connecting to a server remotely over an encrypted channel. If you manage a VPS or dedicated server, SSH is your main tool. Managing files, installing software, viewing logs โ all through the terminal.
Basic connection
Terminal (Linux/Mac) or PowerShell (Windows 10+):
ssh user@server-ip
Example: ssh root@185.123.45.67. The first time you'll be asked to confirm the fingerprint โ type "yes". Then enter the password.
If the port is changed
The default port is 22. For security it's often changed:
ssh -p 2222 user@server-ip
SSH key โ passwordless and more secure
Instead of a password, a cryptographic key pair. Almost immune to brute force. Create:
ssh-keygen -t ed25519 -C "email@example.com"
Two files are created: private (never share) and public (.pub).
Install the key on the server
ssh-copy-id user@server-ip
Now you connect without a password.
Disable password login
Once the key works, disable password login entirely. /etc/ssh/sshd_config: PasswordAuthentication no. This completely blocks brute force.
Useful commands
1) ls -la โ file list. 2) cd /folder. 3) nano file โ editing. 4) tail -f log.txt โ live log. 5) htop โ server load. 6) df -h โ disk.
SCP โ file transfer
scp file.zip user@server-ip:/folder/
SSH config โ convenience
Save server details in ~/.ssh/config. Then just ssh my-server.
Security tips
1) Key instead of password. 2) Change the port. 3) Disable direct root login. 4) Install fail2ban. 5) Allow only necessary IPs.
Sayt.uz practice
Sayt.uz VPS clients are advised to connect via SSH key. On shared hosting, it's safer to work through the control panel (ispmanager).