简体   繁体   中英

putty connect successfully, while pscp run into “server refused our key”

I create one SUSE linux EC2 instance in Amazon AWS.

And it is OK to 'putty' to access the instance (use the key-pair file, let's call it key.pem, I have converted it to key.ppk), and when log in the host, I am using 'root' user name, and it is OK.

login as: root
Authenticating with public key "imported-openssh-key"
Last login: Tue Apr 15 15:17:55 2014 from x.x.x.x
SUSE Linux Enterprise Server 11 SP3 x86_64 (64-bit)

As "root" use the:
  - zypper command for package management
  - yast command for configuration management

Management and Config: https://www.suse.com/suse-in-the-cloud-basics
Documentation: http://www.suse.com/documentation/sles11/

Have a lot of fun...

While when I try to use 'pscp' to copy files, it always failed, and outputs

Server refused our key
Using Keyboard-interactive authentication.
Password:

My 'pscp' command usage as following

C:\Users\t440s\Downloads\putty\pscp.exe -i key.pps test.txt root@myhost.compute.amazonaws.com:/tmp

Actually, I do not know my password.

And I checked following section of /etc/ssh/sshd_config, seems root do not need password

# Authentication:

#LoginGraceTime 2m
PermitRootLogin without-password

PasswordAuthentication no

I am using win8.

Please help me. Yours.

I would like you should use Git Bash tool http://git-scm.com/download/win its free and opensource, Please download and install , You have Unix environment is windows :) now in the git bash type command ls to check where you are and now you can type this command in GIT bash

scp -i /c/Users/USERNAME/Download/key.pem filename.txt ec2-user@ec2-81.1821.1..eu-west-1.compute.amazonaws.com:/tmp

You can replace the user ec2-user to ubuntu or any other which is associate to that machine I dont think root work. Let me know is that works for you

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM