Re: Manually rolling logfiles over

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Joseph L. Casale wrote:
> How can I do this w/o restarting services or rebooting?

copy/truncate.

copy log file to a new file and truncate the original
(cat /dev/null >filename)

Or setup a logrotate config with the copytruncate option.

There is a chance I believe to drop some log events between
the copy and the truncate depending on how active the log is.

Or use a log service such as syslog.

nate

_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux