PHP Server deamons

A

Anonymous

Guest
Does anyone have ever tried creating a php server deamon? If yes, have you used any sockets to communicate with it? I need some ideas/suggestions. Thanks :)
 
Why is that? I have already done this many times and works perfect. Now I am trying to create a child-proccess system and open sockets to communicate with. Of course it needs very high attention on security as well ...
 
If you're trying to create a serious server app, you're much better off using C++ or Java. PHP is not designed for writing server software, and will not serve you well for such.

However, if you want a good example of such an application, take a look at Nanoweb.
 
Thanks for the link! Seems very intresting... By the way I dont want to create an httpd deamon or something similar, just a small application to run some commands any time.

I think PHP is good for Server Apps, but not as best as possible. Plesk Control Panel is totally written in PHP.
 
mike said:
I think PHP is good for Server Apps, but not as best as possible. Plesk Control Panel is totally written in PHP.

Plesk Control Panel is not a daemon. In order for a daemon to work, it must be running constantly, which can be tricky with PHP. Plesk is just like any other web app -- it's executed only when it's requested.
 
Yeap, but its always running on the background and its ready to execute commands... is this a "deamon"?
 
I think youre confusing yourself between an
Server Application (Like Plesk ) and a daemon.

A daemon sits behind and answers the call.. (in the OS)
while a webiste reponds when given a request only
 
Well I know the difference between them but I made my self misundertood. I have created a deamon to execute linux commands, commands given through a web application. This "deamon" is running constantly and every 2" is checking a single file for commands to execute. I was wondering if I can do that in any other way like sockets or direct call.
 
Back
Top