Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

copying files from windows through script

Status
Not open for further replies.

hedap

Technical User
Jun 9, 2002
18
IN
Hi Guys,

Any method to just connect a windows machine if you know the login and password and copy a file to local machine. there should not be any change on other servers....

Having a task in hand like this...

Copy log files from various customers boxes (all windows) with the help of WHS windows host scripting.
Now Zip those files
copy those files to a particular location on a Linux box (it requires creating directory for each server and copying file)
a parm file which stores all data to connect a machine.

Now this is what i know:
I got a command line zip utility to zip the files.
using PSCP utility to transfer files to linux box.


Don't know hot to connect to various windows servers through PSCP while using it's giving error like this...
command 1:
pscp monitoring/pheda@192.168.169.80:"\\192.168.169.80\Reports\AIdetails.rdf" .
Error Message:
Fatal:Local to local copy not supported

command 2:
pscp pheda@192.168.169.80:"\\192.168.169.80\Reports\AIdetails.rdf" .
Error Message:
Fatal:ssh_init: Connection refused

the same type of command is working tom get files from Linux box.
Here I don't know whether PSCP support connecting windows servers
I can't use ftp as it may be not supported
I can't use netuse mapping as mapping should not be done
I can't use telnet as it may be not supported

I have to do this connectivity through command line I mean through scripting only.

Thanks..Prakash
 
its a linux command.....thast why it wokrs on from there and not to there

im not too high speed on UNIX/Linux or anything (yet), so I'm not sure if they'll support it, but all you would have to do is make a batch file and schedule it (if you need it more than once)to run on the windows server to collect all the data you need from the windows workstations.....im just not sure if the copy or xcopy command is capable of copying to linux..

hopefully this will help but i doubt it

 
I am firing this command from windows....
 
i understood your question wrong.....i was thinking you were working on the linux box and couldnt get the command to work....

my bad
 
anyway guys find out it's plink a putty utility allows you to do that....

Thanks for trying...
 
oops that dosn't solve the problem....

sorry still need ur help
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top