Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 7th November 2006, 02:27
satimis satimis is offline
Senior Member
 
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
Default Help - problem after config subversion

Hi folks,

ubuntu-6.06.1-LAMP-server

This is a test on building a server.

I followed
Setup Subversion with Apache2 on Ubuntu
http://www.jessejcollins.com/blog/in...on-Ubuntu.html


encountering problem on running;
$ sudo /etc/init.d/apache2 restart
Code:
 * Forcing reload of apache 2.0 web server...
[Mon Nov 06 11:50:49 2006] [crit] Apache is running a threaded MPM, but
your PHP Module is not compiled to be threadsafe.  You need to recompile
PHP.
Pre-configuration failed                   [fail]
Whether I need to re-install PHP and reconfig it thereafter? Please help. TIA


B.R.
satimis
Reply With Quote
Sponsored Links
  #2  
Old 8th November 2006, 17:05
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,741 Times in 2,575 Posts
Default

Which Apache MPM are you using? You must use the prefork MPM, otherwise you cannot use PHP as an Apache module.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 9th November 2006, 02:42
satimis satimis is offline
Senior Member
 
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
Default

Hi falko,

Tks for your advice.

Quote:
Which Apache MPM are you using? You must use the prefork MPM, otherwise you cannot use PHP as an Apache module.
$ sudo apt-cache search apache2 | grep mpm
Code:
apache2-mpm-perchild - experimental high speed perchild threaded model for Apache2
apache2-mpm-prefork - traditional model for Apache2
apache2-mpm-worker - high speed threaded model for Apache2
$ which apache2-mpm
No printout

$ sudo find / -name apache2-mpm
No printout

I hesitate whether it has been installed?

The small tool "equery" is not installed on the PC. Nor can I find the package offering this tool.

$ sudo equery l apache2-mem
Code:
sudo: equery: command not found
$ which equery
no printout

Tks


Edit-1:- * * *

$ ls /etc/apache2/mods-enabled/ | grep mpm
$ ls /etc/apache2/mods-available/ | grep mpm
both no printout

$ ls /etc/apache2/mods-available/
Code:
actions.load      cgid.load              expires.load     mime_magic.load     ssl.conf
asis.load         cgi.load               ext_filter.load  php5.conf           ssl.load
auth_anon.load    dav_fs.conf            file_cache.load  php5.load           suexec.load
auth_dbm.load     dav_fs.load            headers.load     proxy.conf          unique_id.load
auth_digest.load  dav.load               imap.load        proxy_connect.load  userdir.conf
auth_ldap.load    dav_svn.conf           include.load     proxy_ftp.load      userdir.load
auth_mysql.load   dav_svn.conf.original  info.load        proxy_http.load     usertrack.load
cache.load        dav_svn.load           ldap.load        proxy.load          vhost_alias.load
cern_meta.load    deflate.load           mem_cache.load   rewrite.load
cgid.conf         disk_cache.load        mime_magic.conf  speling.load
$ ls /etc/apache2/mods-enabled/
Code:
cgid.conf  dav_fs.conf  dav.load      dav_svn.load  php5.load  ssl.load      userdir.load
cgid.load  dav_fs.load  dav_svn.conf  php5.conf     ssl.conf   userdir.conf

B.R.
satimis

Last edited by satimis; 9th November 2006 at 04:11.
Reply With Quote
  #4  
Old 9th November 2006, 17:09
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,741 Times in 2,575 Posts
Default

You can find out about your MPM by running

Code:
apache2 -V
A sample output looks like this:

