The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
To call/execute a shell script from a shell script konark UNIX for Dummies Questions & Answers 1 10-26-2007 02:16 PM
How to pass a parameter from one Shell-script to another Shell-script subodhbansal Shell Programming and Scripting 2 09-22-2007 02:19 AM
How to Run a shell script from Perl script in Parent shell? hifake Shell Programming and Scripting 16 08-28-2007 05:42 PM
Accessing variables of one shell script in another shell script rsendhilmani Shell Programming and Scripting 1 04-30-2007 05:43 AM
Have a shell script call another shell script and exit heprox Shell Programming and Scripting 2 11-20-2006 05:17 AM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 10-25-2005
Registered User
 

Join Date: Oct 2005
Posts: 3
shell script

can anyone plz help me in writing the shell script with the following requirements

I have a directory which has a lot of files getting generated automatically every 15 minutes .The script has to identify the files which are created in the last 15 min (configurable ) and transfer them to another FTP server automatically.The file naming convention will be YYYYMMDDHHmmss.* .Files should be renamed in the source directory once copied to the desination with some extension .

Thanks

Naren
Reply With Quote
Forum Sponsor
  #2  
Old 10-26-2005
Registered User
 

Join Date: Jul 2005
Location: Oak Park, IL
Posts: 100
My guess is the hangup is doing the every-15-minutes thing. I would do this:

#!/bin/ksh

list=`find /path/to/dir -newer /tmp/.timestamp -print`
ftp_list_to_server # $list contains your files
touch /tmp/.timestamp # holds the time when you last ftp'ed over

for information about ftp'ing automatically, you can go to
http://www.experts-exchange.com/Oper..._21383832.html
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 06:13 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0