Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ h2n(1M) — DG/UX R4.11

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

named(1M)

admdns(1M)



h2n(1M)                         TCP/IP R4.11                         h2n(1M)


NAME
       h2n - Translate host table to name server file format

SYNOPSIS
       h2n -d domain -n net [ options ]

DESCRIPTION
       h2n translates /etc/hosts (or the hosts-like master file specified
       with the -h option) to DNS db file format and creates the named boot
       file.  This tool can be run once or many times.  After converting
       your master file to DNS format, you can manually maintain the DNS db
       files, or you can maintain the master file and run h2n each time you
       modify the master file.  h2n automatically increments the serial
       number in each DNS db file when it builds the new databases.

       h2n generates files starting with the prefix "db."  These are called
       "db files".  The domain data is stored in a file called db.domain,
       where domain is the first label in your domain name (given with the
       -d option).  The address-to-name data is stored in files named
       db.net, where net is a network number (given with the -n option).

       Each time h2n is run, it generates the DNS db files from scratch.
       Any changes you manually made to the DNS db files are lost.  If you
       would like to add resource records (RRs) to a db file generated by
       h2n, put your RRs in a file prefixed with "spcl" instead of "db".
       h2n will include this file's data by adding a $INCLUDE directive to
       the end of the db file.

       By default, h2n will generate an MX record with a weight of 10 that
       points to the host itself as the mail exchanger.  MX records can be
       suppressed with -M.  Additional MX records can be added with -m.  To
       suppress generating the default MX record for a host, include "[no
       smtp]" in that host's master file comment.

       By default, h2n will create a boot file, ./boot.cacheonly, for a
       caching only name server.  If either of the -z or -Z options are
       used, h2n creates a boot file, named ./boot.sec.save or ./boot.sec
       respectively, for a secondary name server.

OPTIONS
       -b bootfile
              Use bootfile instead of the default: ./named.boot.

       -c domain
              Create CNAME records in the default domain for all the hosts
              in domain.  Including more than one -c option is allowed.

       -d domain
              Your domain name is domain.

       -e domain
              Eliminate all lines from the master file with names in domain.
              Including more than one -e option is allowed.

       -f file
              Command line options are in a file called file.  This options
              cannot be used within file.

       -h host
              Use host in the fields of the SOA record that require a
              hostname.  The default is the host on which you run h2n.

       -m weight:mx-host
              Include an MX record for each host in your domain pointing to
              mx-host at weight.  Including more than one -m option is
              allowed.
              Example: -m 10:terminator.movie.edu -m 20:wormhole

       -n net[:subnetmask]
              net is your network number without the trailing zeros.
              Including more than one -n option is allowed.  If subnetmask
              is provided, create data for each subnet of net.
              Example: -n 192.249.249 -n 15.15.16:255.255.248.0

       -o refresh:retry:expire:minimum
              Change the default SOA values (10800:3600:604800:86400) to the
              values provided.

       -s server
              List server in each domain's NS records.  Including more than
              one -s option is allowed.

       -t     Generate TXT records from the master file comments.  If "[no
              smtp]" appears in a comment, it is ignored.

       -u user
              Use user in the SOA mail address instead of "root".  user can
              be a complete mail address as in: me@a.b.c.

       -w     Generate WKS records that list the SMTP service over the TCP
              protocol if an MX record is also created.

       -z address
              Create a boot file, ./boot.sec.save, for a secondary name
              server that lists address as the master to load from.  Save a
              copy of the domain data in a backup file.  (This option is
              similar to the -Z option.)

       -C comment-file
              Create resource records by using keys in the master file
              comment field as indices into comment-file.  comment-file.
              contains "key:resource record" pairs like: "720:IN HINFO
              av9500 dgux".  When h2n encounters "720" in the comment
              section of the master file, it creates a resource record by
              replacing the "720:" with the hosts's canonical name.

       -H hostfile
              Use hostfile instead of /etc/hosts.

       -M     Don't generate MX records.

       -N subnetmask
              Apply subnetmask to all network numbers instead of listing
              each subnet with -n.  Specifying a subnet mask with -n
              overrides the -N subnet mask for that network only.

       -Z address
              Create a boot file, ./boot.sec, for a secondary name server
              that lists address as the master to load from.  Do not save a
              copy of the data in a backup file. (This option is similar to
              the -z option.)

EXAMPLES
       Create name server data for networks 192.249.249 and 192.253.253 in
       movie.edu,

         h2n -d movie.edu -n 192.249.249 -n 192.253.253

       Create name server data for networks 192.249.249 and 192.253.253 in
       movie.edu.  Eliminate lines in the master file that contain
       fx.movie.edu and include MX records for all hosts pointing to the
       mail hub, postmanrings2x.movie.edu.  Include all of the options in a
       file.

         h2n -f optionfile

       Where option_file contains the following lines:

         -d movie.edu
         -n 192.249.249
         -n 192.253.253
         -e fx.movie.edu
         -m 50:postmanrings2x.movie.edu

SEE ALSO
       named(1M), admdns(1M)


Licensed material--property of copyright holder(s)

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026