Code:
Server version: Apache/2.0.54
Server built:   Sep  5 2005 11:15:09
Server's Module Magic Number: 20020903:9
Architecture:   32-bit
Server compiled with....
 -D APACHE_MPM_DIR="server/mpm/prefork"
 -D APR_HAS_SENDFILE
 -D APR_HAS_MMAP
 -D APR_HAVE_IPV6 (IPv4-mapped addresses enabled)
 -D APR_USE_SYSVSEM_SERIALIZE
 -D APR_USE_PTHREAD_SERIALIZE
 -D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
 -D APR_HAS_OTHER_CHILD
 -D AP_HAVE_RELIABLE_PIPED_LOGS
 -D HTTPD_ROOT=""
 -D SUEXEC_BIN="/usr/lib/apache2/suexec2"
 -D DEFAULT_PIDLOG="/var/run/httpd.pid"
 -D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
 -D DEFAULT_LOCKFILE="/var/run/accept.lock"
 -D DEFAULT_ERRORLOG="logs/error_log"
 -D AP_TYPES_CONFIG_FILE="/etc/apache2/mime.types"
 -D SERVER_CONFIG_FILE="/etc/apache2/apache2.conf"
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #5  
Old 9th November 2006, 17:25
satimis satimis is offline
Senior Member
 
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
Default

Hi falko,

Quote:
You can find out about your MPM by running

Code:
apache2 -V
$ apache2 -V
Code:
Server version: Apache/2.0.55
Server built:   Jul 26 2006 18:01:22
Server's Module Magic Number: 20020903:11
Architecture:   64-bit
Server compiled with....
 -D APACHE_MPM_DIR="server/mpm/prefork"
 -D APR_HAS_SENDFILE
 -D APR_HAS_MMAP
 -D APR_HAVE_IPV6 (IPv4-mapped addresses enabled)
 -D APR_USE_SYSVSEM_SERIALIZE
 -D APR_USE_PTHREAD_SERIALIZE
 -D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
 -D APR_HAS_OTHER_CHILD
 -D AP_HAVE_RELIABLE_PIPED_LOGS
 -D HTTPD_ROOT=""
 -D SUEXEC_BIN="/usr/lib/apache2/suexec2"
 -D DEFAULT_PIDLOG="/var/run/apache2.pid"
 -D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
 -D DEFAULT_LOCKFILE="/var/run/apache2/accept.lock"
 -D DEFAULT_ERRORLOG="logs/error_log"
 -D AP_TYPES_CONFIG_FILE="/etc/apache2/mime.types"
 -D SERVER_CONFIG_FILE="/etc/apache2/apache2.conf"
Following line looks different from your sample;
Code:
 -D DEFAULT_PIDLOG="/var/run/apache2.pid"
" -D APACHE_MPM_DIR="server/mpm/prefork"" is there.

Tks.

B.R.
satimis
Reply With Quote
  #6  
Old 10th November 2006, 16:32
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,741 Times in 2,575 Posts
Default

So your Apache is using the correct MPM...
Can you post the part of /etc/apache2/apache2.conf that looks like this?

Code:
##
## Server-Pool Size Regulation (MPM specific)
##

# prefork MPM
# StartServers ......... number of server processes to start
# MinSpareServers ...... minimum number of server processes which are kept spare
# MaxSpareServers ...... maximum number of server processes which are kept spare
# MaxClients ........... maximum number of server processes allowed to start
# MaxRequestsPerChild .. maximum number of requests a server process serves
<IfModule prefork.c>
StartServers             5
MinSpareServers          5
MaxSpareServers         15
MaxClients             200
MaxRequestsPerChild  10000
</IfModule>

# pthread MPM
# StartServers ......... initial  number of server processes to start
# MaxClients ........... maximum  number of server processes allowed to start
# MinSpareThreads ...... minimum  number of worker threads which are kept spare
# MaxSpareThreads ...... maximum  number of worker threads which are kept spare
# ThreadsPerChild ...... constant number of worker threads in each server process
# MaxRequestsPerChild .. maximum  number of requests a server process serves
<IfModule worker.c>
StartServers         2
MaxClients         150
MinSpareThreads     25
MaxSpareThreads     75
ThreadsPerChild     25
MaxRequestsPerChild  0
</IfModule>

