bschultz
21st February 2008, 06:39
I have a problem. The setup I'm dealing with at work is a router and firewall on the main server (Mac OS X) with ssh. I need to send (via cron job) a directory from my linux server at home to a second machine at work (also Mac OS X)...not the main server.
So, what I need is this:
server1 ssh's into server2 which ssh's into server3 and sends the directory. My boss won't let me change the firewall or port forwarding settings to ssh directly into server3.
I've tried to ssh into server 2 (main server/router) and then ssh into server3 and then scp the files...but I get an "ambiguous target" error.
Here's my code
ssh user@server2
scp -r /server1directory/ user@server3IP:/server3/path
Any idea what I'm doing wrong?
So, what I need is this:
server1 ssh's into server2 which ssh's into server3 and sends the directory. My boss won't let me change the firewall or port forwarding settings to ssh directly into server3.
I've tried to ssh into server 2 (main server/router) and then ssh into server3 and then scp the files...but I get an "ambiguous target" error.
Here's my code
ssh user@server2
scp -r /server1directory/ user@server3IP:/server3/path
Any idea what I'm doing wrong?