Skip to main content

Why does MPM prefork faster than any other MPM?

Comments

5 comments

  • cPanelMichael
    Hello, It's possible that MPM Prefork is better at handling the type of requests your system receives. You can find documentation on how each MPM works at: Multi-Processing Modules - MPMs - EasyApache 4 - cPanel Documentation Thank you.
    0
  • Pankaj K
    yes I have also found MPM prefork working better for most of the servers pretty well. Recently we faced issue on one server where MPM was set to worker and apache was hanging with the message scoreboard is not full. We have switched it to MPM prefork and server started performing well.
    0
  • ssfred
    Hello Pankaj, I think the performance highly depends on your requirements and resource availability. Prefork is an excellent option if you have better RAM. But when it comes to servers with relatively lower RAM, Worker and event appear to out perform prefork. Glad to know that switching to prefork helped you in getting the desired output :)
    0
  • kiti
    For your information, my issue with MPM prefork was related to wordpress. For some reasons, the Mariadb transactions are slower using Prefork rather than worker with Wordpress. I used other CMS or coded myself PHP to mariadb and saw that prefork was great. . For sure, in apache, i have tuned my MPM prefork to always have the maximum
    0
  • vacancy
    Prefork is a more stable mpm. But both memory and CPU have their disadvantages. Not efficient in process management. Separate processing for each request is causing high resource consumption. Mpm event is more efficient in resource usage. But in some cases it is not as stable as prefork. I'm testing mpm event + php-fpm. I did not have a big problem, everything is fine.
    0

Please sign in to leave a comment.