changing Apache

PSD

Verified User
Joined
Apr 12, 2013
Messages
24
Hi can anyone advise me here
I wanted to downgrade Apache/2.4.27 To Apache:2.4.16

I used this code:
cd /usr/local/directadmin/custombuild
echo "apache:2.4.16:" > custom_versions.txt
./build apache

I can see in custom_versions.txt

[root@svr1 custombuild]# cat custom_versions.txt
apache:2.4.16:

but checking httpd -v showing Apache/2.4.27 ???

[root@svr1 ~]# /usr/sbin/httpd -v
Server version: Apache/2.4.27 (Unix)
Server built: Oct 5 2017 01:50:41

even under sys info DA showing Apache 2.4.27 Running

have i missed somthing?? should i have run..

cd /usr/local/directadmin/custombuild
./build apache
./build php n
./build rewrite_confs

any help thanks PSD
 
Hi, the correct commands should be:

cd /usr/local/directadmin/custombuild
echo "apache2.4:2.4.16:" > custom_versions.txt
./build apache
./build php n
./build rewrite_confs
 
Hi thanks for the quick reply

I have already run
echo "apache:2.4.16:" > custom_versions.txt
./build apache

should i continue with
./build php n
./build rewrite_confs

or start over

echo "apache2.4:2.4.16:" > custom_versions.txt
./build apache
./build php n
./build rewrite_confs

thanks....Anyone...with a reply...
 
Last edited:
hi thanks for reply

Installing configuration files
[PRESERVING EXISTING HTDOCS SUBDIR: /var/www/htdocs]
[PRESERVING EXISTING ERROR SUBDIR: /var/www/error]
[PRESERVING EXISTING ICONS SUBDIR: /var/www/icons]
[PRESERVING EXISTING CGI SUBDIR: /var/www/cgi-bin]
Installing header files
Installing build system files
Installing man pages and online manual
make[1]: Leaving directory `/usr/local/directadmin/custombuild/httpd-2.4.27'
Restoring certificate and key, and turning on httpd for DirectAdmins's check.
Checking to ensure /etc/httpd/conf/ssl.crt/server.ca is set.
Enabling httpd in systemd...
Checking to ensure /etc/httpd/conf/ssl.crt/server.ca is set.
Using 1xxx.233.xxxx.130 for your server IP
Restarting apache.
Job for httpd.service invalid.
 
Last edited:
You still install httpd-2.4.27. What's your output for:


Code:
cd /usr/local/directadmin/custombuild/
cat custom_versions.txt

Code:
./build versions | grep -i apache

Code:
./build version
 
Thanks Alex for reply....

Code:
cd /usr/local/directadmin/custombuild/
cat custom_versions.txt

[root@svr1 custombuild]# cat custom_versions.txt
apache:2.4.16:


Code:
./build versions | grep -i apache

[root@svr1 custombuild]# ./build versions | grep -i apache

Latest version of Apache: 2.4.27
Installed version of Apache: 2.4.27

Code:
./build version

[root@svr1 custombuild]# ./build version
2.0.0 (rev: 1733)

Phil
 
That should be

Code:
[B]apache2.4[/B]:2.4.16:

in custom_versions.txt

Then rebuild apache.

Code:
./build apache
./build php n
./build rewrite_confs
 
chaned to
apache2.4:2.4.16:


run
./build apache

make[1]: Leaving directory `/usr/local/directadmin/custombuild/httpd-2.4.16'
Restoring certificate and key, and turning on httpd for DirectAdmins's check.
Checking to ensure /etc/httpd/conf/ssl.crt/server.ca is set.
Enabling httpd in systemd...
AH00526: Syntax error on line 1 of /etc/httpd/conf/extra/httpd-phpmodules.conf:
Invalid command 'ProtocolsHonorOrder', perhaps misspelled or defined by a module not included in the server configuration



