You are here: Home R&D Blog limit the size of log file on centos

limit the size of log file on centos

25 Feb


We will show you how to limit the size of log file in centos:


The logs directly in /var/log/httpd are controlled by logrotate.

The logs in /var/log/httpd/domains are controlled by DA.

To limit the size of httpd type:

vi /usr/local/directadmin/data/templates/apache.logrotate

and add this:

/var/log/httpd/domains/you-domain.error.log {



   size 10M



Maher chakroun

All our stuff are available for your support.

Please contact us by email on

Login to post comments

Sample image

Send us an This email address is being protected from spambots. You need JavaScript enabled to view it. or give us a call on (00216) 28 20 22 36


  • Office 1: Sokra Road, km3, Bussiness incubator "Sfax innovation1" - Sfax 3052 - Tunisia.
  • Office 2: Majida Boulia Avenue, Monia Building, S3, O8. Sfax 3000. Tunisia.
  • (00216) 28 20 22 36


Follow SEN_Solutions on Twitter