First you need following things :
- generate private key from your hosting site ( i used godaddy cpanel )
- username of cpanel
- password of cpanel
- finally passphrase which you have given when creating private key
Download your private key from your hosting site to your desktop , i have download my key from godaddy cpanel , you can find a file named ” newssh ” which is a private ssh key * name of private may vary
i have renamed the file ” newssh ” to ” newssh.txt ” , i have just changed the file extension , so that it can readable by terminal or you can read it using any text based editor like vim , nano or gedit
now you need to move this file from Desktop to your Home Directory , because when you open your directory it will mount home as the default directory
now you can see the ” newssh.txt ” file is listed in the terminal home directory
Run the following command to change the file permissions to 600 to secure the key. You can also set them to 400. *This step is required:
To login you need to type the following details in the terminal , which loads the key in file newssh.txt and logs in as user ,to IP your server ip
then press Enter key , now it will ask you for the passphrase which you have given at the time for private key creation , type the passphrase , Press Enter
Congratulation you have successfully login to your server using ssh
0 Comments