# perchild MPM
# NumServers ........... constant number of server processes
# StartThreads ......... initial  number of worker threads in each server process
# MinSpareThreads ...... minimum  number of worker threads which are kept spare
# MaxSpareThreads ...... maximum  number of worker threads which are kept spare
# MaxThreadsPerChild ... maximum  number of worker threads in each server process
# MaxRequestsPerChild .. maximum  number of connections per server process (then it dies)
<IfModule perchild.c>
NumServers           5
StartThreads         5
MinSpareThreads      5
MaxSpareThreads     10
MaxThreadsPerChild  20
MaxRequestsPerChild  0
AcceptMutex fcntl
</IfModule>
What's the output of
Code:
ls -la /etc/apache2/mods-enabled
and
Code:
ls -la /etc/apache2/mods-available
?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #7  
Old 10th November 2006, 16:47
satimis satimis is offline
Senior Member
 
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
Default

Hi falko,

Quote:
Can you post the part of /etc/apache2/apache2.conf that looks like this?
$ cat /etc/apache2/apache2.conf
Code:
....
# prefork MPM
# StartServers ......... number of server processes to start
# MinSpareServers ...... minimum number of server processes which are kept spare# MaxSpareServers ...... maximum number of server processes which are kept spare# MaxClients ........... maximum number of server processes allowed to start
# MaxRequestsPerChild .. maximum number of requests a server process serves
<IfModule prefork.c>
StartServers         5
MinSpareServers      5
MaxSpareServers     10
MaxClients          20
MaxRequestsPerChild  0
</IfModule>

# pthread MPM
# StartServers ......... initial  number of server processes to start
# MaxClients ........... maximum  number of server processes allowed to start
# MinSpareThreads ...... minimum  number of worker threads which are kept spare
# MaxSpareThreads ...... maximum  number of worker threads which are kept spare
# ThreadsPerChild ...... constant number of worker threads in each server process
# MaxRequestsPerChild .. maximum  number of requests a server process serves
<IfModule worker.c>
StartServers         2
MaxClients         150
MinSpareThreads     25
MaxSpareThreads     75
ThreadsPerChild     25
MaxRequestsPerChild  0
</IfModule>

# perchild MPM
# NumServers ........... constant number of server processes
# StartThreads ......... initial  number of worker threads in each server process
# MinSpareThreads ...... minimum  number of worker threads which are kept spare
# MaxSpareThreads ...... maximum  number of worker threads which are kept spare
# MaxThreadsPerChild ... maximum  number of worker threads in each server process
# MaxRequestsPerChild .. maximum  number of connections per server process (then it dies)
<IfModule perchild.c>
NumServers           5
StartThreads         5
MinSpareThreads      5
MaxSpareThreads     10
MaxThreadsPerChild  20
MaxRequestsPerChild  0
AcceptMutex fcntl
</IfModule>
....
Quote:
What's the output of
Code:
ls -la /etc/apache2/mods-enabled
$ ls -la /etc/apache2/mods-enabled
Code:
total 8
drwxr-xr-x 2 root root 4096 2006-11-09 11:39 .
drwxr-xr-x 8 root root 4096 2006-11-09 12:15 ..
lrwxrwxrwx 1 root root   36 2006-11-09 11:39 cgi.load -> /etc/apache2/mods-available/cgi.load
lrwxrwxrwx 1 root root   29 2006-11-06 10:48 dav_fs.conf -> ../mods-available/dav_fs.conf
lrwxrwxrwx 1 root root   29 2006-11-06 10:48 dav_fs.load -> ../mods-available/dav_fs.load
lrwxrwxrwx 1 root root   26 2006-11-06 10:48 dav.load -> ../mods-available/dav.load
lrwxrwxrwx 1 root root   30 2006-11-06 10:48 dav_svn.conf -> ../mods-available/dav_svn.conf
lrwxrwxrwx 1 root root   30 2006-11-06 10:48 dav_svn.load -> ../mods-available/dav_svn.load
lrwxrwxrwx 1 root root   37 2006-10-17 04:38 php5.conf -> /etc/apache2/mods-available/php5.conf
lrwxrwxrwx 1 root root   37 2006-10-17 04:38 php5.load -> /etc/apache2/mods-available/php5.load
lrwxrwxrwx 1 root root   36 2006-10-29 17:26 ssl.conf -> /etc/apache2/mods-available/ssl.conf
lrwxrwxrwx 1 root root   36 2006-10-29 17:26 ssl.load -> /etc/apache2/mods-available/ssl.load
lrwxrwxrwx 1 root root   40 2006-10-17 04:38 userdir.conf -> /etc/apache2/mods-available/userdir.conf
lrwxrwxrwx 1 root root   40 2006-10-17 04:38 userdir.load -> /etc/apache2/mods-available/userdir.load

