# BIND logging[SOLVED]

## Tony0945

I have a lot of messages like this in /var/log/messages:

```
Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 10.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 16.172.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 17.172.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 18.172.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 19.172.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 20.172.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 21.172.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 22.172.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 23.172.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 24.172.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 25.172.IN-ADDR.ARPA

Mar 27 11:37:30 gentoo named[3123]: automatic empty zone: 26.172.IN-ADDR.ARPA

```

Are this harmful? Should I configure something differently?

Also, what do I have to do to get messages logged in say /var/log/named.log instead of /var/log/messages?

I'd like messages to be notified of start/stop and the fact that errors or warnings exist, but not voluminous standard messages.Last edited by Tony0945 on Sat May 20, 2017 7:22 pm; edited 1 time in total

----------

## theotherjoe

Tony0945,

regarding log destination for bind, have a look at the link article.

there is an example at the end:

http://www.zytrax.com/books/dns/ch7/logging.html

edit: and these are commented lines from an example

I used to get my named.conf going:

```
/*

logging {

        channel default_log {

                file "/var/log/named/named.log" versions 5 size 50M;

                print-time yes;

                print-severity yes;

                print-category yes;

        };

        category default { default_log; };

        category general { default_log; };

};

*/

```

----------

## bunder

Yes these are normal, they just mean you don't have a zone file for some of the RFC1918 blocks.

----------

## Tony0945

theotherjoe,

Thank you for the link. I did already have the section you posted (Uncommented).

The link helped explain things. I accomplished my purpose by adding to /etc/syslog-ng/syslog-ng.conf:

```
destination namedlog { file("/var/log/named/named.log"); };

filter f_BIND { program(named); }; /* f_named was illegal for some reason */

log { source(src); filter(f_BIND); destination(namedlog); };
```

With that change, the early logging that is sent to /var/log/messages is re-directed to /var/log/named/named.log

----------

## Tony0945

 *bunder wrote:*   

> Yes these are normal, they just mean you don't have a zone file for some of the RFC1918 blocks.

 

Should I have a zone file? Or should I just ignore the messages now that they don't clutter /var/log/messages?

----------

## bunder

 *Tony0945 wrote:*   

>  *bunder wrote:*   Yes these are normal, they just mean you don't have a zone file for some of the RFC1918 blocks. 
> 
> Should I have a zone file? Or should I just ignore the messages now that they don't clutter /var/log/messages?

 

It should only print those once when bind starts up, and you don't need a (reverse) zone file for a netblock which you don't use.

----------

