2

I have this weird problem. I am using SSH key to connect to my-server. I have generated both public and private key without password and my public key is installed on my-server. I can connect to my-server from my local (Window 7) using private key but when I am trying to connect from a remote-server (Linux to Unix ) to my-server using the same key it is asking for password. I am using following command.

sftp -o "IdentityFile=<location-of-key>" user_id@server.name.com



 my-local: Window 7
 remote-server: Suse Linux 11 (x86_64)
 my-server: SunOS
Ashish
  • 133

2 Answers2

4

When you connect from Linux, you need to convert the private key from ppk format (understood by windows programs) to openssh format.

There is answer for this question on Stack Overflow.

You need to:

  • Go to Conversions->Export OpenSSH and export your private key from PuttyGEN after loading your PRIVATE key.
Jakuje
  • 10,303
0

Try using:

sftp -i "<location-of-key>" user_id@server.name.com

From the man page:

-i identity_file
Selects the file from which the identity (private key) for public key authentication is read. This option is directly passed to ssh(1).