Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

29.10. Configure the /etc/logrotate.d/apache file

Configure your /etc/logrotate.d/apache file to rotate each week your Apache log files automatically. Create the apache file, touch /etc/logrotate.d/apache and add:

      /var/log/httpd/access_log {
      missingok
      postrotate
      /usr/bin/killall -HUP httpd
      endscript
      }
      /var/log/httpd/error_log {
      missingok
      postrotate
      /usr/bin/killall -HUP httpd
      endscript
      }
      /var/log/httpd/ssl_request_log {
      missingok
      postrotate
      /usr/bin/killall -HUP httpd
      endscript
      }
      /var/log/httpd/ssl_engine_log {
      missingok
      postrotate
      /usr/bin/killall -HUP httpd
      endscript
      }
    

CAution

Lines to automatically rotate the SSL log files named ssl_request_log and ssl_engine_log are included in this file. If you intend to run Apache without SSL support, you must remove the lines related to SSL.

 
 
  Published under the terms of the Open Publication License Design by Interspire