Results 1 to 14 of 14

Thread: New server w/ Apache 2.4. How to switch to event MPM?

  1. #1
    Join Date
    Dec 2005
    Posts
    103

    New server w/ Apache 2.4. How to switch to event MPM?

    I have a new installation with Apache 2.4 and Im assuming its running the prefork MPM by default.

    How do I switch apache to use the event MPM?

    Thanks!

  2. #2
    Join Date
    Aug 2006
    Location
    LT, EU
    Posts
    6,744
    Hello,

    For that you need to upgrade to CustomBuild 2.0. See: http://www.directadmin.com/forum/showthread.php?t=44454.

    Thank you.
    Martynas Bendorius
    MB Martynas IT. Professional server management company. Official DirectAdmin, CloudLinux, LiteSpeed and Comodo partners.

  3. #3
    Join Date
    Dec 2005
    Posts
    103
    Quote Originally Posted by smtalk View Post
    Hello,

    For that you need to upgrade to CustomBuild 2.0. See: http://www.directadmin.com/forum/showthread.php?t=44454.

    Thank you.
    I believe I am using CB 2.0 from the initial install?

  4. #4
    Join Date
    Dec 2005
    Posts
    103
    Anyone know how to do this?

    Thanks!

  5. #5
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    11,023
    Quote Originally Posted by darkus View Post
    Anyone know how to do this?

    Thanks!
    How to do what? To upgrade to CustomBuild 2.0? Or to switch Apache to use the event MPM?

    I guess both answers can be found by the link which was already given here by Martynas Bendorius. So upgrade CustomBuild to 2.0, and run

    Code:
    ./build apache
    once more time.
    With regards, Alex.

    Professional Server Management for web hosting companies and individuals
    Hourly Support, Disaster Recovery, Server Hardening, Monthly Subscription
    Directadmin installation and optimization

    Click here if you need a Linux Admin

  6. #6
    Join Date
    Dec 2005
    Posts
    103
    Quote Originally Posted by zEitEr View Post
    How to do what? To upgrade to CustomBuild 2.0? Or to switch Apache to use the event MPM?

    I guess both answers can be found by the link which was already given here by Martynas Bendorius. So upgrade CustomBuild to 2.0, and run

    Code:
    ./build apache
    once more time.
    I can upgrade to CB2.0, but Im a bit confused as how to switch to the event MPM. I dont see it discussed in that link?

    Thanks!

  7. #7
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    11,023
    See this

    What is new in CB 2.0? The main changes:
    ...
    ...
    Major change: event MPM is now used instead of the prefork one, if PHP-FPM is running
    ...
    ...
    http://www.directadmin.com/forum/sho...591#post228591

    Do you have more questions?
    With regards, Alex.

    Professional Server Management for web hosting companies and individuals
    Hourly Support, Disaster Recovery, Server Hardening, Monthly Subscription
    Directadmin installation and optimization

    Click here if you need a Linux Admin

  8. #8
    Join Date
    May 2006
    Posts
    46
    Quote Originally Posted by zEitEr View Post
    See this



    http://www.directadmin.com/forum/sho...591#post228591

    Do you have more questions?
    Do you have to use php-fpm to utilize Apache MPM?

  9. #9
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    11,023
    Do you have to use php-fpm to utilize Apache MPM?
    Why? I don't think that it's obligatory.
    With regards, Alex.

    Professional Server Management for web hosting companies and individuals
    Hourly Support, Disaster Recovery, Server Hardening, Monthly Subscription
    Directadmin installation and optimization

    Click here if you need a Linux Admin

  10. #10
    Join Date
    Oct 2011
    Posts
    10
    Quote Originally Posted by zEitEr View Post
    Why? I don't think that it's obligatory.
    Hi,

    Why we have to use php-fpm for event-mpm ? Do you have any idea about this ? Because on my localserver i'm using mod_php with mpm event.

    I want to use event with mod_php is it possible with DirectAdmin ? Currently my php1_release 7.0, php1_mode mod_php, apache_mpm auto and httpd -v return;
    Server version: Apache/2.4.18 (Unix)
    Server built: Feb 1 2016 01:15:39
    Server's Module Magic Number: 20120211:52
    Server loaded: APR 1.5.2, APR-UTIL 1.5.4
    Compiled using: APR 1.5.2, APR-UTIL 1.5.4
    Architecture: 64-bit
    Server MPM: prefork
    threaded: no
    forked: yes (variable process count)

    But i want to use apache mpm event.

    if i change apache_mpm auto to apache_mpm event is it work ?

    Sorry for my bad english. English is not my native language.

  11. #11
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    11,023
    apache_mpm event is it work ?
    Yes, it should work.

    Code:
    # cd /usr/local/directadmin/custombuild/
    # ./build set apache_mpm event
    Changed apache_mpm option from auto to event
    and build apache:

    Code:
    # ./build apache
    With regards, Alex.

    Professional Server Management for web hosting companies and individuals
    Hourly Support, Disaster Recovery, Server Hardening, Monthly Subscription
    Directadmin installation and optimization

    Click here if you need a Linux Admin

  12. #12
    Join Date
    Jun 2016
    Posts
    1

    Not work for me

    After that I build apache and check the httpd-V I got this:

    Server version: Apache/2.4.20 (Unix)
    Server built: May 22 2016 01:21:49
    Server's Module Magic Number: 20120211:57
    Server loaded: APR 1.5.2, APR-UTIL 1.5.4
    Compiled using: APR 1.5.2, APR-UTIL 1.5.4
    Architecture: 64-bit
    Server MPM: prefork
    threaded: no
    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="/usr/local/apache2"
    -D SUEXEC_BIN="/usr/local/apache2/bin/suexec"
    -D DEFAULT_PIDLOG="logs/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"
    My options.conf is:

    #PHP Settings
    php1_release=7.0
    php1_mode=php-fpm
    php2_release=no
    php2_mode=fastcgi
    opcache=no
    htscanner=no
    php_ini=no
    php_timezone=Europe/Budapest
    php_ini_type=production
    ioncube=no
    zend=no
    suhosin=no
    x_mail_header=yes

    #MySQL Settings
    mysql=5.6
    mariadb=10.0
    mysql_inst=mariadb
    mysql_backup=yes
    mysql_backup_dir=/usr/local/directadmin/custombuild/mysql_backups
    mysql_force_compile=yes

    #WEB Server Settings
    webserver=apache
    litespeed_serialno=trial
    modsecurity=no
    modsecurity_ruleset=comodo
    apache_ver=2.4
    apache_mpm=event
    mod_ruid2=no
    userdir_access=yes
    harden_symlinks_patch=yes
    use_hostname_for_alias=no
    redirect_host=server.hudns.net
    redirect_host_https=no

    #WEB Applications Settings
    phpmyadmin=yes
    phpmyadmin_ver=4
    squirrelmail=no
    roundcube=yes
    webapps_inbox_prefix=no

    #ClamAV-related Settings
    clamav=yes
    clamav_exim=yes
    modsecurity_uploadscan=no
    proftpd_uploadscan=no
    pureftpd_uploadscan=yes
    suhosin_php_uploadscan=no

    #Mail Settings
    exim=yes
    eximconf=yes
    eximconf_release=4.4
    blockcracking=no
    easy_spam_fighter=no
    spamassassin=no
    sa_update=daily
    dovecot=yes
    dovecot_conf=yes
    pigeonhole=no

    #FTP Settings
    ftpd=pureftpd

    #Statistics Settings
    awstats=no
    webalizer=no

    #CustomBuild Settings
    custombuild=2.0
    autover=no
    bold=yes
    clean=yes
    cleanapache=yes
    clean_old_tarballs=yes
    clean_old_webapps=yes
    downloadserver=files.directadmin.com

    #Cronjob Settings
    cron=no
    cron_frequency=weekly
    email=email@domain.com
    notifications=no
    da_autoupdate=yes
    updates=no
    webapps_updates=yes

    #CloudLinux Settings
    cloudlinux=no
    cagefs=no

    #Advanced Settings
    autoconf=yes
    automake=yes
    libtool=yes
    curl=yes
    new_pcre=no
    ap2/configure.apache

    #!/bin/sh
    "./configure" \
    "--prefix=/etc/httpd" \
    "--exec-prefix=/etc/httpd" \
    "--bindir=/usr/bin" \
    "--sbindir=/usr/sbin" \
    "--sysconfdir=/etc/httpd/conf" \
    "--enable-so" \
    "--enable-dav" \
    "--enable-dav-fs" \
    "--enable-dav-lock" \
    "--enable-suexec" \
    "--enable-deflate" \
    "--enable-unique-id" \
    "--enable-cgi" \
    "--disable-cgid" \
    "--enable-mods-static=most" \
    "--enable-mpms-shared=all" \
    "--enable-nonportable-atomics=yes" \
    "--with-mpm=event" \
    "--with-suexec-safedir=/usr/local/safe-bin" \
    "--with-suexec-caller=apache" \
    "--with-suexec-docroot=/" \
    "--with-suexec-gidmin=100" \
    "--with-suexec-logfile=/var/log/httpd/suexec_log" \
    "--with-suexec-uidmin=100" \
    "--with-suexec-userdir=public_html" \
    "--with-suexec-bin=/usr/sbin/suexec" \
    "--with-included-apr" \
    "--with-pcre=/usr/local" \
    "--includedir=/usr/include/apache" \
    "--libexecdir=/usr/lib/apache" \
    "--libdir=/usr/lib/apache" \
    "--mandir=/usr/share/man" \
    "--datadir=/var/www" \
    "--localstatedir=/var" \
    "--enable-logio" \
    "--enable-ssl" \
    "--enable-rewrite" \
    "--enable-proxy" \
    "--enable-expires" \
    "--enable-reqtimeout" \
    "--with-ssl=/usr" \
    "--enable-headers"
    uname -a
    Linux server.name 2.6.32-042stab113.17 #1 SMP Wed Feb 10 18:31:00 MSK 2016 x86_64 x86_64 x86_64 GNU/Linux
    CentOS release 6.8 (Final)

    Any idea what is wrong?

  13. #13
    Join Date
    Jul 2010
    Location
    Poland
    Posts
    79
    Where to edit Apache settings to switch betwean prefork and event mode?

  14. #14
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    11,023
    With regards, Alex.

    Professional Server Management for web hosting companies and individuals
    Hourly Support, Disaster Recovery, Server Hardening, Monthly Subscription
    Directadmin installation and optimization

    Click here if you need a Linux Admin

Similar Threads

  1. Event On Subdomain is added
    By tincboy in forum DirectAdmin General Discussion
    Replies: 1
    Last Post: 09-25-2011, 11:51 PM
  2. switch my DNS server To Google Dns ??
    By XFAISAL in forum DNS
    Replies: 9
    Last Post: 03-18-2010, 03:12 AM
  3. 2Qs: Gobal Hosting setting? Server Mail switch?
    By robj in forum DirectAdmin General Discussion
    Replies: 1
    Last Post: 08-12-2007, 02:41 PM
  4. How to switch server.
    By erictham in forum System-Level Technical Discussion
    Replies: 14
    Last Post: 07-16-2005, 09:56 PM
  5. Server switch
    By l0rdphi1 in forum DirectAdmin General Discussion
    Replies: 3
    Last Post: 05-05-2005, 10:47 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •