User Tools

Site Tools


ssh-remote

This is an old revision of the document!


HowTo connect to servers using SSH

To connect to server, local or remote, you can use the ssh client program. When you start a connection to the server using this program, the two machine involved, encrypt all the network traffic generated, so nobody can spy on your connection and see what you are doing. This kind of connection is the only available if you want to use terminal session to connect to our server, no matter if the connection is made locally or from a remote workstation.

Connecting to server

All you have to do in order to connect to a local or remote server is to open a terminal window and use the command

ssh <name of the server>

where <name of the server> can be the letteral name of the server or his IP Address. If this is the first time you try to connect to the server, the system present the remote key and ask you to confirm the connection. Just answer yes to the question and the remote system will ask for your username and password.
The username parameter is normally inherithed from the login you are using in the local system, so you have to insert only your password to access the remote system. <note warning> If you are using the session of another use, to access the remote server, use the -l <username> parameter in order to indicate the username you want use on the remote machine. </note> After opening the connection you can work on the server as you where logged to the consolle.

I want graphics

With the base connection, as the one explained above, you can't access to the graphica interface of the remote system. In order to start programs that have a graphical interface. we must use a specific parameter that instruct the system to forward even the graphic connections.

ssh -l <username> -Y <remote server>

With the -Y parameter we can start a program on the remote server and the graphical window of the program will be displayed on our linux workstation (this works also in windows, if you install CygWin). The program is completely running in the remote server, only the graphical interface is displayed on the local machine. <note tip> If you use this trick to see the graphical interface of a machine connected on the other side of the planet, check the bandwidth you can use. </note>

How Access more than one Server

In a perfect world, Firewalls dosn't exist, but here on heart, firewalls are absolutely necessary. Firewalls have just one mission: “block everything suspicious or dangerous that is transmitted on the network”. As disavantages, an user can't access directly the servers of a remote network, but must pass from a gateway.

  • The simple solution is to connect to the gateway and then, from the gateway, connect to the remote server. This can be annoying and difficult if you have to connect to differents remote server at the same time.
  • A second option is to connect to the gateway, and at the same time open different tunnels that permit to connect to the remote server directly.
ssh-remote.1171301166.txt.gz · Last modified: 2007/02/12 17:26 by damir