[asterisk-users] Asterisk AMI - Create a daemon (background process)

Eric Wieling EWieling at nyigc.com
Tue Feb 26 10:29:44 CST 2013

PHP has had memory leak issues in the past, though modern versions are apparently much better.

The thing is, when you write a daemon you must EXPECT it to exit at some point, maybe the socket went away or the system restarted or you are out of memory, whatever.  You need to make sure you handle these situations regardless of which language you write in.   Using inittab is one way, daemon-tools is another.  For me, PHP with its C-like syntax, decent string handling, Perl Regex, and POSIX process control (including fork), it is "good enough" for most stuff that I do.  

-----Original Message-----
From: asterisk-users-bounces at lists.digium.com [mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Steve Edwards
Sent: Tuesday, February 26, 2013 11:12 AM
To: Asterisk Users Mailing List - Non-Commercial Discussion
Subject: Re: [asterisk-users] Asterisk AMI - Create a daemon (background process)

On Tue, 26 Feb 2013, Paul Belanger wrote:

> You don't want to use PHP for your daemon, change to another scripting 
> language (EG: python).


I'm just a 'c' weenie, but why would Python be a better choice than PHP?

Thanks in advance,
Steve Edwards       sedwards at sedwards.com      Voice: +1-760-468-3867 PST
Newline                                              Fax: +1-760-731-3000

-- Bandwidth and Colocation Provided by http://www.api-digital.com -- New to Asterisk? Join us for a live introductory webinar every Thurs:

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:

More information about the asterisk-users mailing list