OpenSSH SSH-2 private key (old PEM format)

Taken from here:

You’ve used ssh-keygen to create a private key file called id_rsa.ppk. However this is an OpenSSH-format private key and needs to be converted to Putty’s own format to use in Putty.

Your options are:

  1. Use this key with command-line SSH (it’s in the correct format). You can either
    1. specify the file on the command line e.g. ssh -i id_rsa.ppk azureuser@vm
    2. make a folder C:\Users\Aquib\.ssh and move it there as C:\Users\Aquib\.ssh\id_rsa (no extension): ssh will now load this file by default to use for all servers that you try to connect to
    3. if you don’t want to use this for all servers, or e.g. if you already have a default id_rsa that you use with git, you can set up a C:\Users\Aquib\.ssh\config file that tells SSH where to find the key and tell it which servers it should use it for.
  2. Convert this file into the right format to use with Putty:
    1. In Puttygen, in the ‘Conversions’ menu choose ‘Import’ and load id_rsa.ppk
    2. ‘Save private key’ to a different file
    3. Use this new file with Putty, either on the connection properties menu or run Pageant (the Putty key agent) and ‘Add key’ the new file. (You can e.g. create a shortcut to pageant in your Startup menu and give it the key file name as a commandline parameter so this is loaded automatically for you.)

Adding SSH Key to SSH Agent

Check if SSH Agent is running

eval "$(ssh-agent -s)"

Add the Keys to SSH Agent

ssh-add ~/.ssh/nameofkey

Verify Keys Added to SSH Agent

ssh-add -l

Copy Key to Remote Server

ssh-copy-id user@remote.server.location

Copy Server Key to Host

ssh-copy-id user@host.local

If you see a warning “Permission 0664 for ‘key_id’ are too open”, do this:

chmod og-rw key_id

Originally posted here:

Guacamole cannot connect via SSH – FIX

If you get “SSH handshake failed” when trying to use Guacamole to connect to Ubuntu via SSH, you need to use a workaround:

In the meantime a workaround is adding “HostKeyAlgorithms +ssh-rsa” to the end of /etc/ssh/sshd_config on the Ubuntu machine and restart sshd. Note: I don’t have an understanding of the security implications of this, so use at your own risk

The solution was posted here:

Check log file for interactive SSH logins

# failed attempt
grep sshd.\*Failed /var/log/auth.log | less

# successful attempts
grep sshd.\*Accepted /var/log/auth.log | less

VMware ESXi

Step 1. Connect to ESXi console and press the Alt+F1 key combination.

Step 2. Type unsupported and then press . Note that nothing will appear on the screen whilst you type this.

Step 3. When prompted enter in the Root password and press.

Step 4. You will now be presented with a prompt on the console. From this prompt type vi /etc/inetd.conf

Step 5. vi (the file editor) has now opened the inetd.conf file. Using the direction arrows scroll through the lines until you reach the line that has #ssh and remove the hash (ie: #). This is effectively un-commenting this line so that the ssh service can be started.

Step 6. Now that you have made this minor file you want to save this change and exit out of the editor (vi). To do this press the ESC key (to put vi back into Command Mode) and then type :wq *Note: If you want to exit without saving any changes to the file then just press the ESC key (Command Mode) and then type :q!.

Step 7. With the SSH service now un-commented from this file we want to restart the