Quote:
and
Code:
ls -la /etc/apache2/mods-available
?
$ ls -la /etc/apache2/mods-available
Code:
total 200
drwxr-xr-x 2 root root 4096 2006-11-09 11:39 .
drwxr-xr-x 8 root root 4096 2006-11-09 12:15 ..
-rw-r--r-- 1 root root   66 2006-07-26 18:03 actions.load
-rw-r--r-- 1 root root   60 2006-07-26 18:03 asis.load
-rw-r--r-- 1 root root   70 2006-07-26 18:03 auth_anon.load
-rw-r--r-- 1 root root   68 2006-07-26 18:03 auth_dbm.load
-rw-r--r-- 1 root root   74 2006-07-26 18:03 auth_digest.load
-rw-r--r-- 1 root root  130 2006-07-26 18:03 auth_ldap.load
-rw-r--r-- 1 root root   72 2006-04-06 04:58 auth_mysql.load
-rw-r--r-- 1 root root   62 2006-07-26 18:03 cache.load
-rw-r--r-- 1 root root   70 2006-07-26 18:03 cern_meta.load
-rw-r--r-- 1 root root   61 2006-07-26 18:03 cgid.conf
-rw-r--r-- 1 root root   60 2006-07-26 18:03 cgid.load
-rw-r--r-- 1 root root   58 2006-07-26 18:03 cgi.load
-rw-r--r-- 1 root root   37 2006-07-26 18:03 dav_fs.conf
-rw-r--r-- 1 root root   64 2006-07-26 18:03 dav_fs.load
-rw-r--r-- 1 root root   58 2006-07-26 18:03 dav.load
-rw-r--r-- 1 root root 1283 2006-11-06 11:40 dav_svn.conf
-rw-r--r-- 1 root root 1331 2006-11-06 11:37 dav_svn.conf.original
-rw-r--r-- 1 root root  174 2006-05-08 07:40 dav_svn.load
-rw-r--r-- 1 root root   66 2006-07-26 18:03 deflate.load
-rw-r--r-- 1 root root   72 2006-07-26 18:03 disk_cache.load
-rw-r--r-- 1 root root   66 2006-07-26 18:03 expires.load
-rw-r--r-- 1 root root   72 2006-07-26 18:03 ext_filter.load
-rw-r--r-- 1 root root   72 2006-07-26 18:03 file_cache.load
-rw-r--r-- 1 root root   66 2006-07-26 18:03 headers.load
-rw-r--r-- 1 root root   60 2006-07-26 18:03 imap.load
-rw-r--r-- 1 root root   66 2006-07-26 18:03 include.load
-rw-r--r-- 1 root root   60 2006-07-26 18:03 info.load
-rw-r--r-- 1 root root   60 2006-07-26 18:03 ldap.load
-rw-r--r-- 1 root root   70 2006-07-26 18:03 mem_cache.load
-rw-r--r-- 1 root root   85 2006-07-26 18:03 mime_magic.conf
-rw-r--r-- 1 root root   72 2006-07-26 18:03 mime_magic.load
-rw-r--r-- 1 root root  133 2006-07-18 23:21 php5.conf
-rw-r--r-- 1 root root   59 2006-07-18 23:21 php5.load
-rw-r--r-- 1 root root  840 2006-07-26 18:03 proxy.conf
-rw-r--r-- 1 root root   78 2006-07-26 18:03 proxy_connect.load
-rw-r--r-- 1 root root   70 2006-07-26 18:03 proxy_ftp.load
-rw-r--r-- 1 root root   72 2006-07-26 18:03 proxy_http.load
-rw-r--r-- 1 root root  316 2006-07-26 18:03 proxy.load
-rw-r--r-- 1 root root   66 2006-07-26 18:03 rewrite.load
-rw-r--r-- 1 root root   66 2006-07-26 18:03 speling.load
-rw-r--r-- 1 root root 3545 2006-07-26 18:03 ssl.conf
-rw-r--r-- 1 root root   58 2006-07-26 18:03 ssl.load
-rw-r--r-- 1 root root   64 2006-07-26 18:03 suexec.load
-rw-r--r-- 1 root root   70 2006-07-26 18:03 unique_id.load
-rw-r--r-- 1 root root  244 2006-07-26 18:03 userdir.conf
-rw-r--r-- 1 root root   66 2006-07-26 18:03 userdir.load
-rw-r--r-- 1 root root   70 2006-07-26 18:03 usertrack.load
-rw-r--r-- 1 root root   74 2006-07-26 18:03 vhost_alias.load
Tks

