How do I connect to Linux VPS through SSH from Linux and Windows OS?

After you’ve purchased your Linux VPS, the first step that divides you from starting to use it as a platform for developing your web presence is connecting to it.
Depending on which operating system you use on your PC, Linux or Windows, you will have to follow a bit different ways. Let’s look at both of them.

Before connecting

Whether connecting from Linux or from Windows, in both cases you’ll require the server access information you get from your hosting provider after purchasing, most likely through an email. You’ll get your hostname, your IP address, your SSH user name, your SSH password, and your SSH port. Keep this information in a safe place and don’t forget where, as you are going to require it in the following sections.

What is SSH?

The connection to a Linux VPS is made through the SSH (secure shell) protocol. This protocol replaced the older standard Telnet, in contrast to which it implements diverse techniques that provide that your encrypted data is transmitted securely through a secure network.

SSH uses three encrypting technologies: symmetrical encryption, asymmetrical encryption, and hashing.

Symmetrical encryption means that a single key is used to encrypt and decrypt the data by both parties, the client, that is, your computer, and the host, that is, your VPS server. Since there is a single key or two keys that can be calculated with the help of another one, they are also referred to as shared keys. The keys are presented by random sequences of characters that are in turn used to turn the information into an undecipherable sequence of characters using a special algorithm. Symmetrical encryption is used to encrypt the whole communication between the client and the host.

In asymmetrical encryption, two keys are used – a private and a public key. The public is the key that can be owned and used by any user to encrypt or send information to the owner of a particular private key, while this information can only be decoded by the latter. Asymmetrical is not used to encrypt the whole session between the client and the host, but rather as a means of creating a secure symmetric connection.

Hashing is a form of encryption that consists in creating a sequence of random characters from certain input, which can’t and is not supposed to be decrypted. This technology is not used to send the data, but rather to verify it, comparing the hash to a certain input to make sure whether you possess the right input.

Connecting to Linux VPS from a PC with Linux OS

Connecting to Linux VPS from Linux is a bit easier than doing it from Windows and is done directly through the command line of your OS.

To connect via SSH on Linux, you should open the terminal. Issue the command:

ssh [username]@[server IP]

Now the command line will ask you to enter the password. You can paste it with a right mouse click, which will open the menu of actions, instead of typing it manually, but you won’t also be able to see it when entering. If all the information is entered correctly, the connection to your server will be established and you’ll be able to proceed to the further configuration of your server.

Connecting to Linux VPS from a PC with Windows OS

Connecting to Linux VPS from Windows is not that straightforward, but is not at all hard. To establish a connection you’ll require a separate client. The most widely used one is PuTTY – an easy and convenient application that you can download for free from this site:

After you have installed PuTTY, launch it. In the newly opened window enter your IP (or your hostname) and your port number – which is 22 by default, but is modified by the hosting provider to provide you better security right away. If the port is anyway 22, it’s recommended to change the port as soon as possible to get better protection from hacking attacks. Click “open” and you’ll see the terminal window requesting your password. Insert it. Here you also will be able to paste it, but not to see it while typing represented by small circles or whatsoever, so don’t panic here, just type it or paste it as you got it from your hosting provider. You can do it with a right mouse click which will insert the password at once.

Once you are through with it, hit the enter button, and if everything is done correctly, you’ll connect to the server. Congratulations, now you can use your Linux VPS for any purpose imaginable!

To sum up

Now you have more than enough information to connect to your Linux VPS and start setting up your web presence. We hope that everything was clear and has gone well. Thank you for your attention, take care!