****
AH00526: Syntax error on line 1 of /etc/httpd/conf/extra/httpd-phpmodules.conf:
Invalid command 'ProtocolsHonorOrder', perhaps misspelled or defined by a module not included in the server configuration
****
/etc/systemd/system/httpd.service has NOT been installed because of no HAVE_SYSTEMD in the otuput!!
****

Checking to ensure /etc/httpd/conf/ssl.crt/server.ca is set.
Using 1xx.2xx.232.1xx for your server IP
Restarting apache.
Job for httpd.service failed because the control process exited with error code. See "systemctl status httpd.service" and "journalctl -xe" for details.
[root@svr1 custombuild]# systemctl status httpd.service
● httpd.service - The Apache HTTP Server
Loaded: loaded (/etc/systemd/system/httpd.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Fri 2017-10-06 12:52:06 BST; 8s ago
Process: 24182 ExecStop=/bin/kill -WINCH ${MAINPID} (code=exited, status=1/FAILURE)
Process: 24180 ExecStart=/usr/sbin/httpd $OPTIONS -DFOREGROUND (code=exited, status=1/FAILURE)
Main PID: 24180 (code=exited, status=1/FAILURE)

Oct 06 12:52:06 svr1.web.com systemd[1]: Starting The Apache HTTP Server...
Oct 06 12:52:06 svr1.web.com httpd[24180]: AH00526: Syntax error on line 1 of /etc/httpd/conf/extra/httpd-phpm...conf:
Oct 06 12:52:06 svr1.web.com httpd[24180]: Invalid command 'ProtocolsHonorOrder', perhaps misspelled or define...ation
Oct 06 12:52:06 svr1.web.com systemd[1]: httpd.service: main process exited, code=exited, status=1/FAILURE
Oct 06 12:52:06 svr1.web.com kill[24182]: kill: cannot find process ""
Oct 06 12:52:06 svr1.web.com systemd[1]: httpd.service: control process exited, code=exited status=1
Oct 06 12:52:06 svr1.web.com systemd[1]: Failed to start The Apache HTTP Server.
Oct 06 12:52:06 svr1.web.com systemd[1]: Unit httpd.service entered failed state.
Oct 06 12:52:06 svr1.web.com systemd[1]: httpd.service failed.



output
/etc/httpd/conf/extra/httpd-phpmodules.conf

ProtocolsHonorOrder On
Protocols h2 h2c http/1.1
LoadModule systemd_module /usr/lib/apache/mod_systemd.so
LoadModule mpm_event_module /usr/lib/apache/mod_mpm_event.so

Now apache Stopped Phil
 
OK, that's the issue. In this case you'd better install the actual Apache version. Or at lease you could try and comment the line:

Code:
ProtocolsHonorOrder

in /etc/httpd/conf/extra/httpd-phpmodules.conf. Or change the PHP mode to different from the current.

I don't guarantee that it does not break anything.

I'd rather say that you need somebody to fix it for you, as there might other errors occur. The forums is not a live chat and I won't guide you on the matter in a real time manner at these hours.
 
sorry alex i did not mean to double post, just got in a panic anyhow

I removed
cd /usr/local/directadmin/custombuild
rm -i custom_versions.txt

and ./build apache its back on now.... thank you...ill look on another path for the old site.
 
after the HDD crash datacentre installed new drive with centos7 lastest updates, one site won't run it comes up with:
Unable to resize photos. Please check file/folder permissions. and dosent load

the old working config for this site was
CONFIG OLD DRIVE
Apache 2.2.31
DirectAdmin 1.51.4
Exim 4.77
MySQL 5.1.65
Named 9.9.5
ProFTPd 1.3.3c
dovecot 2.2.26.0
Php 5.3.29
CentOS 5.11 64-bit
with mod_ruid2

I didnt know you can run mod_ruid2 should with PHP-FPM, just found post
http://forum.directadmin.com/showthread.php?t=55086&highlight=mod_ruid2+with+php-fpm

this may solve ??? thanks again alex...
 
If you run Apache with mod_php then you need to enable mod_ruid2 in order to solve the issue with permissions.
 
Back
Top