You are here: Re: mod_php or fastcgi? « PHP Programming Language « IT news, forums, messages
Re: mod_php or fastcgi?

Posted by Richard Levasseur on 12/16/98 11:52

Michael Vilain wrote:
> In article <1152384534.171573.170610@m73g2000cwd.googlegroups.com>,
> howachen@gmail.com wrote:
>
> > Michael Vilain õçì¼ÅF
> >
> > > In article <1152365690.253421.109840@b28g2000cwb.googlegroups.com>,
> > > howachen@gmail.com wrote:
> > >
> > > > hi,
> > > >
> > > > which package you perfer?
> > > >
> > > > mod_php on apache is okay but some people said fastcgi version of php
> > > > is faster, is it true?
> > > >
> > > > thanks...
> > >
> > > Depends. (That's the standard answer for ambiguous questions which don't
> > > have sufficient technical details to provide an informed opinion).
> > >
> > > Specifically, it depends on the environment (hardware and software)
> > > you're running on. OS and version? Hardware platform--CPU, memory,
> > > disk? Shared web server or dedicated? What sort of web application are
> > > you running? How much traffic is it expected to handle currently? In 6
> > > months? 1 year? 3 years?
> > >
> > > It's my understanding that fastcgi forks a process for each connection,
> > > running in the context of web server. mod_php runs as a thread, allowing
> > > for
> > > it to run concurrently with other processes on multi-CPU systems.
> > >
> > > --
> > > DeeDee, don't press that button! DeeDee! NO! Dee...
> >
> > consider the followings...
> >
> > OS - CentOS 4.3
> > CPU - Intel Pentium D Dual Core 2.8Ghz
> > Memory - 2GB DDR2
> > Dedicated Web server
> > Expect to handle around 500 connections, each requests use at most 3MB
> > of memory
>
> For security on my shared web host, I use CGI when I need to run a perl
> script as a specific user. My ISP provides CGIwrap for this purpose.
> Otherwise, I run all my site using mod_php. It can access the MySQL
> database and display the pages and is fast enough.
>
> Since you have a dual core system, I'd use mod_php. You'd be able to benefit
> from it immediately with a threaded Apache server. And the site will
> scale if you add more CPUs.
>
> --
> DeeDee, don't press that button! DeeDee! NO! Dee...

Theorectically, except PHP isn't thread safe, and requires you use the
pre-fork model of apache. This is suppose to change, eventually. Word
is mod_php is faster, by and large though, probably because its
integrated more with apache than a completely seperate cgi process.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация