The optimal MPM for your server depends on multiple factors. We recommend the MPM Prefork or the MPM ITK for most circumstances.
The MPM Event serves a single HTTP request across multiple threads. However, the MPM Event uses a dedication system and dedicates a thread to handle all live connections. The system allocates a request to the child threads only when it receives a request. This allows the threads instant availability after the request finishes.
We recommend this MPM for users that only make occasional concurrent requests, or when a user requires a long keep-alive timeout. For more information, read the Apache MPM event documentation.
The MPM Worker causes Apache to fork into several processes so that a single crash does not kill the entire Apache process. Each forked process creates numerous threads, and a listener thread that listens for connections. This enables the system to serve multiple requests concurrently. For more information, read the Apache MPM worker documentation.
EasyApache selects the MPM Prefork by default. Unless you use the CloudLinux™ operating system, we recommend that you use this MPM for stability.
The MPM Prefork causes Apache to branch (fork) into additional processes before the system receives requests. When the server receives requests, it responds quickly to each request because an Apache process already exists to handle the request. If a problem occurs with an individual process, the system can kill the process with no effect on the other Apache processes. For more information, read the Apache MPM prefork documentation.
If you use the CloudLinux operating system, we recommend that you select the MPM ITK option in EasyApache.
The MPM ITK causes Apache to branch (fork) into additional processes before requests are made. When an Apache process responds to a request, it switches to the UID and GID of the Virtualhost that owns the request. This protects each Virtualhost's scripts and configuration files from files on other Virtualhosts.
- We introduced the MPM ITK option and the MPM ITK profile to servers that use Apache version 2.2 in the following versions:
- cPanel & WHM version 18.104.22.168
- cPanel & WHM version 22.214.171.124
- cPanel & WHM version 126.96.36.199
- All builds of cPanel & WHM version 11.46
- If you wish to use ModSecurity with the MPM ITK and CloudLinux, either enable or uninstall CageFS before you run EasyApache with ModSecurity and the MPM ITK.
- If you select the MPM ITK option, EasyApache will disable the following options:
- Mod Mono (.Net 1.x)
- Mod Mono (.Net 2.x)
- Tomcat 7.0
- Mod Ruid2
- Mod suPHP
- If you select the MPM ITK option in the Short Options List stage of the EasyApache 3 interface, cPanel & WHM selects CGI as your PHP handler.
- EasyApache will also disable the Apache suEXEC option. To use suEXEC in a future Apache configuration, you must perform the following steps:
- Disable the MPM ITK option in the Exhaustive Options List stage of the EasyApache 3 interface.
- Enable the Apache suEXEC option in WHM's Configure PHP and suEXEC interface (Home >> Service Configuration).
The MPM ITK option is not compatible with the following features:
- If you select the MPM ITK option, we strongly recomend that you remove the MPM Options feature from your users' feature lists. Use WHM's Feature Manager interface (Home >> Packages >> Feature Manager) to change your users' feature lists.
Select an MPM
Due to the differences between each MPM, some MPMs work better on specific systems than others. For example, we recommend that you use the MPM Prefork if you use older software that requires stability and compatibility. For websites that require more diversity and scalability, we recommend that you use the MPM Worker or MPM Event. For websites that run the CloudLinux™ operating system, we recommend that you use the MPM ITK.
Because each system possesses different requirements, use the following information to determine which MPM to choose for your system.
- If your system requires threads and allows for safe thread-polling, use the MPM Event.
- If your system requires threads, but does not allow for safe thread-polling, use the MPM Worker.
- If your system does not require threads and does not allow for safe thread-polling, use the MPM Prefork.