LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Scp to Windows server (https://www.linuxquestions.org/questions/linux-software-2/scp-to-windows-server-577551/)

jaysin_aus 08-16-2007 09:37 AM

Scp to Windows server
 
Hi all,

I want to setup a scp to a Windows machine and be able to get all files in the folder it ftp's to.

I can successfully get the connection to the box with scp.
I can get a file if i put in the name of the file fine.
I want to be able to get all files in that directory.

I try to put in values like *.* and * and doesn't work.
Even if I put in *.exe, still won't find the file.
I have also tried the -r option but that doesn't work either.

The command I am using is:
scp -P 223 username@serverip:*.* ./test2/

Does anybody know what needs to be set to be able to do this?

Any help is greatly appreciated.

Jason

ilikejam 08-16-2007 10:51 AM

Hi.

The problem is that your local shell is expanding the '*', not the remote shell.

Try:
Code:

scp -P 223 username@serverip:'*.*' ./test2/
Dave

jaysin_aus 08-16-2007 11:05 AM

The response I get back is scp: Failed to open file *.*.

ilikejam 08-16-2007 04:19 PM

Welcome to the wonderful world of Windows.

You might have better luck running sshd through cygwin on the Windows side, as it provides a proper shell that understands globs.

Dave


All times are GMT -5. The time now is 09:48 PM.