SOLVED Apache failing after EasyApache update

nyjimbo

Well-Known Member
Jan 25, 2003
1,135
1
168
New York
UPCP ran last night and after it could not start apache:

The service “httpd” appears to be down.

Code:
Server xxxxxxx.com
Primary IP Address xxxxxxxxxx
Service Name httpd
Service Status failed 
Notification The service “httpd” appears to be down.
Service Check Method The system failed to connect to this service’s TCP/IP port.
Reason Service check failed to complete
Unable to connect to port 80 on 127.0.0.1: Connection refused: Died
Number of Restart Attempts 49
Startup Log /usr/sbin/httpd: symbol lookup error: /usr/sbin/httpd: undefined symbol: apr_bucket_alloc_aligned_floor
Log Messages [Tue Apr 03 22:54:35.759371 2018] [mpm_prefork:notice] [pid 12717] AH00163: Apache/2.4.29 (cPanel) OpenSSL/1.0.2n mod_bwlimited/1.4 configured -- resuming normal operations
So I manually ran it and upgrade to v70.0.26 from .23. That did not fix it.

I then ran easyapache, using the existing profile.

Apache is now up, but php is displayed as raw code and not processed and displayed as normal.

Anyone know what is going on ?
 
Last edited by a moderator:

vacancy

Well-Known Member
Sep 20, 2012
556
223
93
Turkey
cPanel Access Level
Root Administrator
I see the same error on my 2 servers.

I went back to easyapache 3 to solve the problem.

yum -y upgrade I did not solve the problem.
 
Last edited:

John Galvin

Member
Apr 4, 2018
6
0
1
Hungary
cPanel Access Level
Root Administrator
After last nights Easy Apache update, httpd is failing with the error:
Starting httpd: /usr/sbin/httpd: symbol lookup error: /usr/sbin/httpd: undefined symbol: apr_allocator_align

Originally I had an error that libapr-1.so.0 couldn't be found in /lib64/libapr-1.so.0, so I created a symlink from there to /opt/cpanel/ea-apr15/lib64 where it's located, but now I can't past the above error.

Anyone encountered this or know how to resolve it?
 

tim_proc

Registered
Apr 4, 2018
1
0
1
Lisburn, Northern Ireland
cPanel Access Level
Root Administrator
Just a quick note to say we ran into the same issue.

Ended up re-provisioning with Easy Apache 4 using the same profile.... as per the first message we seen raw PHP code being rendered.

This was solved by resetting the PHP handlers again (for all versions) to suPHP in our case.

A bit more long-winded than @Raedo's solution but worked for us.


We're a bit pissed that we can't control this auto-update process though tbh.
 

OttoM

Member
Apr 4, 2018
19
4
3
UK
cPanel Access Level
Root Administrator
Hello,

The httpd has been down on my server since 1.30am.

I can ssh and run the command to start it.
service httpd start

But getting these error messages:
Code:
Apr 04 12:25:16 vps.online-example.com systemd[1]: Starting Apache web server managed by cPanel EasyApache...
    Apr 04 12:25:16 vps.online-example.com restartsrv_httpd[3627]: /usr/sbin/httpd: symbol lookup error: /usr/sbin/httpd: undefined symbol: apr_stat_fd
    Apr 04 12:25:16 vps.online-example.com systemd[1]: httpd.service: control process exited, code=exited status=127
    Apr 04 12:25:16 vps.online-example.com systemd[1]: Failed to start Apache web server managed by cPanel EasyApache.
    Apr 04 12:25:16 vps.online-example.com systemd[1]: Unit httpd.service entered failed state.
    Apr 04 12:25:16 vps.online-example.com systemd[1]: httpd.service failed.
I have already installed package apr and apr-util.

Not sure what else to do really. Any help is much appreciated.
 
Last edited by a moderator:

nyjimbo

Well-Known Member
Jan 25, 2003
1,135
1
168
New York
Run "yum -y update". I had the same problem, ran yum again and it resolved the problem for me. Looks like Apache was compiled yesterday and then again today.
did you run yum to fix the not starting issue or the php issue ?
 

nyjimbo

Well-Known Member
Jan 25, 2003
1,135
1
168
New York
as per the first message we seen raw PHP code being rendered.

This was solved by resetting the PHP handlers again (for all versions) to suPHP in our case.
where is this done ?
 

SageBrian

Well-Known Member
Jun 1, 2002
413
2
318
NY/CT (US)
cPanel Access Level
Root Administrator
Run "yum -y update". I had the same problem, ran yum again and it resolved the problem for me. Looks like Apache was compiled yesterday and then again today.
Yup, that fixed it for me.
 

OttoM

Member
Apr 4, 2018
19
4
3
UK
cPanel Access Level
Root Administrator
This did not fix my problem. I run yum -y update twice and re-provisioning with Easy Apache 4.
I have no php handlers so it is left as none.

When I restarted apache it gives me the following message:

Code:
/usr/sbin/httpd: symbol lookup error: /usr/sbin/httpd: undefined symbol: apr_stat_fd
 

cPanelNick

Administrator
Staff member
Mar 9, 2015
3,481
35
208
cPanel Access Level
DataCenter Provider
Please open a ticket through WHM or at cPanel Customer Portal and hit the emergency button once the ticket is open.

