mail: acknowledgment of receipt?

mail: acknowledgment of receipt?

Post by Francisco Gordillo Alvar » Wed, 07 Aug 1996 04:00:00



How can I know if a message sent with mail has been received?
finger doesn't work always.
--
------------------------------------------------------------------------

------------------------------------------------------------------------

 
 
 

1. FTP acknowledgment for file receipt

Greetings,

Sorry for the long message.
I need some help with following problem:

Our company FTPing hundreds of files to a remote location through the
3rd party carrier.  When we transmit files we need to receive an
acknowledgement that files have been received by remote location.
However we only receive acknowledgment from the carrier that files
reached their cite.

The problem is that we still need to know whether files are at final
destination.

As I understand there are two ways to do this:
1.  Easy way:
Resident program will reside at the remote host and constantly look at
directory and its subdirs for new files to arrive.  As soon as files
are arrived it will send an email to us. I found an example of such
program on the web:
oldfiles=`ls -R`
while :                         # indefinite loop
do
    newfiles=`ls -R`
    if [ "$oldfiles" != "$newfiles" ]
    then
        echo >&2 "DIFFERENCE!"
        new=`(echo "$oldfiles"; echo "$newfiles") |
                awk 'F[$0]++ {next};
                END{ for (i in F) if (F[i]==1) print i }'`
        # Do some processing with the new file (append & to
           oldfiles=`ls`
while :                         # indefinite loop
do
    newfiles=`ls`
    if [ "$oldfiles" != "$newfiles" ]
    then
        echo >&2 "DIFFERENCE!"
        new=`(echo "$oldfiles"; echo "$newfiles") |
                awk 'F[$0]++ {next};
                END{ for (i in F) if (F[i]==1) print i }'`
        # Do some processing with the new file
        # for example send an email with file name received....
    fi
done

The problems with this script is that
 A.  It will also perform an action when files are deleted from
directory
 B.  If the directory is large enough I assume variable could not hold
such a large peace data.
 C. If hundreds of files will be transferred, we will receive hundreds
emails.
    I suspect that better solution is to notify FTP server that files
arrived.

2. Second way is probably harder to implement but the idea is to
notify our FTP server that files arrived.  However, since I do not
have any expirience in such programming I do not know even how to
start.

Would someone help me with an idea on how to do this better (probably
with more sophisticated program) or how to improve the script.

Thank you.

2. Where's Electric Eyes in RedHat 5.1?

3. mail acknowledgement...

4. Virtual Server Limit in Apache?

5. Mail read acknowledgement

6. web server

7. unix mail return receipt

8. XMMS and Ipchains DENY

9. execution upon receipt of mail

10. mail receipt problem

11. Unix mail return receipts

12. What's the correct enrty for return receipt mail?