Reputation: 188
Hello I am trying to SCP a log file to serve and I keep getting error
Warning: Identity file ids-east-1.pem not accessible: No such file or directory.
ec2-11.com: Permission denied (publickey).
lost connection
I have tried all the solutions presented earlier but can't seem to figure out what's wrong. The key I am using is :
scp -r -i ids-east-1.pem ~/int/resources/tests/tasks/lib/testing.log [email protected]:/home/wn/shelf/wrDb/fractions
Just a reminder- I am able to get a log file from this server using :
scp -i ids-east-1.pem [email protected]:/home/wn/shelf/wrDb/fractions/chrono.log ~/Desktop/aws_chrono.log
Upvotes: 2
Views: 154
Reputation: 11995
If one command works, but the other gives you:
Warning: Identity file ids-east-1.pem not accessible: No such file or directory.
You are likely not running the commands from the same directory. Try specifying the key path fully (something like):
scp -i ~/.ssh/ids-east-1.pem ...
Upvotes: 1