Hi.
I'm trying to create an automated script to copy files from one server to another using scp. I've set up the keys and I can successfully ssh into the other server with no password needed, so my keys are working.
When I try to scp, it asks for a password, when I don't want it to, and even when I type the correct password, I get the following error:
Here's the command I use:
I'm telling scp to use a different port, but it keeps saying refused on port 22.
I don't know where to go next. I haven't touched the ssh_config files, so there may be something there, but I'm not sure what I would be looking for.
I'm trying to create an automated script to copy files from one server to another using scp. I've set up the keys and I can successfully ssh into the other server with no password needed, so my keys are working.
When I try to scp, it asks for a password, when I don't want it to, and even when I type the correct password, I get the following error:
ssh: connect to host xxx.xxx.xxx.xxx port 22: Connection refused
lost connection
lost connection
Here's the command I use:
scp -P 2222 me@myserver.com:~/test_file.txt me@xxx.xxx.xxx.xxx:/usr/home/me/
I'm telling scp to use a different port, but it keeps saying refused on port 22.
I don't know where to go next. I haven't touched the ssh_config files, so there may be something there, but I'm not sure what I would be looking for.