Change Apache Server MPM in RHEL 8

Apache on RHEL 8 uses events MPM. You can use apachectl -V command to see the current MPM used by Apache.

[[email protected] ~]# apachectl -V
Server version: Apache/2.4.37 (AlmaLinux)
Server built: Jan 25 2022 20:48:49
Server’s Module Magic Number: 20120211:83
Server loaded: APR 1.6.3, APR-UTIL 1.6.1
Compiled using: APR 1.6.3, APR-UTIL 1.6.1
Architecture: 64-bit
Server MPM: event
threaded: yes (fixed thread count)
forked: yes (variable process count)
Server compiled with….
-D APR_HAS_SENDFILE
-D APR_HAS_MMAP
-D APR_HAVE_IPV6 (IPv4-mapped addresses enabled)
-D APR_USE_SYSVSEM_SERIALIZE
-D APR_USE_PTHREAD_SERIALIZE
-D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
-D APR_HAS_OTHER_CHILD
-D AP_HAVE_RELIABLE_PIPED_LOGS
-D DYNAMIC_MODULE_LIMIT=256
-D HTTPD_ROOT=”/etc/httpd”
-D SUEXEC_BIN=”/usr/sbin/suexec”
-D DEFAULT_PIDLOG=”run/httpd.pid”
-D DEFAULT_SCOREBOARD=”logs/apache_runtime_status”
-D DEFAULT_ERRORLOG=”logs/error_log”
-D AP_TYPES_CONFIG_FILE=”conf/mime.types”
-D SERVER_CONFIG_FILE=”conf/httpd.conf”
[[email protected] ~]#

To modify Apache MPM, edit file

Apache MPM change in AlmaLinux 8

You can enable the PMP you want to use, comment out other MPM.

For example to enable Prefork, uncomment the line

and comment the following line

Once modified, restart Apache with

Veirfy Apache MPM changed to prefork with command

Need help with Linux Server or WordPress? We can help!

Leave a Reply

Your email address will not be published.