Can two views be layered?

Novosielski, Ryan novosirj at umdnj.edu
Fri Mar 15 23:31:22 UTC 2013


Thanks! Wonderful -- asked and answered. 


----- Original Message -----
From: Joseph S D Yao [mailto:jsdy at tux.org]
Sent: Friday, March 15, 2013 07:11 PM
To: Novosielski, Ryan
Cc: 'bind-users at lists.isc.org' <bind-users at lists.isc.org>
Subject: Re: Can two views be layered?

On Fri, Mar 15, 2013 at 06:56:57PM -0400, Novosielski, Ryan wrote:
> Hi all. Running BIND 9.6 I believe it is. Not important what version as if there is a version that can do this and I'm not running it, I can go there. 
> 
> Is it possible to have a view that is in essence a list of exceptions to the main zone? eg. the example.com domain exists, so does www.example.com, but for a small subset of machines I need it to resolve to a different address -- every other address should come from the main zone.
> 


It is not possible to have views layered as you describe.  However, try
this:

file zonename.shared with all shared records.
file zone.zonename.for-the-many with the records for the many.
	$INCLUDE "zonename.shared"
File zone.zonename.for-the-few with the records for the few.
	$INCLUDE "zonename.shared"

view "for_the_few" {
	...
	zone "zonename" {
		...
		file "data/zone.zonename.for-the-few";
		...
	};
};

view "for_the_many" {
	...
	zone "zonename" {
		...
		file "data/zone.zonename.for-the-many";
		...
	};
};


--
/*********************************************************************\
**
** Joe Yao				jsdy at tux.org - Joseph S. D. Yao
**
\*********************************************************************/




More information about the bind-users mailing list