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.

Raw Log Access

Discussion in 'General Discussion' started by Jason Brice, Aug 2, 2002.

  1. Jason Brice

    Jason Brice Active Member

    Joined:
    Sep 29, 2001
    Messages:
    44
    Likes Received:
    0
    Trophy Points:
    6
    Hi,

    I'm a reseller and don't have root access so this may complicate what I'm about to ask.

    The I own the largest site on my server, and it currently does about 50Gb of traffic a month.

    When I try to access the raw log files from CPanel using :2082/getaccesslog/ towards the end of the month the download quite often times out and I get only part of the logs.

    Is there a way to telnet in and build the logs into a gzip in my root, and then ftp them down?

    Any other solutions? It's getting quite annoying as I am finding it difficult to sell advertising without accurate traffic reporting.
     
  2. awsol

    awsol cPanel Test Bitch

    Joined:
    Feb 8, 2002
    Messages:
    591
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Boston MA
    Contact your provider and tell them to do the following

    mkdir /home/USERNAME/logs

    pico httpd.conf

    hit control + W and then type the username to search within the apache config

    Change

    CustomLog domlogs/DOMAIN.com combined
    to
    CustomLog /home/USERNAME/logs/DOMAIN.com combined

    Hit control + O then Enter

    Now just to be safe have them do this

    chown USERNAME.USERNAME /home/USERNAME/logs/domain.com


    Then tell them to restart apache just to make sure it all works right. That way it don't crash while they're AFK. Rather have it crash while they're there.


    Now all you have to do is login via FTP and change directories to logs and download the file. This will be in realtime so you can use webtrends or your favorite traffic generator.

    Also tell them to replace USERNAME with your correct username. And domain.com with your domain.

    I do this for a bunch of my clients. You will be happy with how it works.

    Good luck and may business bring you great pleasure.
     
  3. Jason Brice

    Jason Brice Active Member

    Joined:
    Sep 29, 2001
    Messages:
    44
    Likes Received:
    0
    Trophy Points:
    6
    Thanks!

    :)

    I will pass this on to my provider. Hopefully they'll be able to get it sorted soon!
     
  4. Jason Brice

    Jason Brice Active Member

    Joined:
    Sep 29, 2001
    Messages:
    44
    Likes Received:
    0
    Trophy Points:
    6
    Okay, got some additional questions...

    I gzipped the file to download it, but then found that once I'd removed the file the logs didn't start building themselves again in the /logs directory. I had to get my provider to run your routine again. I'd have expected that the logs would start a new in the directory if there wasn't one there, but they didn't.

    Also, I'm concerned that uncompressed they will grow to a huge size in my user area.

    I'm not so good with cron jobs, but would it be possible to run one that would compress the logs into a daily chunk, and still allow them to continue building uninterupted in the logs area? Way back when I started running my site at hypermart.net they provided a facility like that.

    Any suggestions?
     
  5. martekbiz

    martekbiz Member

    Joined:
    Mar 17, 2004
    Messages:
    17
    Likes Received:
    0
    Trophy Points:
    1
    Hi there,

    Hope you don't mind me bumping an OLD post but I have a question regarding what you wrote, specifically the chown... part.

    IS there a way to automatically chown the /logs/filename without having to manually do it everytime you setup a new account?

    Can it be incorporated into the CustomLog/virtual area?

    Any idea/help?

    Thanks!!!

    Aaron
     
  6. andyf

    andyf Well-Known Member

    Joined:
    Jan 7, 2002
    Messages:
    246
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    UK
    I believe there's a option in cpanel to archive the months into your home directory at the EOM, if this helps.
     
Loading...

Share This Page