I'm working on one ubuntu server with sftp but fail. I use -v on command and see output below:

Connecting to server...
OpenSSH_5.3p1 Debian-3ubuntu3, OpenSSL 0.9.8k 25 Mar 2009
...

debug1: Authentications that can continue: publickey,password  
debug1: Next authentication method: publickey  
debug1: Trying private key: /home/user/.ssh/id_rsa  
debug1: Trying private key: /home/user/.ssh/id_dsa  
debug1: Next authentication method: password  
loginuser@server's password:   

**[Here input the right password]**

debug1: Authentications that can continue: publickey  
debug1: No more authentication methods to try.  
Permission denied (publickey).  
Couldn't read packet: Connection reset by peer  

It's very strange that after the password method, it will try publickey method again... This sftp server is normal and I can login at another machine and the output are listed below:

Authentications that can continue: publickey,password  
debug1: Next authentication method: publickey  
debug1: Trying private key: /home/user/.ssh/id_rsa  
debug1: Trying private key: /home/user/.ssh/id_dsa  
debug1: Next authentication method: password  
loginuser@server's password:  

**[Here input the right password]**

debug1: Authentication succeeded (password).  
debug1: channel 0: new [client-session]  
debug1: Entering interactive session.  
debug1: Sending environment.  
debug1: Sending env LANG = en_HK.UTF-8  
debug1: Sending subsystem: sftp  
sftp>  

Why it can not work on the first one? Another question is that I got one more strange log on one server which I set auto ssh login with some other servers. It seems that id_rsa or authorized_keys in .ssh will intefere the login process, why? I only want to use username-password to login that sftp site, how can I do?

link|improve this question
Can you provide the relevant logs from the SSH server? – chuckx Mar 4 '11 at 11:40
feedback

migrated from stackoverflow.com Mar 4 '11 at 9:18

This question came from our site for professional and enthusiast programmers.

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
or
required, but never shown