Hi, I need to write a script for fetching 2 files which come(thru FTP) to server1 at a particular location (/u/home/folder1). Now the condition is, the files are transmitted from another server (server2) between 3pm to 4pm (server time). The script should check if both files have come to the location (/u/home/folder1). If one file has come (thru FTP) and if the other has not yet arrived, then the script must wait for some time and then check, if the file has arrived, then the script should end by emailing me that both files have arrived. I've built the code for FTP to get the files. The problem is what could be done to check the files for that long period of time? And the script should run in the background.
Please help in this regard.