I have php-fpm.log which is about 1 gb now. How can I setup log rotation like in linux logrotate?
Open config file for syslogd:
ee /etc/newsyslog.conf
And add line:
/var/log/php-fpm.log 600 5 100 * JC
Where 5 – count of rotated files and 100 – max size (in mb).