The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Apache auto update?

Discussion in 'EasyApache' started by mtech-hosting, Sep 18, 2007.

  1. mtech-hosting

    mtech-hosting Well-Known Member

    Joined:
    Apr 30, 2006
    Messages:
    62
    Likes Received:
    0
    Trophy Points:
    6
    Man this is killing me. I moved php5 to fastcgi, made the edits to the php.conf file to parse certain info and ran the distiller just fine. This morning i wake up and find that my site no longer works correctly and apache decided all by itself to go back to su_PHP.

    I can appreciate that the cpanel guys wanted to make things better and i can appreciate the work that went into it, but it is not working the way it is intended, according to the many complaints on the forum. I cant go to to sleep each night knowing i followed directions and wake up to an inoperable site.

    What was wrong with the old style apache configs whre the changes actually stuck when you saved the file? Can we (I) have that back please? Sure it was long, but it worked. I simply wish to edit a file and forget about it.

    Forgive me if this sounds like a rant, i love cpanel and enjoyed using it up until 16XXX builds, after that so far its been a nightmare and is really hurting our business as we've had more downtime in the last few days than we've ever had in the last 8-9 months.
     
  2. cPanelDavidG

    cPanelDavidG Technical Product Specialist

    Joined:
    Nov 29, 2006
    Messages:
    11,279
    Likes Received:
    8
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    So you are aware, Apache recompiles do not occur automatically. They must be manually initiated either via the WHM interface or /scripts/easyapache
     
  3. mtech-hosting

    mtech-hosting Well-Known Member

    Joined:
    Apr 30, 2006
    Messages:
    62
    Likes Received:
    0
    Trophy Points:
    6
    Thats what i thought and perhaps apache update wasn't the correct wording. Whatever it is, i went to bed last night running php5 fastcgi/suexec and woke up this morning running php5 su_php and i didnt change it?
     
  4. cPanelBilly

    cPanelBilly Guest

    There is no suexec for PHP5 on su_php... You must have enabled su_php for 5.
     
  5. mtech-hosting

    mtech-hosting Well-Known Member

    Joined:
    Apr 30, 2006
    Messages:
    62
    Likes Received:
    0
    Trophy Points:
    6
    This was my configuration as i left it last night:
    Code:
    # This file was automatically generated by the Cpanel PHP Configuration system
    # If you wish to change the way PHP is being handled by Apache on your system,
    # use the /usr/local/cpanel/bin/rebuild_phpconf script or the WHM interface.
    #
    # Manual edits of this file will be lost when Apache is updated.
    
    
    # Fastcgi configuration for PHP5
    LoadModule fcgid_module modules/mod_fcgid.so
    MaxRequestsPerProcess 500
    AddHandler fcgid-script .php5 .php .php3 .php2 .phtml .html
    FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .php5
    FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .php
    FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .php3
    FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .php2
    FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .phtml
    FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .html
    
    # SuPHP configuration for PHP4
    LoadModule suphp_module modules/mod_suphp.so
    suPHP_Engine on
    AddType x-httpd-php4 .php4
    <Files *.php4>
        suPHP_AddHandler x-httpd-php4
    </Files>
    
    # End of autogenerated PHP configuration.
    
    
    and when i looked this morning, it had mysteriously changed to this:
    Code:
    # This file was automatically generated by the Cpanel PHP Configuration system
    # If you wish to change the way PHP is being handled by Apache on your system,
    # use the /usr/local/cpanel/bin/rebuild_phpconf script or the WHM interface.
    #
    # Manual edits of this file will be lost when Apache is updated.
    
    
    # SuPHP configuration for PHP5
    LoadModule suphp_module modules/mod_suphp.so
    suPHP_Engine on
    AddType x-httpd-php5 .php5 .php .php3 .php2 .phtml
    <Files *.php5>
        suPHP_AddHandler x-httpd-php5
    </Files>
    <Files *.php>
        suPHP_AddHandler x-httpd-php5
    </Files>
    <Files *.php3>
        suPHP_AddHandler x-httpd-php5
    </Files>
    <Files *.php2>
        suPHP_AddHandler x-httpd-php5
    </Files>
    <Files *.phtml>
        suPHP_AddHandler x-httpd-php5
    </Files>
    
    # SuPHP configuration for PHP4
    AddType x-httpd-php4 .php4
    <Files *.php4>
        suPHP_AddHandler x-httpd-php4
    </Files>
    
    # End of autogenerated PHP configuration.
    
    I do not know why?
     
  6. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,458
    Likes Received:
    22
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    If your cPanel is set for auto-update, then it picked up the new build released, which contained fixes for php.conf

    If you are modifying /usr/local/apache/conf/php.conf please be aware that at this time, changes to that file are not retained. Hence the warning at the top:

    From reading this, it appears that last line needs tweaking or the scenario you described needs a bit of testing.
     
  7. mtech-hosting

    mtech-hosting Well-Known Member

    Joined:
    Apr 30, 2006
    Messages:
    62
    Likes Received:
    0
    Trophy Points:
    6
    cPanel updates are set to manual, everything else is automatic / inherit. I was fully aware of the warning, but, assumed that running distiller cemented these changes. What would happen if i just put the php.conf info in the httpd.conf, removed the include line for the php.conf and ran the distiller? Will it retain the php changes in the apache conf?

    Needless to say, we cant worry about nightly mishaps if it happens to occur again and no one is available to correct it.
     
  8. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,458
    Likes Received:
    22
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    Nah, distiller doesn't cement changes to php.conf, only httpd.conf

    Your customizations for FCGI should be added to httpd.conf, after the Include "/usr/local/apache/conf/php.conf" line, then execute:

    /usr/local/cpanel/bin/apache_conf_distiller --update --main

    It appears there is a problem with the caching involved with this entire process that is interfering with generation of a new httpd.conf with the directives/values one just distilled. This will be fixed in the next build(s).
     
Loading...

Share This Page