How do I connect to my server via SSH (Windows, Mac and Linux)

What is SSH (Secure Shell)? 

Secure Shell is an encoded protocol for managing network resources in a safe way while using a potentially unsafe network such as Internet. SSH allows you to connect to your server in a safe way by endoding the data that is exchanged making it inaccessible to anyone else.

The purpose of this kind of connection is to allow you efficient and safe way to complete a task on your server. For example, yu can reboot a service or the server if none of the other methods are working.

How to connect?

Windows

To connect to your server using Windows, download PuTTY, and then follow these steps:

  1. Start PuTTY.
  2. Enter your IP address as well as port.
  3. Click Open and the terminal will open.



  4. Enter your username and password (in case you wish to log in as a root user, enter "root" for the username). 
  5. Press Enter.
You are now logged into your server via SSH.

For users with Linux and MacOS

Both Linux and MacOS come with a native application which you can use called Open SSH. Start your terminal and issue the following command :

ssh username@hostname.domain.ext

or

ssh username@ipaddress

Change the "username" part of the command with your actual username, while the "hostname.domain.ext" should be changed with your actual hostname. The same applies for the IP address. If you are trying to connect using your root account, enterroot@hostname.mojsajt.rs ili root@91.201.129.561

If you are using Ubuntu operating system, you can install Open SSH using the following command:

sudo apt install openssh-server

For the Mac users, SSH is available by default while SSH Deamon is switched off. You will need to switch it on using the following command:

sudo systemsetup -setremotelogin on

To stop the SSH Daemon, issue the following command:

sudo systemsetup -setremotelogin off

To check SSH status, type the following:

sudo systemsetup -getremotelogin


Was this article helpful?

mood_bad Dislike 0
mood Like 0
visibility Views: 4449