Named version: BIND 9.10.3-P4 (the latest one), OS versions: CentOS 6.3, CentOS 6.7
I need to use shared zones in different views, since 9.10 ISC Bind doesn't support using the same file for the same zone in different views. Trying to do so will lead to an error:
/etc/named.conf:21: writeable file 'slaves/example.db': already in use: /etc/named.conf:8
The documentation suggests using the in-view statement. Brandon Xavier in serverfault recommends the same. However, I failed. Here's simplified configuration file I'm trying to load:
view "internal" {
zone example.com {
type slave;
file "slaves/example.db";
masters { 192.168.1.1; };
};
};
view "external" {
zone example.com {
in-view "internal";
};
};
Removing the zone example.com from external view allows named to start. Configuring it to the separate file also works:
zone example.com {
type slave;
file "slaves/example2.db";
masters { 192.168.1.1; };
};
But pointing to a different file is not an option - hereby I provide only example of real configuration. Also when Bind is trying to start, there's no output with an error message nor anything in logs:
# /etc/init.d/named restart
Stopping named: [ OK ]
Starting named:
Error in named configuration:
[FAILED]
Isn't it just nice? Named-checkconf doesn't show any errors (I removed commas or brackets on purpose - checkconf works). I've also taken configuration files from 9.10.3-P4 sources.tar.gz (bin/test/system/..) and the result was the same. Should I report a bug?
/var/log/debug.log
seems like a potentially problematic path in terms of permissions (at least when rotating logs) whennamed
is going to write to a file itself rather than just passing messages to syslog.