From owner-freebsd-questions Tue Oct 15 15:00:09 1996 Return-Path: owner-questions Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id PAA11893 for questions-outgoing; Tue, 15 Oct 1996 15:00:09 -0700 (PDT) Received: from red.interact.net.au (red.interact.net.au [203.23.1.50]) by freefall.freebsd.org (8.7.5/8.7.3) with ESMTP id PAA11784 for ; Tue, 15 Oct 1996 15:00:00 -0700 (PDT) Received: from mailhost.bimberi.com.au (mailhost.bimberi.com.au [203.20.123.10]) by red.interact.net.au (8.7.5/8.7.3) with ESMTP id HAA08931; Wed, 16 Oct 1996 07:59:34 +1000 (EST) Received: from toad (toad.bimberi.com.au [203.20.123.1]) by mailhost.bimberi.com.au (8.7.5/8.7.3) with SMTP id HAA21092; Wed, 16 Oct 1996 07:56:12 +1000 (EST) Message-Id: <3.0b35.32.19961016075538.00940330@mailhost.bimberi.com.au> X-Sender: heagre@mailhost.bimberi.com.au X-Mailer: Windows Eudora Pro Version 3.0b35 (32) Date: Wed, 16 Oct 1996 07:56:04 +1000 To: "Lenzi, Sergio" From: Greg Healy Subject: Re: NAMED administration. Cc: questions@freebsd.org, freebsd@iqm.unicamp.br Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Sender: owner-questions@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Sergio You shoud specify the SOA records a little better. At 00:32 11/10/96 +0000, Lenzi, Sergio wrote: @ IN SOA $host.$localdomain. root.( should be @ IN SOA $host.$localdomain. hostmaster.$localdomain ( Where hostmaster is an alias to the person responsible for the zone's data. Otherwise its a good tool for setting up the initial named database files You could also include the following HOST=ftp.rs.internic.net. ftp -n -v < >Hello. > >To all of you who is in need to make named to work and need to >build those "db" files, here is a shell script that "builds" a >working named "site" for you. > > >Your machine must be setted up with ip, and name in the /etc/hosts. > > >--------- >#!/bin/sh >if [ ! -d /var/named ] >then > mkdir /var/named >fi >cd /var/named >host=`hostname` >localip=`grep $host /etc/hosts | awk '{print $1}'` >lastiptok=`echo $localip | awk -F. '{print $4}'` >revip=`echo $localip | awk -F. '{printf "%d.%d.%d",$3,$2,$1}'` >localdomain=`echo $host | awk -F. '{print $2}'` >host=`echo $host | awk -F. '{print $1}'` >echo -n root name server ip: >read rootip >echo -n root name server name: >read nroot > >cat > /etc/named.boot <<% >; >; Boot file for name server >; >directory /var/named >cache . cache >primary $localdomain db.$localdomain >primary 0.0.127.in-addr.arpa db.local >primary $revip.in-addr.arpa $localdomain.rev >% >cat > cache <<% >; BIND data file for initial cache data for root domain servers. >; >$localdomain. IN NS `hostname`. >br. IN NS dixit.ansp.br. >. IN NS $nroot. >; >; ADDRESS >; >dixit.ansp.br. IN A 143.108.1.17 >`hostname`. IN A $localip >$nroot. IN A $rootip >% >cat > db.$localdomain <<% >; >; named definition for $localdomain >; >@ IN SOA $host.$localdomain. root.( > 1 ; Serial > 3600 ; Refresh > 300 ; Retry > 3600000 ; Expire > 3600 ) ; Minimum > NS $host.$localdomain. > MX 10 $host.$localdomain. >; >localhost IN A 127.0.0.1 >$host IN A $localip > >\$INCLUDE localnet >% >cat > db.local <<% >; >; named.local >; >@ IN SOA $host.$localdomain. root.( > 18 ; Serial > 3600 ; Refresh > 300 ; Retry > 3600000 ; Expire > 3600 ) ; Minimum > IN NS $host.$localdomain. >1 IN PTR localhost. >% >cat > $localdomain.rev <<% >@ IN SOA $host.$localdomain. root.( > 1 ; Serial > 3600 ; Refresh > 300 ; Retry > 3600000 ; Expire > 3600 ) ; Minimum > > IN NS $host.$localdomain. > >1 PTR $host.$localdomain. >% >cat > /etc/resolv.conf <<% >domain $localdomain >nameserver 127.0.0.1 >% >----------------- > >Sergio Lenzi. > >Unix consult. > > >