Windows to Linux Files Transfer


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Windows to Linux Files Transfer
# 1  
Old 09-26-2011
Windows to Linux Files Transfer

Hi,
I have to write a batch script in windows and transfer files from windows ro linux. But I am not able to connect to the Linux machine. The script to transfer files from windows to unix is not working. Please let me know how to transfer files using script.

P.S.- I have to put files from windows.so We have to write the script in windows.
# 2  
Old 09-26-2011
Could you show us the code of your existing script (OBSCURE PASSWORDS etc..) and any errors it displays when run?
# 3  
Old 09-26-2011
how do you transfer files between windows and linux WITHOUT script? after you give us this information, we might be able to give you some hints how to do it with a script/batchfile...
# 4  
Old 09-26-2011
There's not a 'linux method' of transferring files. It depends on what services you're running on the Linux server, and how you're trying to use them.

Show what you've tried and in what manner it doesn't work please.
# 5  
Old 09-27-2011
Thanks...I have installed psftp client on my machine. then I am using the below script.

b.scr:
-----
Code:
cd /path on which I shall put my txt files/
mput *txt
quit

c.bat:
-----
Code:
psftp user_name@IP_address -pw password -batch -b b.scr

Now it is working. But my question is if there are no txt files in my local directory, then some garbage message is there on command prompt. I want to put a check condition. But its not working.

I used below CHECK condition:
Code:
IF EXIST "local file path\*txt" ELSE (goto :eof)

Please suggest.......

Moderator's Comments:
Mod Comment Video tutorial on how to use code tags in The UNIX and Linux Forums.

Last edited by Franklin52; 09-27-2011 at 08:51 AM.. Reason: Please use code tags, thank you
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Help with a script to transfer files from Solaris to windows

Hi Please can you tell me what could be wrong with the following scriptto transfer files from solaris 10 to windows machine: #!/bin/sh HOST=<IP> USER=administrator PASSWD=xyz123zyx /usr/bin/ftp -inv <<EOF connect $HOST user $USER $PASSWD cd Documents binary mput *.sh bye EOF (23 Replies)
Discussion started by: fretagi
23 Replies

2. UNIX for Dummies Questions & Answers

Remote file transfer between Linux and Windows

Hello, I have a file, say details.txt on my windows machine. I want to copy it to linux machine through a shell script and edit the file and transfer the file back to windows machine. (All I want to do is to edit the file on windows machine from linux machine by a script.) I have tried scp... (1 Reply)
Discussion started by: Devendra Hupri
1 Replies

3. Shell Programming and Scripting

Script to transfer files from Solaris to windows

Hi All Please can you help, I´ve wrote the following script on a solaris 10 server to transfer files to a windows machine. #!/usr/bin/sh cd /moneta_polled01/download HOST=10.100.4.72 USER=user1 PASSWD=V7stop /usr/bin/ftp -v $HOST <<EOF user $USER $PASSWD cd tmp binary put... (7 Replies)
Discussion started by: fretagi
7 Replies

4. Shell Programming and Scripting

Transfer files from linux server to windows using secure ftp (sftp)

HI, I have to transfer files from linux server to windows using secure ftp (sftp) .Kindly help me out. (3 Replies)
Discussion started by: manushi88
3 Replies

5. UNIX for Dummies Questions & Answers

transfer windows files to linix

I'm very new to linix (using puppy) and need to transfer some files on the same computer from windows to linix. Please use small easy words (2 Replies)
Discussion started by: bugzy
2 Replies

6. Shell Programming and Scripting

File transfer from Windows machine to Linux server

Hi guys, I need to send a txt file from a windows machine to Linux server. Any help is appreciated.... Thanks... (3 Replies)
Discussion started by: gowrishankar05
3 Replies

7. Homework & Coursework Questions

File transfer from Red Hat Linux to Windows 7

My assignment is to use C++ to generate a table of values for the U.S. standard atmosphere, when data at sea level are given, which i have done perfectly. Now, i am attempting to create a matlab script to read and plot the data. I forgot to put my table of data on my thumb drive yesterday, and... (4 Replies)
Discussion started by: ds7202
4 Replies

8. HP-UX

Transfer Files from Windows to HP-UX

I need to transfer files from Windows to Hp-UX box with out any software(Filezilla ...., Fsecure file transfer) Is it possible to transfer using command prompt ? (6 Replies)
Discussion started by: girija
6 Replies

9. Solaris

Transfer files from Solaris to windows

Please let me know a efficient way to transfer files from a solaris to a windows machine. Total size of data is 800GB. (3 Replies)
Discussion started by: pingmeback
3 Replies

10. UNIX for Advanced & Expert Users

How to transfer files from Unix to Windows.

Hi There is a requirement for me to transfer files from Unix to windows in an automation process of unix. Please let me know is it posibble to shell scripting this? Could you help me in scripting it? Regards Venugopal (2 Replies)
Discussion started by: venu_eie
2 Replies
Login or Register to Ask a Question