Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Cherokee: users

PHP FastCGI

 

 

Cherokee users RSS feed   Index | Next | Previous | View Threaded


dmiller at amfes

Jul 7, 2009, 12:06 PM

Post #1 of 8 (681 views)
Permalink
PHP FastCGI

Is there a "rule of thumb" for determining the appropriate number of
FastCGI processes? In my case, I'm supporting a small LAN of less than
10 workstations, but I don't want any delays when they visit the
different PHP virtual servers. I would think just 1 or 2 would be
sufficient - but is there something I'm missing?
--
Daniel
_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee


stefan at konink

Jul 7, 2009, 2:14 PM

Post #2 of 8 (637 views)
Permalink
Re: PHP FastCGI [In reply to]

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Daniel L. Miller wrote:
> Is there a "rule of thumb" for determining the appropriate number of
> FastCGI processes? In my case, I'm supporting a small LAN of less than
> 10 workstations, but I don't want any delays when they visit the
> different PHP virtual servers. I would think just 1 or 2 would be
> sufficient - but is there something I'm missing?

The amount of concurrent clients would be your number of PHP instances.


Stefan
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEAREKAAYFAkpTurkACgkQYH1+F2Rqwn2YjACfbwXI664gufrvwN0VpXr+FP3S
lH4AoIUvaIS4YnW6I0Vb4S3V6K/yVOG8
=zwg1
-----END PGP SIGNATURE-----
_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee


gwolf at gwolf

Jul 8, 2009, 6:39 AM

Post #3 of 8 (631 views)
Permalink
Re: PHP FastCGI [In reply to]

Daniel L. Miller dijo [Tue, Jul 07, 2009 at 12:06:55PM -0700]:
> Is there a "rule of thumb" for determining the appropriate number of
> FastCGI processes? In my case, I'm supporting a small LAN of less than
> 10 workstations, but I don't want any delays when they visit the
> different PHP virtual servers. I would think just 1 or 2 would be
> sufficient - but is there something I'm missing?

It is not _so_ important the amount of users, but the frequency of the
hits and the complexity of your program. Do you expect to have a
constant rate, say, more than one hit per five seconds? A execution
time of over one second? If neither of those is true, you could be
fine with a single process - of course, launching two (or even three)
to avoid collisions won't hurt too much.

--
Gunnar Wolf • gwolf [at] gwolf • (+52-55)5623-0154 / 1451-2244
_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee


santagada at gmail

Jul 8, 2009, 10:11 AM

Post #4 of 8 (634 views)
Permalink
Re: PHP FastCGI [In reply to]

On Jul 8, 2009, at 10:39 AM, Gunnar Wolf wrote:

> Daniel L. Miller dijo [Tue, Jul 07, 2009 at 12:06:55PM -0700]:
>> Is there a "rule of thumb" for determining the appropriate number of
>> FastCGI processes? In my case, I'm supporting a small LAN of less
>> than
>> 10 workstations, but I don't want any delays when they visit the
>> different PHP virtual servers. I would think just 1 or 2 would be
>> sufficient - but is there something I'm missing?
>
> It is not _so_ important the amount of users, but the frequency of the
> hits and the complexity of your program. Do you expect to have a
> constant rate, say, more than one hit per five seconds? A execution
> time of over one second? If neither of those is true, you could be
> fine with a single process - of course, launching two (or even three)
> to avoid collisions won't hurt too much.


Isn't there a way to specify a range like in apache for the prefork
worker? Minimal number of processes and a maximum would be great. Just
in case some site gets slashdoted :)

--
Leonardo Santagada
santagada at gmail.com



_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee


alvaro at octality

Jul 8, 2009, 10:34 AM

Post #5 of 8 (625 views)
Permalink
Re: PHP FastCGI [In reply to]

On 08-jul-09, at 19:11, Leonardo Santagada wrote:
> On Jul 8, 2009, at 10:39 AM, Gunnar Wolf wrote:
>
>> Daniel L. Miller dijo [Tue, Jul 07, 2009 at 12:06:55PM -0700]:
>>> Is there a "rule of thumb" for determining the appropriate number of
>>> FastCGI processes? In my case, I'm supporting a small LAN of less
>>> than
>>> 10 workstations, but I don't want any delays when they visit the
>>> different PHP virtual servers. I would think just 1 or 2 would be
>>> sufficient - but is there something I'm missing?
>>
>> It is not _so_ important the amount of users, but the frequency of
>> the
>> hits and the complexity of your program. Do you expect to have a
>> constant rate, say, more than one hit per five seconds? A execution
>> time of over one second? If neither of those is true, you could be
>> fine with a single process - of course, launching two (or even three)
>> to avoid collisions won't hurt too much.
>
> Isn't there a way to specify a range like in apache for the prefork
> worker? Minimal number of processes and a maximum would be great. Just
> in case some site gets slashdoted :)


That'd be a great feature, indeed.

However, that's something the PHP folks would have to implement in php-
cgi. There is no much we can do (except start hacking PHP).

--
Octality
http://www.octality.com/

_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee


jbozza at mindsites

Jul 8, 2009, 11:26 AM

Post #6 of 8 (627 views)
Permalink
Re: PHP FastCGI [In reply to]

> > Isn't there a way to specify a range like in apache for the prefork
> > worker? Minimal number of processes and a maximum would be great.
> Just
> > in case some site gets slashdoted :)
>
>
> That'd be a great feature, indeed.
>
> However, that's something the PHP folks would have to implement in php-
> cgi. There is no much we can do (except start hacking PHP).

Isn't this something that php-fpm does?

http://php-fpm.org/Configuration_File - under "apache_like" mode.



Jaime

_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee


santagada at gmail

Jul 8, 2009, 1:15 PM

Post #7 of 8 (626 views)
Permalink
Re: PHP FastCGI [In reply to]

On Jul 8, 2009, at 3:26 PM, Jaime Bozza wrote:

>>> Isn't there a way to specify a range like in apache for the prefork
>>> worker? Minimal number of processes and a maximum would be great.
>> Just
>>> in case some site gets slashdoted :)
>>
>>
>> That'd be a great feature, indeed.
>>
>> However, that's something the PHP folks would have to implement in
>> php-
>> cgi. There is no much we can do (except start hacking PHP).
>
> Isn't this something that php-fpm does?
>
> http://php-fpm.org/Configuration_File - under "apache_like" mode.

"Valid values are 'static' and 'apache-like'. Default "static". NOTE:
only 'static' has effect currently"
:(

I found this feature interesting:
http://php-fpm.org/Features#Accelerated_upload_support

If cherokee supported this it would be great to make file uploads
faster if they need to be processed after by a fcgi process.

--
Leonardo Santagada
santagada at gmail.com



_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee


jbozza at mindsites

Jul 8, 2009, 1:31 PM

Post #8 of 8 (626 views)
Permalink
Re: PHP FastCGI [In reply to]

> "Valid values are 'static' and 'apache-like'. Default "static". NOTE:
> only 'static' has effect currently"
> :(

I missed that... At least they're thinking about it! With the fact that the project has been picked up again, it may be something to watch.

> I found this feature interesting:
> http://php-fpm.org/Features#Accelerated_upload_support
>
> If cherokee supported this it would be great to make file uploads
> faster if they need to be processed after by a fcgi process.

Sounds like an interesting feature!

Jaime

_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee

Cherokee users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.