Generate SSH key on Windows with PuTTYgen
A way to generate a SSH key under Windows is with help of PutTTY-gen. PuTTYgen can be downloaded at http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html or directly downloaded from http://the.earth.li/~sgtatham/putty/latest/x86/puttygen.exe .
- Start PuTTYgen
- In the field “Type of key to generate”, please select “SSH-2 RSA”.
- Move your pointer under the bar and move the mouse in this field until the bar is completely green.
- Fill in a passphrase in the “Key passphrase” field. A passphrase is the same as a password, but in general it contains more characters. Repeat the same passphrase in the “Confirm passphrase” field. It is possible to not use a passphrase, but this is not considered as good practice in terms of security.
- Save your private key at a secure spot (never share this file!) with the “Save Private Key”. The extension of the file must be
.ppk. You need this file later on to login to your machine.
- Save also your public key with the “Save Pubilic Key”. The extension of the file should be
.pub. You need this file later on to copy to your UI profile.
- Select all text from the “Public key for pasting into OpenSSH authorized_keys file” and copy paste this in OpenNebula UI profile.
SSH access from a Windows PuTTY client
A well known SSH client for Windows is PuTTY.
You can download Putty here.
This client only works with a terminal and does not support a graphical user interface out of the box.
To login to your VM:
- start Putty
- Fill in the Host Name (or IP address) e.g. vmname.projectname-institute.surf-hosted.nl or 145.100.XX.YY
- Select Connection ->Data on the left hand panel
- Fill in your user name at Auto-login username (for the first time you start a VM this should be root, or ubuntu when using Ubuntu)
- Select Connection->SSH->Auth on the left-hand panel
- Select your private key by selecting the browse button and navigate to your private key (with the
- Select Session on the left-hand panel
- Save the session by giving it a name under saved sessions and click on the save button.
- Click the Open button.
- In case you have set a passphrase on your certificate, you will have to fill it in.
- Now you are logged on to your VM
The first time you start a session to a VM a warning is given that the machine is not cached. Select yes to continue the session.