|
Posted by Blitzen on 01/23/08 10:40
On 1月21日, 下午9时17分, "C. (http://symcbean.blogspot.com/)"
<colin.mckin...@gmail.com> wrote:
> On 21 Jan, 10:18, drblitzkr...@gmail.com wrote:
>
> > Problem: If you need to run regularphpscriptsunderFastCGI, saving
> > on the overhead of fopen'ing and reading in the contents before
> > executing each time, in theory I guess you'd put a FastCgiServer
> > directive in your httpd.conf, and direct it to some sort of app (could
> > be written in C or anything) that loads and keeps in memory all your
> >phpfiles from your site, and runs their contents when a url request
> > comes in for that file. Does such an app exist?
>
> Yes - a ramdisk. But if you're using a sensible operating system it
> will be cached anyway.
>
> But more sensibly, aPHPaccelerator will go even further by caching a
> tokenized version of the script
>
> C.
Cool, thanks.
One thing: I'm using (from the sapi/cgi/php-cgi) and running my apps
instead of mod_php from apache, and it's not recognizing the mysql
functions. From strace I realized it wasn't finding php.ini, so I sym-
linked the correct one to where it was trying to look for it (/usr/
local/lib/php-cgi-fcgi.ini). Looks like it's finding it now, but still
not loading mysql - normally the mod_php executes /etc/php5/apache2/
php.ini and I guess at some point also executes the ones in /etc/php5/
conf.d, which are just 1 line each telling it to extension=mysqli.so
or whatever the module is. I dumped the contents of all of these into /
etc/php5/fcgi/php.ini and set:
extension_dir = "/usr/lib/php5/20060613/"
which is where they are. How to get the sapi cgi php binary to load
the mysql and other modules correctly to use in running apps?
Thx.
Navigation:
[Reply to this message]
|