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.

Disable Access Logging for certain accounts?

Discussion in 'General Discussion' started by thewird, Mar 30, 2006.

  1. thewird

    thewird Well-Known Member

    Joined:
    Jan 4, 2006
    Messages:
    54
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Toronto
    I have some proxies and they create a TON of accesses per page view. Basically, they grow and grow to enormous proportions (in the gigs). I'd like to know where the access logs are and if I can disable logging for certain accounts and how? Thanks.

    thewird
     
  2. HostMerit

    HostMerit Well-Known Member

    Joined:
    Oct 24, 2004
    Messages:
    160
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    New Jersey, USA
    cPanel Access Level:
    DataCenter Provider
    Create a cron script to run this / clear the stats every 3 or 4 hours, so it'll never be parsed, and won't overfill your /usr directory / cause issues with logs becoming 2.0+ gig - Of course this is only if this is 'your site' / a site that wont need to be metered, etc.

    echo "" > /usr/local/apache/domlogs/domain.com

    Of course replacing domain.com with your domain

    Maybe not the cleanest way, but hey why not? :p
     
  3. thewird

    thewird Well-Known Member

    Joined:
    Jan 4, 2006
    Messages:
    54
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Toronto
    can't I just disable logging to save on CPU as well as space?

    thewird
     
  4. PWSowner

    PWSowner Well-Known Member

    Joined:
    Nov 10, 2001
    Messages:
    2,948
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    ON, Canada
    If you don't want any logging, just remove the log entry lines in the httpd.conf file for that VirtualHost entry, then restart apache.
     
  5. thewird

    thewird Well-Known Member

    Joined:
    Jan 4, 2006
    Messages:
    54
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Toronto
    Which entries would that be?

    Code:
    <VirtualHost 66.90.73.96>
    ServerAlias atunnel.com
    ServerAdmin webmaster@atunnel.com
    DocumentRoot /home/atunnel/public_html
    BytesLog domlogs/atunnel.com-bytes_log
    ServerName www.atunnel.com
    
    User atunnel
    Group atunnel
    CustomLog /usr/local/apache/domlogs/atunnel.com combined
    Options -ExecCGI -Includes
    </VirtualHost>
     
  6. web2corp

    web2corp Member

    Joined:
    Mar 28, 2006
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    1
    the CustomLog line is what sets the access log for that vhost
     
Loading...

Share This Page