-
Notifications
You must be signed in to change notification settings - Fork 4
Connect via SSH
A Linux computer (including servers and virtual servers) have a command line interface (CLI) to interact with files and programs. The command line is very convenient, and it is in fact very user friendly to perform repetitive tasks, much more than a point-and-click interface that would force you to repeat tasks with the risk of introducing errors in the procedure.
💡 Remember: you need three things to log in: the remote address, your remote username and your remote password.
We can access a remote server only if we have a user account inside that server, and of course we need to know the address of the remote server. For this example let's suppose that our username is ubuntu and that the remote server has this address 147.188.173.69.
If your local computer already has a UNIX terminal (e.g. all Macs and all Linux computers have one), you can use your local terminal to connect to the remote machine.
In OS X you'll find the Terminal application inside the Applications folder, and can fire it up using Spotlight and typing “Terminal”. When the terminal is open, type the command:
ssh username@machine
If this is the first time you try to access a new server, then you'll get a message like this:
The authenticity of host '<server name>' can't be established.
RSA key fingerprint is SHA256:H5D4SW4xqEMp6TJCtDR76xxc5h+7bW4bvBP4r9rQ9jM.
Are you sure you want to continue connecting (yes/no)?
You can safely type yes
and then hit Enter.
Type it very carefully (as errors could prevent us to go on with the practical) and be aware that you won't see asterisks or dots ❗ while you type. Just hit enter at the end.
There is a free terminal emulator for Windows called PuTTY, that we can download and launch to access the remote machine. Once launched we just need to type username@machine_address
in the appropriate form field and then
If this is the first time you try to access a new server, then you'll get a message like this:
The authenticity of host '<server name>' can't be established.
RSA key fingerprint is SHA256:H5D4SW4xqEMp6TJCtDR76xxc5h+7bW4bvBP4r9rQ9jM.
Are you sure you want to continue connecting (yes/no)?
You can safely type yes and then hit Enter.
Type it very carefully (as errors could prevent us to go on with the practical) and be aware that you won't see asterisks or dots while you type. Just hit enter at the end.
Now you have a Terminal session like any other, just inside a Windows program.
· Bioinformatics at the Command Line - Andrea Telatin, 2017-2020
Menu