|
Polling an FTP site for a file
Hi,
I'm after a bit of advice for the best way to collect files from an ftp server via a unix process. The main issue here is the frequency, the job needs to check for files every minute or so between 8am and 8pm and pull them down to the box if there is anything there.
Originally the transfer was going to be done via a VPN tunnel direct to a directory on my machine which my batch job would poll, but life is never simple. Unfortunately, that has now fallen through and the files are now being placed on an ftp site instead and I have to pull the files from there as security will not allow a push from there when a file is deposited on it, which also would have made life easier.
My question is, is there a way of opening a connection to the ftp site and keeping it open to poll for a file for that long, or am I just going to have to open and close connections repeatedly throughout the day?
Is there a better way?
Cheers
Paul.
|