Apache2 ~ Worker or PreFork

Apache2 ~ Worker or PreFork

am 18.05.2007 04:18:08 von janedunnie

Hi,

Without root access, is there an easy way to tell if the Linux server
I am using is running Apache as Worker or Prefork?

Failing that, with root access, how would I tell?

Many thanks in advance,
Jane

Re: Apache2 ~ Worker or PreFork

am 31.05.2007 06:48:00 von CamelRichard

Jane,

I'm not sure of the specifics for Linux, but this is how you would
tell for Solaris, and I assume the methods would be very similar:

Under the apache root directory, in this case, /u01/app/apache, cd to
the "build" directory and cat the "config.nice" file. This file
contains the options that were used during configure, for example:

----------------------------------------------

% cat config.nice
#! /bin/sh
#
# Created by configure

"./configure" \
"--prefix=/u01/app/apache" \
"--disable-ipv6" \
"--enable-so" \
"--enable-rewrite" \
"--enable-proxy" \
"--with-mpm=worker" \
"$@"

----------------------------------------------

in this case, apache was compiled with worker.

another way would be, under the apache root dir, cd to bin:

% ./httpd -l
Compiled in modules:
core.c
mod_authn_file.c
mod_authn_default.c
mod_authz_host.c
mod_authz_groupfile.c
mod_authz_user.c
mod_authz_default.c
mod_auth_basic.c
mod_include.c
mod_filter.c
mod_log_config.c
mod_env.c
mod_setenvif.c
mod_proxy.c
mod_proxy_connect.c
mod_proxy_ftp.c
mod_proxy_http.c
mod_proxy_ajp.c
mod_proxy_balancer.c
worker.c
http_core.c
mod_mime.c
mod_status.c
mod_autoindex.c
mod_asis.c
mod_cgid.c
mod_negotiation.c
mod_dir.c
mod_actions.c
mod_userdir.c
mod_alias.c
mod_rewrite.c
mod_so.c

shows that worker was compiled into apache.

You might also find some useful info here:

http://www.camelrichard.org/apache-prefork-vs-worker

Hope that helps.


kyle.reynolds@camelrichard.org








On 17 May 2007 19:18:08 -0700, janedunnie@gmail.com wrote:

>Hi,
>
>Without root access, is there an easy way to tell if the Linux server
>I am using is running Apache as Worker or Prefork?
>
>Failing that, with root access, how would I tell?
>
>Many thanks in advance,
>Jane