Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Les deux révisions précédentesRévision précédente
en:documentation:tutorials:ssh:first_connection [2020/08/25 15:58] – modification externe 127.0.0.1en:documentation:tutorials:ssh:first_connection [2023/12/12 12:59] (Version actuelle) – supprimée ltaulell
Ligne 1: Ligne 1:
-====== First SSH connection ====== 
  
-===== From ENS network ===== 
- 
- 
-  * To connect to ''allo-psmn'' from the ENS network, simply type in a terminal the following command: 
- 
-<code bash > 
-ssh <mylogin>@allo-psmn.psmn.ens-lyon.fr 
-</code> 
- 
-===== From outside of ENS network ===== 
- 
-   * To connect to ''allo-psmn'' from outside of the ENS network, you first need to connect to ''ssh.psmn.ens-lyon.fr'' in order to access the ENS network. Then connect to  ''allo-psmn''. In a terminal, type the following commands:  
- 
-<code bash> 
-ssh <mylogin>@ssh.psmn.ens-lyon.fr 
-# enter your PSMN password 
-# then  
-ssh <mylogin>@allo-psmn.psmn.ens-lyon.fr 
-# enter your PSMN password 
-</code> 
- 
-===== First connection error message ===== 
- 
-<WRAP center round important 82%> 
-At your <wrap em>first attempt to connect to ''allo-psmn''</wrap> (either from the ENS network or from outside),  
-you need to <wrap em>strictly follow these instructions </wrap> ! 
-</WRAP> 
- 
- 
- 
-The following message will appear at your first attempt to connect to ''allo-psmn'': 
- 
-<code> 
-The authenticity of host 'allo-psmn.ens-lyon.fr (140.77.144.90)' can't be established.  
-RSA key fingerprint is xx:lots:of:caracters:ascii:xx:xx. 
-</code> 
- 
- 
-• To the question:  
-<code bash>Are you sure you want to continue connecting (yes/no)?</code> 
- 
-Answer : <wrap caution> yes</wrap> 
-===== Generate SSH keys ===== 
- 
-<note important>**WARNING**: This step provide a key pair without passphrase, for job submission. This key pair **MUST NOT** leave PSMN. It is equivalent to a master key on your home.</note> 
- 
-If you don't have already a SSH key pair **without** passphrase, you need to create it first time you connect (In order to simplify the computation system, you **must** have a PSMN's SSH key pair **without** passphrase). Strictly follow these CLI instructions: 
- 
-<code bash> 
-ssh-keygen -t rsa 
-</code> 
- 
- 
-• To the question: 
-<code bash> 
-Generating public/private rsa key pair. 
-Enter file in which to save the key (/home/votrelogin/.ssh/id_rsa) : 
-</code> 
- 
-<wrap hi>Hit ENTER</wrap> (default answer) 
- 
-• to the questions: 
- 
-<code bash> 
-Enter passphrase (empty for no passphrase) : 
-</code> 
- 
-and  
- 
-<code bash> 
-Enter same passphrase again : 
-</code> 
- 
-<wrap hi>Hit ENTER</wrap> (default answer) 
- 
-===== Keys copy ===== 
- 
-Then, create the  ''~/.ssh/authorized_keys'' file by  typing: 
- 
-<code bash> 
-touch ~/.ssh/authorized_keys 
-</code> 
- 
-Next, add your public SSH key (''id_rsa.pub'') to the ''~/.ssh/authorized_keys'' file: 
- 
-<code bash> 
-cat .ssh/id_rsa.pub >> ~/.ssh/authorized_keys 
-</code> 
- 
- 
-If you already have a pair of SSH authentication keys without password, **copy** the public key (id_rsa.pub) in ''~/.ssh/authorized_keys''. 
- 
- 
-Besides, if you also have a personal pair of SSH authentication keys (with passphrase), you can **add** your personal SSH public key (''id_rsa.pu''b) to the ''~/.ssh/authorized_keys'' file. 
- 
-===== Minimal configuration ===== 
- 
- 
-To automate as much as possible connections to machines and compute nodes, create the following configuration file (''~/.ssh/config'') : 
- 
-<code bash ~/.ssh/config> 
-Host * 
-  ServerAliveInterval 60 
-  ForwardX11Timeout 1d 
-  TCPKeepAlive yes 
-  ForwardAgent yes 
-  ForwardX11 yes         # for Linux 
-#  ForwardX11Trusted yes # for MacOSX 
-  Compression yes 
-  StrictHostKeyChecking no 
-  HashKnownHosts no 
-</code> 
- 
- 
-You can find ** a more complete file ** on the page [[documentation:tutorials:ssh:clef_agent_ssh&#exemple_de_configuration_pour_linux_et_bsd|Example of SSH configuration]]. 
- 
-Moreover, the list of front machine (connection servers) is available at [[documentation:clusters:services#serveurs_de_compilation|the following page]]. 
- 
- 
----- 
-Back to  [[en:documentation:tutorials:ssh:accueil|SSH connection to front machines]] 
en/documentation/tutorials/ssh/first_connection.1598371112.txt.gz · Dernière modification : 2020/08/25 15:58 de 127.0.0.1