Apache Going down frequently [ HELP Needed ]

geek4ever

Member
Sep 23, 2011
9
0
51
cPanel Access Level
Website Owner
HI ,

Straight to the point , apache going down every few hours and i need to restart it from cpanel ( restart services ) so it starts again

here's the apache error log :

/usr/local/apache/logs/error_log

[Sun Apr 22 13:22:32 2012] [notice] Graceful restart requested, doing restart
[Sun Apr 22 13:22:33 2012] [notice] seg fault or similar nasty error detected in the parent process

[Sun Apr 22 02:00:56 2012] [notice] Graceful restart requested, doing restart
[Sun Apr 22 02:00:56 2012] [error] (9)Bad file descriptor: apr_socket_accept: (client socket)
[Sun Apr 22 02:00:57 2012] [notice] seg fault or similar nasty error detected in the parent process
[Sun Apr 22 02:28:17 2012] [notice] suEXEC mechanism enabled (wrapper: /usr/local/apache/bin/suexec)
[Sun Apr 22 02:28:17 2012] [notice] ModSecurity for Apache/2.6.3 (ModSecurity: Open Source Web Application Firewall) configured.
[Sun Apr 22 02:28:17 2012] [notice] ModSecurity: APR compiled version="1.4.5"; loaded version="1.4.5"
[Sun Apr 22 02:28:17 2012] [notice] ModSecurity: PCRE compiled version="8.21"; loaded version="8.21 2011-12-12"
[Sun Apr 22 02:28:17 2012] [notice] ModSecurity: LUA compiled version="Lua 5.1"
[Sun Apr 22 02:28:17 2012] [notice] ModSecurity: LIBXML compiled version="2.7.8"

i rebuild apache and updated cpanel and the problem remains , can someone please tell me what i have to do or what does these errors mean i really appreciate any help .
 

thewebhosting

Well-Known Member
May 9, 2008
1,199
1
68
[error] (9)Bad file descriptor: apr_socket_accept: (client socket)

Do you still receive above error while stop/start apache manually from command prompt?
 

NetMantis

BANNED
Apr 22, 2012
116
1
66
Utah
cPanel Access Level
DataCenter Provider
There is more possibilities here than could be listed with the little information at hand.

To properly diagnose your issue, we'd really need to know:

1. The amount of memory and traffic on your server
2. The details of your Apache configuration

Per the former, if your server has insufficient resources that would definitely cause a crash condition.

Per the latter, an incorrect configuration, over allocation of resources, or even mis-configured or mismatched modules could also contribute to the server crashing as well.

If I saw your server's configuration, I could probably tell you in a heartbeat what is wrong but with the little bit of
log information you posted above, I really couldn't say exactly what is happening here.
 

thewebhosting

Well-Known Member
May 9, 2008
1,199
1
68
To see the usage of apache processes run following command from SSH:

top -c

See which process is consuming more Apache resource.
 

geek4ever

Member
Sep 23, 2011
9
0
51
cPanel Access Level
Website Owner
There is more possibilities here than could be listed with the little information at hand.

To properly diagnose your issue, we'd really need to know:

1. The amount of memory and traffic on your server
2. The details of your Apache configuration

Per the former, if your server has insufficient resources that would definitely cause a crash condition.

Per the latter, an incorrect configuration, over allocation of resources, or even mis-configured or mismatched modules could also contribute to the server crashing as well.

If I saw your server's configuration, I could probably tell you in a heartbeat what is wrong but with the little bit of
log information you posted above, I really couldn't say exactly what is happening here.
Thanks for your reply and everyone reply .

Here's some information might help :
Code:
[email protected] [~]# httpd -v
Server version: Apache/2.2.22 (Unix)
Server built:   Apr 21 2012 20:18:19
Cpanel::Easy::Apache v3.11.2 rev9999
Code:
[email protected]  [~]# php -v
PHP 5.2.17 (cli) (built: Apr 21 2012 20:22:51)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies
    with eAccelerator v0.9.6.1, Copyright (c) 2004-2010 eAccelerator, by eAccelerator
    with the ionCube PHP Loader v4.0.12, Copyright (c) 2002-2011, by ionCube Ltd., and
    with Zend Optimizer v3.3.9, Copyright (c) 1998-2009, by Zend Technologies
    with Suhosin v0.9.32.1, Copyright (c) 2007-2010, by SektionEins GmbH
Code:
[email protected] [~]# cat /etc/redhat-release
CentOS release 5.8 (Final)
Code:
[email protected] [~]# /usr/local/cpanel/cpanel -V
11.32.2 (build 18)
i Don't have a lot of visitors nearly 20 visitor per day & my server is a vps with 1 gb ram and there is no dos attacks

1- Load Averages: 0.10 0.03 0.01

2- Apache configuration i ll put the modules loaded with apache hope it helps and if you need something else let me know :

Code:
Loaded Modules: core_module (static) 
authn_file_module (static) 
authn_default_module (static)
authz_host_module (static) 
authz_groupfile_module (static) 
authz_user_module (static) 
authz_default_module (static)
auth_basic_module (static) 
file_cache_module (static) 
cache_module (static) 
mem_cache_module (static)
include_module (static) 
filter_module (static) 
deflate_module (static) 
log_config_module (static) 
logio_module(static)
env_module (static)
expires_module (static)
headers_module (static) 
unique_id_module (static) 
setenvif_module (static) 
version_module (static) 
proxy_module (static)
proxy_connect_module (static)
proxy_ftp_module (static) 
proxy_http_module (static) 
proxy_scgi_module (static) 
proxy_ajp_module (static) 
proxy_balancer_module (static)
ssl_module (static) 
mpm_prefork_module (static) 
http_module (static)
mime_module(static)
status_module (static) 
autoindex_module (static) 
asis_module (static)
info_module (static) 
suexec_module (static) 
cgi_module (static)
negotiation_module (static) 
dir_module (static) 
actions_module (static) 
userdir_module (static) 
alias_module (static) 
rewrite_module (static) 
so_module (static) 
perl_module(shared) 
bwlimited_module (shared) 
php5_module (shared) 
security2_module (shared) 
Syntax OK
 

geek4ever

Member
Sep 23, 2011
9
0
51
cPanel Access Level
Website Owner

geek4ever

Member
Sep 23, 2011
9
0
51
cPanel Access Level
Website Owner