[asterisk-dev] temporary file names for monitor files

Tzafrir Cohen tzafrir.cohen at xorcom.com
Fri May 30 08:24:54 CDT 2008


On Fri, May 30, 2008 at 09:09:14AM -0400, Matthew J. Roth wrote:

> 
>   3. Instead of waiting for the recording file to have no modifications 
> for a set amount of time, you could use the Linux command 'lsof' to 
> determine if Asterisk has the file open.

A bit OS-specific here, but a keyword on Linux, at least, is "inotify".

'man 7 inotify' for some general information. 

For those of you not interested in keeping your hands clean of C coding,
there are already a bunch of programs using it. e.g. a quick at search
gives me, among others:

incron - cron-like daemon which handles filesystem events
inotify-tools - command-line programs providing a simple interface to inotify

Bindigs are available for perl, python, ruby, and probably other
languages.

-- 
               Tzafrir Cohen
icq#16849755              jabber:tzafrir.cohen at xorcom.com
+972-50-7952406           mailto:tzafrir.cohen at xorcom.com
http://www.xorcom.com  iax:guest at local.xorcom.com/tzafrir



More information about the asterisk-dev mailing list