B.R.
satimis
Reply With Quote
  #8  
Old 11th November 2006, 17:09
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,741 Times in 2,575 Posts
Default

Please change
Code:
<IfModule prefork.c>
StartServers         5
MinSpareServers      5
MaxSpareServers     10
MaxClients          20
MaxRequestsPerChild  0
</IfModule>
to
Code:
<IfModule prefork.c>
StartServers         5
MinSpareServers      5
MaxSpareServers     10
MaxClients          20
MaxRequestsPerChild  10000
</IfModule>
and restart Apache.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #9  
Old 12th November 2006, 12:36
satimis satimis is offline
Senior Member
 
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
Default

Hi falko,

Apache2 is now running.

$ sudo /etc/init.d/apache2 restart
Code:
Password:
 * Forcing reload of apache 2.0 web server... apache2: Could not determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
apache2: Could not determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
                                                                         [ ok ]
After changing the line on;
/etc/apache2/ports.conf
Code:
Listen 80 Listen 40
to
Code:
Listen 80
Listen 44
They must be in 2 lines.


Shall I make any change on your suggestion?
Quote:
Please change
Code:
<IfModule prefork.c>
StartServers         5
MinSpareServers      5
MaxSpareServers     10
MaxClients          20
MaxRequestsPerChild  0
</IfModule>
to
Code:
<IfModule prefork.c>
StartServers         5
MinSpareServers      5
MaxSpareServers     10
MaxClients          20
MaxRequestsPerChild  10000
</IfModule>
and restart Apache.
[/quote]

Tks.

B.R.
satimis
Reply With Quote
  #10  
Old 13th November 2006, 15:54
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,741 Times in 2,575 Posts
 
Default

Quote:
Originally Posted by satimis
Shall I make any change on your suggestion?
No, if it's working it's ok.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
sending e-mail using mail() function linuxuser1 HOWTO-Related Questions 38 21st April 2009 12:20
Problem with Apache 2 + ISP Config Ally Installation/Configuration 1 10th June 2006 20:34
PHP problem ..Just installed ISP Config malikp Installation/Configuration 5 10th April 2006 11:43
Problem with the apache (I can't start ist) M.Behrens Installation/Configuration 11 31st March 2006 10:48
DNS Config Problem bolinux Installation/Configuration 27 20th August 2005 16:12


All times are GMT +2. The time now is 11:45.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.