Code:
/usr/sbin/httpd: symbol lookup error: /usr/sbin/httpd: undefined symbol: apr_stat_fd
Alternatively, you could also try:
  1. Code:
    yum clean all
    yum -y update
  2. Reprovision php handlers in WHM (if needed) under
    Code:
    Home »
    Software »
    MultiPHP Manager »
    PHP Handlers (tab)
Do you by chance have these settings in your /etc/cpupdate.conf?
  1. System packages updates disabled (RPMUP=never)
  2. cPanel updates enabled (CPANEL=..anything except never..)
 
Last edited:

OttoM

Member
Apr 4, 2018
19
4
3
UK
cPanel Access Level
Root Administrator
This is what I have in /etc/cpupdate.conf by the way.

Code:
CPANEL=release
RPMUP=daily
SARULESUP=daily
STAGING_DIR=/usr/local/cpanel
UPDATES=daily
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
Hello Everyone,

Allow me to offer some background information on this topic. An updated ea-apache24 RPM was published yesterday. It was considered a required update and thus automatically installed by the /usr/local/cpanel/scripts/sysup script that runs during the nightly cPanel update process. When an update to an RPM is required, the following settings will not prevent the automatic update from occurring:

  • The RPMUP variable set to never in the /etc/cpupdate.conf file.
  • The Operating System Package set to Never Update in WHM's Update Preferences interface (WHM >> Home >> Server Configuration >> Update Preferences).
In this particular case, we forced an update to the ea-apache24 RPM, but didn't force an update to one of the required dependencies (ea-apr-util). Thus, systems with "Operating System Package Updates" set to "Never" in "WHM >> Update Preferences" failed to receive a required update to the ea-apr-util RPM. We've now fixed this as part of internal case EA-7366, so try running the following command to receive the updated RPM if Apache is down on your system:

Code:
/usr/local/cpanel/scripts/sysup
Additionally, it's possible that systems affected by this issue no longer have PHP handlers configured for the versions of PHP installed on the system. To solve that issue, check to see if any of the enabled PHP versions on the system are set to "None" as the PHP handler:

Code:
 /usr/local/cpanel/bin/rebuild_phpconf --current
If any versions are set to "None", browse to "WHM >> MultiPHP Manager" and configure the correct handler for each version.

If you were using DSO as the PHP handler for one of the PHP versions on your system, you can verify which version it was enabled for by running a command like this:

Code:
rpm -qa | grep -i ea-php[0-9][0-9]-php-[0-9]
If you see an RPM in the output of that command, it means the DSO RPM was installed for that version of PHP. If that's the case, try running the following command:

Code:
yum reinstall ea-apache24
Once the RPM is reinstalled, browse back to "WHM >> MultiPHP Manager" to see if you can then update the PHP handlers.


To update, we've published an autofixer to repair the missing PHP handlers that resulted from the issue noted with internal case EA-7366. This should run automatically upon the nightly cPanel update, but you can also run it manually using the following command:

Code:
/usr/local/cpanel/scripts/autorepair resolve_all_php_handlers_being_none
Thank you.
 
  • Like
Reactions: cPLevey and vacancy

John Galvin

Member
Apr 4, 2018
6
0
1
Hungary
cPanel Access Level
Root Administrator
I have this issue, but my 'Operating System Package Updates' settings were set to automatic and I can't change the php handler type in WHM, it's stuck at 'None'.

Any other suggestions?
 

Oxy Hospedagem

Registered
Apr 4, 2018
1
1
3
Brazil
cPanel Access Level
Website Owner
Hello,

Internal case EA-7366 is open to address an issue where systems with "Operating System Package Updates" set to "Never" in "WHM >> Update Preferences" failed to receive a required update to the ea-apr-util RPM during the most recent EasyApache 4 update. I'll update this thread as soon as the resolution is published.

In the meantime, please take the following steps as a temporary workaround:

1. Update to the most recent RPMs available:

Code:
yum clean all
yum update ea-*
2. Check to see if any of the enabled PHP versions on the system are set to "None" as the PHP handler:

Code:
 /usr/local/cpanel/bin/rebuild_phpconf --current
3. If any versions are set to "None", browse to "WHM >> MultiPHP Manager" and configure the correct handler for each version.

Thank you.
worked for me,

Code:
 /usr/local/cpanel/bin/rebuild_phpconf --current
3. If any versions are set to "None", browse to "WHM >> MultiPHP Manager" and configure the correct handler for each version.

Thank you.[/QUOTE]

Was none I configured as suphp and everything is back
 
  • Like
Reactions: cPanelMichael

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
I have this issue, but my 'Operating System Package Updates' settings were set to automatic and I can't change the php handler type in WHM, it's stuck at 'None'.

Any other suggestions?
Hi John,

Do you happen to know if you were using DSO as the PHP handler for one of the PHP versions on your system? If you are unsure, you can verify that by running a command like this:

Code:
rpm -qa | grep -i ea-php[0-9][0-9]-php-[0-9]
If you see an RPM in the output of that command, it means the DSO RPM was installed for that version of PHP. If that's the case, try running the following command:

Code:
yum reinstall ea-apache24
Once the RPM is reinstalled, browse back to "WHM >> MultiPHP Manager" to see if you can then update the PHP handlers.

Thank you.