Laris Benkis wrote: | We have a system in place where clients drop off files via FTP to a | wu-ftp server which are then processed automatically by scripts. Files | have to be processed relatively quickly for the application to work | properly therefore the convention we have developed is to indicate end | of transmission by doing a rename of the file once the initial put is done. | We are trying to tighten the security of the whole process and want to | use FW1 ftp resources to limit where puts can be done. Unfortunately it | turns out that when the ftp resources are used it is no longer possible to | do rename. | What is a reliable, transparent way to tell that an ftp transmission has | been completed? Depending on the OS, open(file, O_EXLOCK, mode) might work. You can also look at using lsof (ls open files) to see what files are open, or looking at the wu-ftp process to see what files it has open. (If your system has a /proc/$PID/fd/ type structure this could be very easy.) Adam -- "It is seldom that liberty of any kind is lost all at once." -Hume
This archive was generated by hypermail 2b30 : Fri Apr 13 2001 - 13:00:07 PDT