Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
dns-ng(1)		    General Commands Manual		     dns-ng(1)

NAME
       dns-ng -	generate /etc/netgroup entries from DNS	tables

SYNOPSIS
       dns-ng [	option...  ][ infile [ outfile ]]
       dns-ng -Help
       dns-ng -VERSion

DESCRIPTION
       The  dns-ng program is used to generate a netgroup file from DNS	infor-
       mation.

       Each host is given a netgroup.  Higher-level netgroups can  be  created
       from patterns applied to	the HINFO field.

OPTIONS
       The following options are understood:

       -Help
	       Provide some help with using the	dns-ng program.

       -VERSion
	       Print the version of the	dns-ng program being executed.

       -Group name pattern
	       In  addition  to	 one netgroup for each host, a netgroup	of the
	       given name will be created for all hosts	with  a	 second	 HINFO
	       field matching the given	pattern.  This option may be specified
	       more than once.	The first pattern match	 found	is  used,  ma-
	       chines  are  not	placed in more than one	of these groups.  Pat-
	       terns are regular expressions.

       -Delete_Foreign_Names
	       This option may be used to delete A and NS records which	refer-
	       ence names in domains outside the domain	specified in the clos-
	       est preceeding SOA record.

       -Idirectory
	       This option may be used to set  the  search  path  for  include
	       files.

EXAMPLE
       The  idea  is that you have all of the information concerning each com-
       puter in	the one	file.  This makes it less likely that  something  will
       be omitted, and simpler to change if the	name or	IP address changes.

       By  using netgroups, you	can assign NFS mount permissions (the /etc/ex-
       ports file) and rlogin permissions (the /etc/hosts.equiv	file) based on
       the kind	of machine they	are.

       Given  a	 database  file	 called	``example.com''	and which contains the
       following text
       You can generate	the /etc/netgroup file using the following command
	      %	dns-ng example.com /etc/netgroup \
		      -g pc MSDOS -g mac MacOS \
		      -g unix UNIX -g other '.*'
	      %
       Here is what you	would see as the output
       Note that the output uses relative names.

   Makefile
       All of this can be automated using the following	makefile fragment:
	      /etc/netgroup: example.com
		      dns-ng example.com $@ -g pc MSDOS	\
			      -g mac MacOS -g unix UNIX	-g other '.*'
       By doing	this, all you need to do is edit the example.com file, and the
       use the make(1) command to bring	everything up-to-date.

       If  you were using NIS, NIS+ or LDAP you	would update them, rather than
       the static file,	especially since  on  many  systems  the  static  file
       doesn't do anything.

Reference Manual		    dnsutl			     dns-ng(1)

NAME | SYNOPSIS | DESCRIPTION | OPTIONS | EXAMPLE

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=dns-ng&sektion=1&manpath=FreeBSD+12.0-RELEASE+and+Ports>

home | help