Permission denied (publickey).
duquerroy opened this issue · comments
On Ubuntu 16.10, i have a error. Permission problems on know_hosts ?
Thanks for your help
Instance has been created XX.XXX.XXX.XXX
Giving new instance some time to fully boot up...
XX.XXX.XXX.XXX is still booting...
XX.XXX.XXX.XXX is still booting...
Setting up VPN on XX.XXX.XXX.XXX
Warning: Permanently added 'XX.XXX.XXX.XXX' (ECDSA) to the list of known hosts.
Permission denied (publickey).
lost connection
Error code 5
If you created a new key pair you will need to use
ssh-add <key>.pem
Verify that it's in ssh-agent
ssh-add - l
I create a new key pair and...
I specify that the key is not already in AWS, on the other hand it is well created but I can not save it locally
./autovpn -G -r us-west-2
Generating new keypair for us-west-2.
Traceback (most recent call last):
File "./scripts/keygen.py", line 37, in <module>
generate_key()
File "./scripts/keygen.py", line 29, in generate_key
key.save(key_dir)
File "/usr/local/lib/python2.7/dist-packages/boto/ec2/keypair.py", line 81, in save
file_path = os.path.join(directory_path, '%s.pem' % self.name)
File "/usr/lib/python2.7/posixpath.py", line 73, in join
path += '/' + b
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 11: ordinal not in range(128)
Key already exists in AWS
Try to delete it and recreate It looks like some weird ascii encoding error.
. /autovpn -D -r us-east-2 - k us-east-2_vpnkey
Then
. /autovpn -G -r us-east-2
hum, it's the same thing.
I will look at the code
when i do in command line
python ./scripts/keygen.py "us-west-2_vpnkey" "us-west-2" "."
it's works...
sounds like its unable to write to the directory. what is the output of "pwd"?
$ pwd
/home/zil/Téléchargements/autovpn
But it's good, I managed to make it work with
python ./scripts/keygen.py "us-west-2_vpnkey" "us-west-2" "."
Thanks !