Automated ftp for Multiple files


 
Thread Tools Search this Thread
Special Forums IP Networking Automated ftp for Multiple files
# 1  
Old 11-09-2006
Automated ftp for Multiple files

I have seen the script posted yesterday for automated ftp

Can we do some thing like ftp ing multiple files in one script

Example input.txt has all files names to be ftped

input.txt ------
a.tar
b.ccp
c.perl

i need to ftp all the files present in input.txt


i tried something like this

#! /usr/bin/ksh

HOST=remote.host.name
USER=whoever
PASSWD=whatever
cat input.txt | while ln=`line`
do
exec 4>&1
ftp -nv >&4 2>&4 |&

print -p open $HOST
print -p user $USER $PASSWD
print -p cd directory
print -p binary
print -p put $ln

wait
exit 0

done




but this gets hanged after ftping the first file
then i have to give a Ctrl C to come out of it
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Automated script to look for files in FTP Server location.

suppose one file comes in one sever location on MOnday.we have to write a script to automatically get that files and put it in different server location. ---------- Post updated at 10:28 AM ---------- Previous update was at 10:27 AM ---------- Please help me on this (2 Replies)
Discussion started by: sonam273
2 Replies

2. Shell Programming and Scripting

FTP multiple files from multiple directories

I have multiple files that starts as TRADE_LOG spread across multiple folders in the given structure.. ./dir1/1/TRADE_LOG*.gz ./dir2/10/TRADE_LOG*.gz ./dir11/12/TRADE_LOG*.gz ./dir12/13/TRADE_LOG*.gz when I do ftp uisng mput from the "." dir I am getting the below given error mput... (1 Reply)
Discussion started by: prasperl
1 Replies

3. Shell Programming and Scripting

Automated FTP

Hello,I just know the basics of scripting & I need a script to automate ftp since I use it quite often. I use ftp to transfer different kind of files and everytime the source & the destination directories are different for transferring files, so can anyone help me out on this urgently.. (2 Replies)
Discussion started by: mohit_02mar
2 Replies

4. Shell Programming and Scripting

Automated FTP script using .netrc to multiple FTP servers

Hi all, I'm using the following script to automated ftp files to 1 ftp servers host=192.168.0.1 /usr/bin/ftp -vi >> $bkplog 2>&1 <<ftp open $host bin cd ${directory} put $files quit ftp and the .netrc file contain machine 192.168.0.1 login abc... (4 Replies)
Discussion started by: varu0612
4 Replies

5. Shell Programming and Scripting

Automated FTP

I want to do Automated FTP from linux client to LINUX server using a shell script after every one hour. And copies last most updated file from Linux server. OR You can say that whenever files get modified on LINUX server so it also copies on my LINUX client. Linux SERVER path=... (4 Replies)
Discussion started by: wakhan
4 Replies

6. Shell Programming and Scripting

automated ftp.

Hi I am trying to delete some specific files ( files other than created today) from the server on a cron basis. I wrote a small script, but I am stuck up in how to delete only specific files. #!/usr/bin/expect -f set IP set timeout -1 spawn ftp $IP expect ): send "username\n"... (10 Replies)
Discussion started by: sangfroid
10 Replies

7. UNIX for Advanced & Expert Users

automated ftp script from unix -date range of files

Hi , I need some help to finish my ftp script and i need to find the last one weeks of fles updated in the sepecific directory and see those end with Z and ftp them to my backup server. Any help is appreciated. Thanks, Ravi :) (1 Reply)
Discussion started by: koduri0475
1 Replies

8. Programming

automated ftp script from unix -date range of files

Hi , I need some help to finish my ftp script and i need to find the last one weeks of fles updated in the sepecific directory and see those end with Z and ftp them to my backup server. Any help is appreciated. Thanks, Ravi :) (1 Reply)
Discussion started by: koduri0475
1 Replies

9. Shell Programming and Scripting

automated ftp script from unix -date range of files

Hi , I need some help to finish my ftp script and i need to find the last one weeks of fles updated in the sepecific directory and see those end with Z and ftp them to my backup server. Any help is appreciated. Thanks, Ravi :) (1 Reply)
Discussion started by: koduri0475
1 Replies
Login or Register to Ask a Question
MASSAGEVENDOR(8)					      System Manager's Manual						  MASSAGEVENDOR(8)

NAME
massagevendor - convert the ethernet vendor codes master list to arpwatch format SYNOPSIS
massagevendor vendorfile DESCRIPTION
massagevendor is a program that converts a text file containing ethernet vendor codes into a format suitable for use by arpwatch(8) and arpsnmp(8). The input vendorfile is a master text file containing vendor codes. The output is sent to stdout. Each line of the vendorfile is expected to have a six digit hexadecimal vendor code followed by spaces followed by the name of the manufacturer. All ethernet devices have a unique identifier which includes a vendor code specifying the manufacturer of the device. In normal operation arpwatch(8) and arpsnmp(8) use the file ethercodes.dat to report this vendor code. massagevendor is used to generate the ethercodes.dat file from text files containing these vendor codes. Locations where an ethernet vendor codes master text file can be obtained are given below. FILES
/var/lib/arpwatch - default location of the ethernet vendor list ethercodes.dat - file containing the list of ethernet vendor codes SEE ALSO
arpwatch(8), arpsnmp(8) NOTES
Sources for ethernet vendor codes seen in the wild are http://map-ne.com/Ethernet/vendor.html ftp://ftp.cavebear.com/pub/Ethernet.txt http://www.cavebear.com/CaveBear/Ethernet/vendor.html Useful for comparison or completeness are the ethernet vendor codes as assigned by the IEEE which can be found at http://standards.ieee.org/regauth/oui/oui.txt BUGS
Please send bug reports to arpwatch@ee.lbl.gov. AUTHORS
Craig Leres of the Lawrence Berkeley National Laboratory Network Research Group, University of California, Berkeley, CA. The current version is available via anonymous ftp: ftp://ftp.ee.lbl.gov/arpwatch.tar.gz This manual page was contributed by Hugo Graumann. MASSAGEVENDOR(8)