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.

AWstats LogFormat not sticking

Discussion in 'General Discussion' started by ckoehler, Dec 17, 2009.

  1. ckoehler

    ckoehler Member

    Joined:
    Aug 7, 2009
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    Hi,

    I am using a custom log format for our apache logs, but it broke stats.
    Now, I changed /usr/local/cpanel/etc/awstats.conf to account for the different format, but I guess it gets overwritten all the time.
    I even copied it to /etc/, but it doesn't work.

    Any idea how to make the changes stick?

    Thanks!

    Christoph
     
  2. ckoehler

    ckoehler Member

    Joined:
    Aug 7, 2009
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    Anyone? Bueller?
     
  3. ckoehler

    ckoehler Member

    Joined:
    Aug 7, 2009
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    Lalala. Any smart cPanel people here?
     
  4. 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:
    One possible method that I would consider for modifying AWStats directives is to ensure the following option is enabled via WHM then define the customizations in a user-specific include file:
    WHM: Main >> Server Configuration >> Statistics Software Configuration >> Generators Configuration
    * Allow Awstats configuration Include file
    Awstats Include file option will allow a user defined configuration file to be included at the time of statistics processesing. The include file should be place in the user's home directory at ~/tmp/awstats/awstats.conf.include. This file can be used to override and add new configuration options to Awstats.


    Related Documentation: Generators Configuration
     
  5. ckoehler

    ckoehler Member

    Joined:
    Aug 7, 2009
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    Thanks Don!

    I've seen this option, but the log format change was server wide, so adding a conf file per user is not feasible. Is there a way to prevent cpanel from overwriting the file all the time? Or a way to specify a different file at some other location?

    Christoph
     
  6. ckoehler

    ckoehler Member

    Joined:
    Aug 7, 2009
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    Anything? Surely I am not the only person with this problem.
     
  7. 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:
    I apologize for the delayed update; while researching internally I was unable to determine an easier way to accomplish the task. I believe a feature request would help best to have the enhanced functionality considered for inclusion as a native (built-in) feature.

    If needing to safely retain an edit to the default AWStats configuration file I recommend using one of the built-in hooks to execute a custom script or other custom commands that reapply the change or apply a patch. Here is our documentation regarding script hooks for cPanel and WHM:
    cPanel/WHM Script Hooks
    Here is an example of a pre hook and a post hook that could be created and used as referenced in the documentation:
    Code:
    /scripts/preupcp
    /scripts/postupcp
    For development-related inquires, (e.g., usage of hooks), I recommend the cPanel and WHM Developer Discussions forum area:
    Developer Discussions - cPanel Forums

    The following documentation regarding other built-in hooks may also be of interest:
    Hooking into cPanel Functionality
    EasyApache Hook Scripts
     
Loading...

Share This Page