1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice
  2. Dear Pleskians, please read this carefully! New attachments and other rules Thank you!
    Dismiss Notice
  3. Dear Pleskians, I really hope that you will share your opinion in this Special topic for chatter about Plesk in the Clouds. Thank you!
    Dismiss Notice

httpd logs not rotating

Discussion in 'Plesk for Linux - 8.x and Older' started by ++good, Jun 3, 2005.

  1. ++good

    ++good Guest

    0
     
    I'm a plesk newbie, using 7.5.3. I have setup logrotation for all my domains (daily, keep 7, and compress) and made sure that they are enabled. However, the log files are not being rotated.

    All the files in /usr/local/psa/etc/logrotate.d look like the sample below (except for the domain name). I tried running /usr/local/psa/logrotate/sbin/logrotate -d on one of the conf files, I got this error:
    log /home/httpd/vhosts/domain/statistics/logs/*.processed does not exist -- skipping

    Ok, the log files are /home/httpd/vhosts/domain/statistics/logs/access_log

    This is the file name the domain httpd.conf file uses and plesk is the one that genereated the httpd.conf files.

    I am kinda stumped. Can anyone point my in the right direction?

    Thanks,
    Marcus

    /home/httpd/vhosts/domain/statistics/logs/*.processed {
    daily
    rotate 7
    compress
    missingok
    }
    /home/httpd/vhosts/domain/statistics/logs/error_log {
    daily
    rotate 7
    compress
    missingok
    copytruncate
    }
    /home/httpd/vhosts/domain/statistics/logs/error_ssl_log {
    daily
    rotate 7
    compress
    missingok
    copytruncate
    }
     
  2. worker

    worker Guest

    0
     
    Maybe try creating them?
    # touch /home/httpd/vhosts/domain.com/statistics/logs/{access_log,xferlog_regular}.processed
     
  3. ++good

    ++good Guest

    0
     
    Thanks for the suggestion, but it seems that now the system is only trying to rotate that empty log file.

    Should my acccess log be access_log, or access_log.processed ? access_log is what plesk set the log file to, but the log rotation conf file seems to want access_log.processed

    Thanks,
    Marcus
     
  4. worker

    worker Guest

    0
     
    You should have both logs. I believe when `statistics` is done, it moves the entries to the .processed log.
     
  5. ++good

    ++good Guest

    0
     
    Thanks for the reply.
    I guess the statistics job isn't running. Would you have any idea why that wouldn't be? I have stats setup for each domain.

    Thanks,
    Marcus
     
  6. worker

    worker Guest

    0
     
    You should check your cron file for root:

    bash-2.05b# grep /var/spool/cron/root -e stat
    7 4 * * * /usr/local/psa/admin/sbin/statistics >/dev/null 2>&1
    bash-2.05b#
     
  7. ++good

    ++good Guest

    0
     
    That did it!
    Thanks,
    Marcus
     
Loading...