Description of problem: There is a difference between setting httpd locale on RHEL 6 vs 7. On RHEL 7, this is done with the variable LANG in /opt/rh/httpd24/root/etc/sysconfig/httpd, whereas on RHEL 6 the variable HTTPD_LANG serves the same purpose. Yet by default, the said file contains on both RHEL versions the line 'LANG=C' which has little to no effect on RHEL 6 and should be replaced by HTTPD_LANG=C. To inspect the impact of both variables, edit the sysconfig file to contain these two following lines: LANG=ru_RU.utf-8 HTTPD_LANG=ja_JP.utf-8 Create file /opt/rh/httpd24/root/var/www/html/info.php with the following contents: --- <?php print "LANG=" . getenv('LANG') . "\n"; ?> --- Now start the httpd24-httpd service and check the PHP script's output. On RHEL 6, we get: # service httpd24-httpd start Запускается httpd: [ OK ] # curl http://localhost/info.php LANG=ja_JP.utf-8 What we see is that the init script itself runs with the 'LANG' locale (Russian in this case), but httpd process is executed with the 'HTTPD_LANG' locale (Japanese). This contradicts the claim in the sysconfig file that the default 'LANG=C' line 'ensures the httpd process is started in the "C" locale'. On RHEL 7, we get another result -- HTTPD_LANG is completely ignored and the 'LANG' locale is used with httpd processes: # service httpd24-httpd start Redirecting to /bin/systemctl start httpd24-httpd.service # curl http://localhost/info.php LANG=ru_RU.utf-8 Version-Release number of selected component (if applicable): httpd24-httpd-2.4.12-4.el6.x86_64
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://access.redhat.com/errata/RHBA-2016:1154