Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm a newbie to unix. My requirement is to create an automation script which will transfer a zipped folder from my/remote desktop to an unix server. Tools lik WinSCP shouldnt be used. No manual moving. I use putty to connect to server. I couldnt find any help on this topic. Should i use ftp commands? If yes, how? What is the basic requirement(security n access-wise) for this transfer to happen? Pls help.

share|improve this question
3  
Is this supposed to be run from the Linux server or from Windows? Why do you not want to use WinSCP? Do you mean not WinSCP specifically or that you don't want to use any third party applications? What do you mean by "manual moving"? Does the server provide you with FTP access? –  terdon Jul 10 '13 at 15:58
    
The general overview would seem to be to write a script (batch, Powershell, VBS, WSH, whatever) and have it run as a scheduled task. This means using command line tools (winscp can be scripted). You don't mention anything about the source, but detecting the file to upload may be a challenge if it is dynanically named . . . in any case, this may be a better fit for Stack Overflow once you get a skeleton of a script written. –  ernie Jul 10 '13 at 16:35
    
This sounds like your homework. What did you try and what didn't work? –  tommy_o Jul 10 '13 at 22:35

3 Answers 3

Since you already have putty, have you tried pscp.exe, part of the same package?

It's not a gui, so you could in theory run as a batch script, or a scheduled push.

share|improve this answer
    
winscp can be run from the command line as well –  ernie Jul 10 '13 at 16:32
    
@ernie does WinSCP still pop a GUI up at that point? the OP specifically mentioned NOT to use WinSCP, I'm assuming for batch script reasons. –  Rich Homolka Jul 10 '13 at 17:08
1  
No GUI . . . that page is specifically titled "Scripting and Task Automation" and details how to write scripts to run via winscp.exe from the command line. It would be helpful if the OP clarified their use case. –  ernie Jul 10 '13 at 18:30

This looks like an easy way to do this

They recommend not using FTP for security reasons.

http://www.terminally-incoherent.com/blog/2006/09/23/command-line-scp-for-windows/

share|improve this answer
pscp c:\documents\zipped_folder.zip  username@server_ip:/tmp/

This command will copy your directory archive file (zipped_folder.zip) to unix server into /tmp/ directory. More about pscp. To avoid password entering use PuTTYgen.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.