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.

enabling AWSTATS for 1 account

Discussion in 'General Discussion' started by jamesbond, Dec 5, 2003.

  1. jamesbond

    jamesbond Well-Known Member

    Joined:
    Oct 9, 2002
    Messages:
    738
    Likes Received:
    1
    Trophy Points:
    18
    I have AWSTATS disabled in WHM, but I would like to turn it on for specific accounts.

    I added 'skipawstats=0' in the user config file located in /var/cpanel/users and restarted cpanel.

    It does show up in CPanel but when I click on the link I get this error :

    Error: Couldn't open config file "awstats.xxxxx.com.conf" nor "awstats.conf" after searching in path "./,/home/xxxxx/tmp/awstats/,/etc/opt/awstats,/etc/awstats,/etc,/usr/local/etc/awstats": No such file or directory

    Setup (Config file, web server or permissions) may be wrong.
    See AWStats documentation in 'docs' directory for informations on how to setup awstats.

    It has been 48 hours since I enabled AWSTATS for this account.

    The /home/xxxxx/tmp/awstats is empty, so obviously I am doing something wrong.

    Also when I run /scripts/runweblogs user, I don't see any mention of AWSTATS in the output
     
    #1 jamesbond, Dec 5, 2003
    Last edited: Dec 5, 2003
  2. Wallaby

    Wallaby Well-Known Member

    Joined:
    Aug 15, 2001
    Messages:
    131
    Likes Received:
    1
    Trophy Points:
    18
    Maybe try this:

    - Enable AWStats server-wide in the WHM config (Tweak Settings).

    - Using the feature manager (under Packages), turn off AWStats for the Default feature list.

    - Add a new feature list (eg "plusAWStats") and turn on AWStats for this one.

    - Create a new Package just for your customer, and in the package make the featute list the "plusAWStats" one.

    I haven't tried it and it's convoluted, but it should work.
     
  3. jamesbond

    jamesbond Well-Known Member

    Joined:
    Oct 9, 2002
    Messages:
    738
    Likes Received:
    1
    Trophy Points:
    18
    Does turning it off in the feature manager also mean that stats are not being generated on that account?
    Or is it just that the awstats link is not visible.

    There should be a way to just copy the necessary config files to the account. I don't know what I need to copy exactly though.
     
    #3 jamesbond, Dec 5, 2003
    Last edited: Dec 5, 2003
  4. Dmitry M.

    Dmitry M. Active Member

    Joined:
    Dec 4, 2003
    Messages:
    40
    Likes Received:
    0
    Trophy Points:
    6
    All what you need are

    1. Edit acount profile here
    /var/cpanel/users/account_username
    set
    skipawstats=0

    2. Add awstat config with name
    awstat.domain_name.conf
    to
    /etc folder.
     
  5. jamesbond

    jamesbond Well-Known Member

    Joined:
    Oct 9, 2002
    Messages:
    738
    Likes Received:
    1
    Trophy Points:
    18
    Step 1 I already did, the problem is part 2.
    Where do I get this awstats.domain_name.conf file from?

    I tried this :
    cp /usr/local/cpanel/etc/awstats.conf /etc/awstats.domain.com.conf

    But then it complains about errors in the variables.

    Error: DNSLookup parameter is wrong in config/domain file. Value is '%DNSLOOKUP%' (should be 0 or 1)
     
    #5 jamesbond, Dec 5, 2003
    Last edited: Dec 5, 2003
  6. Dmitry M.

    Dmitry M. Active Member

    Joined:
    Dec 4, 2003
    Messages:
    40
    Likes Received:
    0
    Trophy Points:
    6
    I've attached example of config file to this thread
     

    Attached Files:

  7. jamesbond

    jamesbond Well-Known Member

    Joined:
    Oct 9, 2002
    Messages:
    738
    Likes Received:
    1
    Trophy Points:
    18
    Dimitry thanks for taking the time to upload the file.
    You accidently uploaded a webalizer instead of a awstats config file though :)
     
  8. Dmitry M.

    Dmitry M. Active Member

    Joined:
    Dec 4, 2003
    Messages:
    40
    Likes Received:
    0
    Trophy Points:
    6
    Yes, Here is correct config :)
    This one working for one of accounts at our server
     

    Attached Files:

  9. jamesbond

    jamesbond Well-Known Member

    Joined:
    Oct 9, 2002
    Messages:
    738
    Likes Received:
    1
    Trophy Points:
    18
    Thanks Dimitry.

    This seems to be the same file as the awstats.conf file except for having the domain specific values

    I'll modify the awstats.conf I copied to /etc and see how that goes.

    It would be easier though if it were possible to have awstats.domain.com.conf generated with the correct domain values.
    (I assume this is what cpanel does when you enable awstats serverwide in WHM)
     
  10. jamesbond

    jamesbond Well-Known Member

    Joined:
    Oct 9, 2002
    Messages:
    738
    Likes Received:
    1
    Trophy Points:
    18
    Seems like I have to enable awstats server wide according to CPanel support :

    'Awstats has to be enabled as a whole otherwise cpanel will not include it when the logs are processed, at this time its not possible to just enable it for one site. '
     
Loading...

Share This Page