Страница 1 из 1

named view master and slave

Добавлено: 03 май 2013, 04:49
admin
Content of named.conf.local in dns-01:

Код: Выделить всё

key "external" {
	algorithm hmac-md5;
	secret "HvJo78teh/7iyK8BlSkmAA==";
};

view "internal" {
	match-clients { !key external; 192.168.1.0/24; };
	recursion yes;
	zone "example.com" {
		type master;
		file "/etc/bind/db.example.com-int";
		allow-transfer { 192.168.1.202; };
	};
	zone "1.168.192.in-addr.arpa" {
		type master;
		file "/etc/bind/db.192";
		allow-transfer { 192.168.1.202; };
	};
};

view "external" {
	match-clients { key external; any; };
	server 192.168.1.202 { keys external; };
	recursion no;
	zone "example.com" {
		type master;
		file "/etc/bind/db.example.com-ext";
		allow-transfer { 192.168.1.202; };
	};
	zone "zz.yy.xx.in-addr.arpa" {
		type master;
		file "/etc/bind/db.xx";
		allow-transfer { 192.168.1.202; };
	};
};
Content of named.conf.local in dns-02:

Код: Выделить всё

key "external" {
	algorithm hmac-md5;
	secret "HvJo78teh/7iyK8BlSkmAA==";
};

view "internal" {
	match-clients { !key external; 192.168.1.0/24; };
	recursion yes;
	zone "example.com" {
		type slave;
		file "db.example.com-int";
		masters { 192.168.1.201; };
	};
	zone "1.168.192.in-addr.arpa" {
		type slave;
		file "db.192";
		masters { 192.168.1.201; };
	};
};

view "external" {
	match-clients { key external; any; };
	server 192.168.1.201 { keys external; };
	recursion no;
	zone "example.com" {
		type slave;
		file "db.example.com-ext";
		masters { 192.168.1.201; };
	};
	zone "zz.yy.xx.in-addr.arpa" {
		type slave;
		file "db.xx";
		masters { 192.168.1.201; };
	};
};