Skip to Content
Technical Articles

SAP APACHE Upgrade from V2.2 to V2.4 on Linux

Hello All,

This blog will detail out the required steps to upgrade Apache version on Linux box..


In general Apache is used to reduce the load on a SAP Web application server where you can set a separate, dedicated web server to serve static content. All static content will be served by the web server, while dynamic content will be served by the web application server.

In our SAP landscape Apache is used so that the Network will be protected using a dual layer reverse proxy approach.  This will incorporate an Apache reverse proxy with a network DMZ and SAP Web dispatcher,  which will function as a combination of reverse proxy and load balancer for SAP.





  1. First ask OS team to “Enable Red Hat Software Collections repository on servers”. This is required to enable available software on Red Hat site so that software can be directly used from site to install.

2. After that Check Current Apache Version(run with root user or your User ID must be having root user access):-

Goto /usr/sbin directory

Run ./httpd -v


1.Create Required Directories and sub directories

Create /apachejail on root path

Create subdirectories




give full permission to directories and sub directories. Also maintain hosts file in etc directory.


2.Check available HTTPD executables on server

rpm -qa | grep httpd


3.Take full backup of running/current Apache Directory

3.1 Stop running apache services on server.

3.2 Create backup directory with full permission.

3.3 Copy current apache directory with current permission in the backup directory.

4.Uninstall Current/old Apache release

stop Apache services

# service httpd stop

yum erase httpd*        (run from root directory)

Installed size: 18 M

Is this ok [y/N]: y


  1. Manually Remove/rename old httpd directory
  2. Reboot server

7.Install New Apache version on server

#yum install -y -q httpd24-httpd (for force install it will not ask whether we need to install or not)


#yum install httpd24-httpd (It will ask whether we need to continue to install or not)


#service httpd24-httpd start


#service httpd24-httpd stop


#yum install httpd24-mod_ssl


#yum install httpd24-mod_proxy_html

8. Backup of New config file.

Take backup of newly created httpd.conf file


8.1. Configure httpd.conf file

Customize the httpd.conf file as per customer changes (use httpd.conf file kept in backup from old version and make necessary changes)

Maintain below details in httpd.conf file:-

ChrootDir /apachejail


ServerName “<full server name (include FQDN if maintained)>”
ServerTokens “<type of server(Dev,QA,Prod)>”
ServerSignature “Off”
ServerRoot “/opt/rh/httpd24/root/etc/httpd” (newly created apache directory path)


Include conf.modules.d/*.conf
LoadModule headers_module modules/


User <Apache User ID>

Group <Apache Group ID>


also maintain other details like:-

# DocumentRoot: The directory out of which you will serve your documents.

# ErrorLog: The location of the error log file.

# LogLevel: Control the number of messages logged to the error_log.

# Customizable error responses

# Access Control Admin Page

# Access Control Admins Page

# Blacklist via Request Method

# Blacklist vie Request

# Blacklist via HTTP REFERRER

# Blacklist via Cookies

# Blacklist via Request URI

# Blacklist via Query String

# Virtual Host Block for  Fiori

#Virtual host block for EREC



******all above mentioned changes needs to be done comparing from old version httpd.conf file*******


Copy required files from old apache backup directory to new apache directory like the certificates if any, ssl.conf , userdir.conf , passphrase, conf modules from directory old conf.modules.d to newly created conf.modules.d , that contains the customization of the customer and make necessary changes in the newly created files or new version.


conf.d (directory)


9. Restart Apache after making necessary changes to check the configuration is successfully changed in new files.

# service httpd24-httpd start

Make corrections in module files


10. Correct the modules file and # out the irrelevant modules (Check from old version backup file)

Goto directory and make required changes



conf.modules.d (directory)

11. Restart Apache system and check the required directories.

Restart Apache

Check folders of PID(process ID) for httpd services should be created in /proc directory


And check

value for “cwd” should be pointing to “/apachejail”


value for “root” should be pointing to “/apachejail”


value for “exe” should be pointing to “/opt/rh/httpd24/root/usr/sbin/httpd”


Check version


12. Check the Customer/Internet links are working fine as per new version configuration. Check all the URL should be tested by customer without any issue.


13. Standard References:-



You must be Logged on to comment or reply to a post.