[Asterisk-Users] Outgoing spool file ignored

Jean-Denis Girard jd.girard at sysnux.pf
Sun May 15 12:27:43 MST 2005


trixter http://www.0xdecafbad.com a écrit :
> How do you create them?
> 
> There is a race condition with asterisk and the spool where if you
> create the file or copy it into the queue directory asterisk tries to
> read and parse the file before you have finished writing it.  A
> suggested method instead is to create it on the same partition then move
> it into the appropriate directory to prevent this from occuring.

Thanks for your reply, but unfortunately I'm aware of this, and the file 
is first created in a temporary directory, then moved to asterisk's 
outgoing directory. Move is done from a Perl script, using the 
File::Copy module; I think it's an atomic operation on Linux (like the 
mv shell command), but maybe I'm wrong?


Thanks,
-- 
Jean-Denis Girard

SysNux                  Systèmes Linux en Polynésie française
http://www.sysnux.pf/   Tél: +689 483 527 / GSM: +689 797 527



More information about the asterisk-users mailing list