📄 readme
字号:
# Copyright (c) 1992 by Texas Internet Consulting# This code may be freely copied and used so long as this# copyright notice is attached. This code may not be sold# without the express written permission of Texas Internet Consulting.# Texas Internet Consulting makes no warranty as to the correctness# nor the applicability of this code for any purpose.Generic host configuration files.This is a brief overview of a set of utilities used to managehost files when running DNS or NIS nameservice or both.File description:README - this fileetc.named - files installed in /etc/namedgendns - shell script to generate DNS tablesgenstatic - shell script to generate static host filemake_rev - automatically creates the reverse DNS mappoke_ns.c - C program to help manage DNS serversreadinfo - shell script to extract fields from hst filesupdatehosts - shell scrip to automate host updateThis host database system organizes host information in a set offlat tables. All host updates are made in these tables. From thesetables both the static host table and the DNS database files are created.This eliminates potential errors caused by having to maintain two sets ofhost tables.The static host table is used to update NIS maps, if you run NIS. It canalso be used on machines which may not have DNS or NIS support.Install the scripts in /usr/local/etc. Compile and install poke_ns in/usr/local/etc making it setuid to root, but only executable by the groupof users which will be maintainingg the host database. Do not make itexecutable by everyone. Check the define NAMED and be sure it points tothe pathname for your nameserver.The next step is to install the files in etc.named in the /etc/nameddirectory or the directory where the DNS database files will be maintained.Now populate the host database files. These files are organized like arelational database and consist of several files. They are all under SCCScontrol and must be checked out to be populated. Be sure and check thefiles back in under SCCS before continuing.hosts.main - the main host file. Required fields are the host and IPaddress field. Note the #FIELDS line. This describes the fields to thereadinfo script which extracts particular fields from the host.* files.Each field is described by its fieldname, followed by an optional prefix=,suffix=, or no= descriptor. The prefix= and suffix= describe what will beprepended or appended to the field value when readinfo outputs the field.For host names the suffix is equal to the default domain. For hostaddresses the prefix is equal to the network number. This facility is auseful shorthand. The no= field gives a character which says to displaythe host value as given and ignore any prefix or suffix. For example ifyour default domain is tic.com and you have a host named tic.com enter itin the file as @tic.com@.hosts.cname - host alias file. This has two fields the real host namefollowed an alias for the host. If a host has more than a single alias,renteer the host name followed by the second alias.hosts.mx - DNS MX information is entered here. This file has three fields:the domain name to MX for, the priority of the MX record and the host toforward mail to for this domain.The other hosts.* and remaining files are helper filesfor creating the static host tables and DNS files. No data needs to be entered into them.Create a file in nisservers of the host names for NIS servers for doinghost lookups. If you have no NIS servers performing this function do notcreate this file.Run the command updatehosts -u. This will generate the DNS tables andstart the DNS server or cause the currently running server to reload itsdata files. If you are replacing an existing DNS server it is best tobring it down first before typing this command. When you update the hostfiles in the future, type updatehosts followed by the names of the fileswhich need to be updated. e.g. updatehosts hosts.main. This can be done inany directory. Updatehosts knows how to find the files. The -u option isused when you want to update the server without modifying any files or youmodified the files by manually running SCCS.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -