Logrotate for bind9

Anand Buddhdev anandb at ripe.net
Wed Jul 4 14:00:04 UTC 2018


On 04/07/2018 15:50, Blason R wrote:

> Hi There,
> 
> I am not getting appropriate results for my custom daily logrorate for
> bind9 logs on Ubuntu.

It's more useful if you show us your logrotate snippet, so we can point
out what is wrong with it.

> Can someone please help me with the settings which would include below
> stuff
> 
> 
>    1. Should rotate daily

daily

>    2. Compress

compress

>    3. create new file

Usually not needed, because BIND creates the log file itself.

>    4. keep last 180 entries

rotate 180

> Do I need stop bind9 while logs are being rotated? What is the correct
> procedure to start logs in new file?

You don't have to stop BIND to rotate log files. Instead, you just run
"rndc reconfig" and that causes BIND to reopen its log files. If it
finds that the files have been moved (by logrotate) it will create new
log files.

Anand


More information about the bind-users mailing list