help Apache is functioning normally New accounts

Dr.DoctorT

New member
Joined
Mar 19, 2017
Messages
4
Greetings,
I'm new here and I have a problem I open new accounts once domain works never
That is done several times with fresh once it shows "Apache is functioning normally" and once it works!


Apache 2.4.23 Running
DirectAdmin 1.51.3 Running
Exim 4.87 Running
MySQL 5.5.31 Running
Named 9.8.2rc1 Running
sshd Running
dovecot 2.2.25 (7be1766) Running
pure-ftpd 1.0.42 Running
Php 5.6.25 Installed
 
We've been seeing a few reports of issues with the newer httpd binaries. I believe it started somewhere around apache 2.4.3+ where during a restart or reload, we're not exactly sure, the main httpd process doesn't actually quit, but the new process somehow manages to start a 2nd process.
When this happens you've got 2 master root httpd processes.. the old one is serving the old data (without a restart, hence "Apache is functioning normally"), but the new process does load the domain correctly, so you get the random result.

This only seems to happen on some boxes, seems to just be init.d, so mainly CentOS 6 (systemd is not affected).
We have updated our httpd_2 scripts, I believe we're at v2.6 of the /etc/init.d/httpd file, which you can find here:
Code:
wget -O /etc/init.d/httpd http://files.directadmin.com/services/custombuild/httpd_2

which is a symlink to the latest file, which right now is 2.6:
http://files.directadmin.com/services/custombuild/httpd_2-2.6

The change is basically to add extra code in the stop() function to ensure that all processes are actually stopped after the stop call, and if not, nuke whatever is left-over.

You can see if you've got a ghost copy of httpd running by typing:
Code:
ps axuf |grep /usr/sbin/httpd |grep -v grep | grep -c ^root
where we only want to ever see 1. If you see 2, then you've got a ghost of apache running and serving old data.
If that happens, ensure you have 2.6+ (check the top of the httpd boot script), and restart httpd.

The issue seems to be very random, and we're not 100% sure the trigger, as it cannot be reproduced on demand (but is likely one of restart, reload, seen on system that do not use graceful but not ruled out as also affected)

John
 
He's a sample output from a box I checked today (March 29th):
Code:
[root@server init.d]# ps axuf |grep /usr/sbin/httpd |grep -v grep | grep  ^root
[COLOR=#a52a2a]root      4758  0.0  0.0  61180  1712 ?        Ss   [B]Feb20[/B]   3:11 /usr/sbin/httpd[/COLOR]
[COLOR=#0000cd]root     20103  0.0  0.0  60888  6680 ?        Ss   00:50   0:00 /usr/sbin/httpd[/COLOR]
[root@server init.d]# /etc/init.d/httpd restart
Stopping httpd:                                            [COLOR=#00ff00][  OK  ][/COLOR]
[B]Found 1 leftover httpd processes. Killing.[/B]
                                                           [COLOR=#00ff00][  OK  ][/COLOR]
[root@server init.d]# ps axuf |grep /usr/sbin/httpd |grep -v grep | grep  ^root
[COLOR=#008000]root     26293  0.1  0.0  60888  6680 ?        Ss   03:05   0:00 /usr/sbin/httpd[/COLOR]
[root@server init.d]#
when the new script finds and kills the ghost httpd process.
 
We had 1 last Month.
Not sure about 100% the same issue.
CENTOS7 Custombuild2 latest.

We had to change before the gracefull restart in directadmin.conf in force restart so gracefull=0
Because of the problem with Apache update 2.4.25 and http2 not doing gracefull, ( https > http2 is not running after a gracefull restart this is probably another BUG )

But anyway that/last Month / 1 time the real httpd restart didn't work to so that was maybe the same problem ?

i am not sure but this didn't work for as i remember right.:
killall -9 httpd
service httpd start

For the http2 prob see http://forum.directadmin.com/showthread.php?t=54240
IF these/yourservers had also http2 maybe also with older apache version some (same kind) of bugs.?
Http2 here in the past with the Forumpost in DA forum also SMTALK did some service on our server because of a DA bug that then was noticed and later updated in DA custombuild itself problem then was restarting every... )


UHU JOHN you are working in the Future such Support is awsome. ;)
see 29...
He's a sample output from a box I checked today (March 29th):
 
Last edited:
Back
Top