Bug 1366541

Summary: RPM: RHEL6: httpd service is not starting, LD_LIBRARY_PATH needs to be set
Product: [JBoss] JBoss Enterprise Web Server 2 Reporter: fgoldefu
Component: httpdAssignee: Coty Sutherland <csutherl>
Status: CLOSED NOTABUG QA Contact: Jan Onderka <jonderka>
Severity: urgent Docs Contact:
Priority: urgent    
Version: 2.1.1CC: info, jclere, jdoyle, mbabacek, pdegave, pragshar, pslavice, rsvoboda
Target Milestone: CR01Keywords: Reopened
Target Release: 2.1.1   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-11-30 14:58:35 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description fgoldefu 2016-08-12 09:34:22 UTC
Description of problem:
The httpd did not start with default configuration. The LD_LIBRARY PATH have to be set i.e. in /etc/init.d/httpd
export LD_LIBRARY_PATH=/opt/rh/jbcs-httpd24/root/usr/lib64/
or 
export LD_LIBRARY_PATH=/opt/rh/jbcs-httpd24/root/usr/lib/
has to be set.

After installation this error occurs:
# service httpd start
Starting httpd: httpd: Syntax error on line 217 of /etc/httpd/conf/httpd.conf: Syntax error on line 12 of /etc/httpd/conf.d/ssl.conf: Cannot load /etc/httpd/modules/mod_ssl.so into server: /usr/lib/libcrypto.so.10: version `OPENSSL_1.0.2' not found (required by /etc/httpd/modules/mod_ssl.so)
[FAILED]


Version-Release number of selected component (if applicable):
RHEL6

How reproducible:
Everytime.

Steps to Reproduce:
1. Execute service httpd start.

Actual results:
Httpd server did not start.

Expected results:
Httpd server will start.

Comment 1 George Zaronikas 2016-08-12 12:58:06 UTC
LD_LIBRARY_PATH env added to init script

Comment 2 fgoldefu 2016-08-16 11:47:51 UTC
The RHEL7 x64 and RHEL6 x64 is fixed, but the patch did not work for RHEL6 i386,
because

export LD_LIBRARY_PATH=/opt/rh/jbcs-httpd24/root/usr/lib64

is not valid for 32bit RHEL.

Comment 5 errata-xmlrpc 2016-08-22 18:12:03 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHSA-2016-1649.html

Comment 11 Sebastian Stelmasik 2016-12-15 14:02:50 UTC
LD_LIBRARY_PATH env should also be added to apachectl script - in the current version it has the same issue as the httpd service ini script before patching.
Including the same LD_LIBRARY_PATH export from the httpd init script into apachctl fixes the issue:

test -d /opt/rh/jbcs-httpd24/root/usr/lib64 &&
    export LD_LIBRARY_PATH=/opt/rh/jbcs-httpd24/root/usr/lib64 ||
    export LD_LIBRARY_PATH=/opt/rh/jbcs-httpd24/root/usr/lib



Version-Release number of selected component (if applicable):
RHEL6

How reproducible:
Everytime.

Steps to Reproduce:
1. Execute: apachectl -t

Actual results:
apachectl will not check httpd configuration when mod_ssl is enabled - it shows the following error:

httpd: Syntax error on line 226 of /etc/httpd/conf/httpd.conf: Syntax error on line 12 of /etc/httpd/conf.d/ssl.conf: Cannot load /etc/httpd/modules/mod_ssl.so into server: /usr/lib64/libcrypto.so.10: version `OPENSSL_1.0.2' not found (required by /etc/httpd/modules/mod_ssl.so)

Expected results:
apachectl will check httpd configuration and show results