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 2 issue with Domlogs

Discussion in 'EasyApache' started by dhananjay, Sep 25, 2007.

  1. dhananjay

    dhananjay Registered

    Joined:
    Feb 21, 2006
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Hello,

    I have come across a small issue;

    apache2 is not producing proper domlogs, so awstats cannot process stats. As apache 2 is new to cPanel, it seems a bug in cpanel apache2.

    In the domlogs all that appears in the log is this

    combined
    combined
    combined

    Any help will be appreciated.

    Thank you.

    Regards,
    DhananJay
     
  2. RSCChris

    RSCChris Active Member

    Joined:
    Sep 15, 2004
    Messages:
    26
    Likes Received:
    0
    Trophy Points:
    1
    Having this same issue on one server as well. Any help would be appreciated.
     
  3. schumilux

    schumilux Member

    Joined:
    Jan 14, 2006
    Messages:
    18
    Likes Received:
    0
    Trophy Points:
    1
    I have had sleepless nights with the same problem...lots of angry customers.

    Add the following line to /usr/local/apache/conf/httpd.conf:
    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\"\"%{User-agent}i\"" combined
    Restart Apache and type the following
    /usr/local/cpanel/bin/apache_conf_distiller --update

    You should have again logs, good luck :)
     
  4. SunDanceKid

    SunDanceKid Member

    Joined:
    Dec 26, 2005
    Messages:
    19
    Likes Received:
    0
    Trophy Points:
    1
    Does it matter where in the file you put that line? I just tried this and it didn't work for me .
     
  5. Worelock

    Worelock Active Member

    Joined:
    Mar 23, 2004
    Messages:
    37
    Likes Received:
    0
    Trophy Points:
    6
    I tried this fix and it didnt work.
    Apache is still not logging info for the domains on the server.
    It all started when I ran the easyapache 3.2.0 update.
    I have even rerun easyapache 3.2 just this minute and the problem still exists.

    Cheers
    Paul
     
  6. t9clkclnr

    t9clkclnr Well-Known Member

    Joined:
    Jun 11, 2004
    Messages:
    254
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Southern California
    Same problem here

    I have this is many of my domlogs:

    combined
    combined
    combined


    about 4 thousand lines of this in some accounts. Other accounts only have 1 instance of this.
    It all started the same day I ran the update to apache2 as well.

    There is something not right.

    WHM 11.11.0 cPanel 11.15.0-C17588
    CENTOS Enterprise 4.5 i686 on standard - WHM X v3.1.0
     
  7. ManojB

    ManojB Well-Known Member

    Joined:
    Mar 25, 2005
    Messages:
    80
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    pune
    Please try and add all of the following lines to /usr/local/apache/conf/httpd.conf

    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
    LogFormat "%h %l %u %t \"%r\" %>s %b" common
    LogFormat "%{Referer}i -> %U" referer
    LogFormat "%{User-agent}i" agent

    Restart Apache and type the following
    /usr/local/cpanel/bin/apache_conf_distiller --update

    You should have again logs !!
     
  8. SunDanceKid

    SunDanceKid Member

    Joined:
    Dec 26, 2005
    Messages:
    19
    Likes Received:
    0
    Trophy Points:
    1
    That worked. Thanks ManojB!!!
     
  9. dahatecatalyst

    Joined:
    Jul 15, 2005
    Messages:
    10
    Likes Received:
    0
    Trophy Points:
    1
    Also make sure the following lines are not being loaded within an ifmodule embankment

    Code:
    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
    LogFormat "%h %l %u %t \"%r\" %>s %b" common
    LogFormat "%{Referer}i -> %U" referer
    LogFormat "%{User-agent}i" agent
    
    If they are being loaded within a module that is not loading they will also not load and be skipped over.

    Incorrectly these will not load as such
    Code:
    <IfModule mod_log_config>
        LogFormat "%h %l %u %t \"%r\" %>s %b" common
        LogFormat "%{User-agent}i" agent
        LogFormat "%{Referer}i -> %U" referer
        LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
    
        CustomLog logs/access_log common
    
    </IfModule>
    
    
     
  10. CoolMike

    CoolMike Well-Known Member

    Joined:
    Sep 6, 2001
    Messages:
    307
    Likes Received:
    0
    Trophy Points:
    16
    I added this line, but awstats is still not updating. But I saw, that the logfiles are not created at the same place anymore like before. Before there where in /usr/loacal/apache/domlogs/domain.com, now they are in /usr/loacal/apache/domlogs/username/domain.com. Is this a problem?

    Michael
     
  11. majidnt

    majidnt Well-Known Member

    Joined:
    Nov 15, 2004
    Messages:
    46
    Likes Received:
    0
    Trophy Points:
    6
    awstats problem

    i have a silimar problem,all setting in whm and httpd.conf checked and right,are there any new idea?
     
  12. konrath

    konrath Well-Known Member

    Joined:
    May 3, 2005
    Messages:
    367
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Brasil
    Fixed for me.

    Thank you
    Konrath
     
  13. cPanelDon

    cPanelDon cPanel Quality Assurance Analyst
    Staff Member

    Joined:
    Nov 5, 2008
    Messages:
    2,557
    Likes Received:
    7
    Trophy Points:
    38
    Location:
    Houston, Texas, U.S.A.
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    For the benefit of others, would you please clarify what exactly helped you?
     
  14. konrath

    konrath Well-Known Member

    Joined:
    May 3, 2005
    Messages:
    367
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Brasil
    Yes, of course ;)


    I put this lines in the httpd.conf

    pico /etc/httpd/conf/httpd.conf

    Code:
    
    <IfModule log_config_module>
        LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
        LogFormat "%h %l %u %t \"%r\" %>s %b" common
    
        CustomLog logs/access_log common
    
        <IfModule logio_module>
            LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
    
        </IfModule>
    
    </IfModule>
    
    
    

    And

    /scripts/restartsrv httpd ( to restart the apache )
    /scripts/runstatsonce ( to run awstats for all sites )


    NOTE 1:
    ---------------------------
    I put these lines below

    <Location /whm-server-status>
    SetHandler server-status
    Order deny,allow
    Deny from all
    Allow from 127.0.0.1
    </Location>




    NOTE 2:
    ---------------------------
    I have another server with APACHE 2 and preferred to copy these lines from my other server updated.

    This post is old (2007)


    NOTE 3:
    ---------------------------
    See in my code ( combinedio )
    I kept (combinedio) because in my other server was written (combinedio)
    Is working properly with me.


    This is another post that I collect in my favorites. I have several links to important post.


    Thank you
    Konrath
     
    #14 konrath, Aug 17, 2010
    Last edited: Aug 17, 2010
Loading...

Share This Page