The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

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 and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Shell Script question ryanique Shell Programming and Scripting 10 08-26-2008 02:08 PM
Linux Shell Question: how to print the shell script name ? meili100 UNIX for Dummies Questions & Answers 3 07-01-2008 01:55 PM
Shell script question jbou1087 Shell Programming and Scripting 2 05-06-2008 02:01 AM
shell script question tselvanin Shell Programming and Scripting 2 08-28-2007 09:53 PM
A shell script question surjyap Shell Programming and Scripting 2 11-24-2005 05:48 AM

 
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1 (permalink)  
Old 09-01-2008
bsandeep_80 bsandeep_80 is offline
Registered User
  
 

Join Date: Jul 2007
Posts: 122
FTP - shell script question

Hi All,

I had a question on something which i have trying to add to my current shell script which does FTP of files from my local machine to a remote server.

I have 5 files which i zip and FTP them on daily basis to a remote server. My script is as below:
############################
#!/bin/sh
temp="put $1"
ftp xxxx.this is IP address of remote machine.com << EOFFile
myusername
binary
$temp
quit
EOFFile
exit 0
############################

I am successfull in doing this activity.

But sometimes there is some problem with the remote FTP machine the FTP fails.

My problem is that i am only able to determine this failure after manually logging in checking for the files on remote machine.

My remote files look like this on FTP machine, all the files have the same name each day and The system date of this matches with the local machine:

08-31-08 10:00PM 55182 help1.zip
08-31-08 10:00PM 64861 help2.zip
08-31-08 10:00PM 57915 help3.zip
08-31-08 10:01PM 224245 help4.zip
08-31-08 10:01PM 2388 help5.zip


Is there a way i can add in my script or have an external script that checks for these files on FTP machine( probablly compare with local machine date stamp and FTP date stamp to determine the latest files are there).

Please suggest

Thanks,
Sandy
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 10:53 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0