Re: daemon without pcntl_fork

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2009/8/18 Per Jessen <per@xxxxxxxxxxxx>:
> Lars Torben Wilson wrote:
>
>> Again, that's not a daemon. If it is sufficient to run a background
>> process then that's fine, but that doesn't make it a daemon (although
>> it shares some things in common with a daemon). The background process
>> still has a controlling terminal (even if input and output have been
>> redirected), and a fully-implemented daemon will typically perform
>> other tasks which make it a good system citizen, such as: becoming
>> session leader, chroot'ing to / so that the filesystem it was started
>> from can be unmounted if necessary, and so on.
>
> Torben, you're really just splitting hairs - the OP didn't ask for the
> definition of "daemon', he just wanted a script to run continually as
> if it was a daemon.  Besides, I did also suggest using either setsid or
> openSUSEs startproc.

Thank you for the lecture. Your opinion of my post on this is quite
beside the point. If Jim needs a daemon, then he should probably use a
daemon coded the best way possible. If not, then that's fine too. As
you correctly pointed out, there are ways to fake it. I simply feel
that Jim should be made aware of potential drawbacks. That's perhaps
splitting hairs--it's also being thorough. Clients don't tend to
appreciate being told that a lack of thoroughness arose from a fear of
splitting hairs.


Regards,

Torben

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux