Re: Eliminating CLI overhead
| From: | Jason Barnett | Date: | Mon, 14 Mar 2005 15:14:30 +0000 |
| Subject: | Re: Eliminating CLI overhead | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-210659@lists.php.net to get a copy of this message | ||
Skippy wrote:
> I intend to run a lot of PHP scripts, all the time, on a Linux machine.
> The scripts were designed for CLI environment, since they will handle
> the entire management of the machine, being started by init and then
> effectively and completely taking over.
>
> I'm wondering whether starting up the PHP interpreter for every script
> hurts performance, if there's anything I can do about it, and if possible,
> would the potential gain be noticeable? We're talking a machine in the
> range of 1 GHz CPU speed, with IDE disk drives. I've already considered
> all kinds of Linux-specific "tricks", I'm interested in the pure PHP
> aspect of the issue.
>
If you want to reduce startup overhead then you could just run PHP as a
shared Apache module. You will save the time required for the MINIT
hooks... not sure how much time you'll end up saving, but you should
notice the difference. This would be especially true if you have a lot
of extensions compiled into PHP.
--
Teach a man to fish...
NEW? | http://www.catb.org/~esr/faqs/smart-questions.html
STFA | http://marc.theaimsgroup.com/?l=php-general&w=2
STFM | http://php.net/manual/en/index.php
STFW | http://www.google.com/search?q=php
LAZY |
http://mycroft.mozdev.org/download.html?name=PHP&submitform=Find+search+plugins
Attachment: [application/pgp-signature] OpenPGP digital signature signature.asc
Attachment: [application/pgp-signature] OpenPGP digital signature signature.asc