📄 nonamed.8
字号:
.\" These numbers should match those in nonamed.c:.ds TT "1 hour".ds ST "two seconds".ds MT "four seconds".ds LT "five minutes".ds NS "five".ds NI "256".TH NONAMED 8.SH NAMEnonamed \- not a name daemon, but acts like one.SH SYNOPSIS.B nonamed.RB [ \-d [\fIlevel\fP]].RB [ \-p.IR port ].RB [ \-n.IR address [/\fIport\fP]].SH DESCRIPTION.B Nonamedis not an Internet name daemon. When started it immediately tries to find areal name daemon on the local network. If it finds one then it will relayany DNS queries to that name daemon. If it can't find one then it will doits best to answer simple queries using the.B /etc/hoststable for name to address translation..PPOn startup.B nonamedbroadcasts up to \*(NS simple UDP queries on the local network. This is asomewhat nasty thing to do, because it makes all name servers on the netspring into action to answer the request. The first name server to answeris used by.B nonamedto answer the queries of its clients. The broadcast search is repeatedafter an hour to give another name server a chance to be abused. (It isquite normal for a host to use a remote name server. The broadcasts are abit unfriendly, but they only happen once an hour.).PPIf a real name server is found then.B nonamedenters "relay mode", passing all queries on. In relay mode the daemoncannot be distinguished from a real DNS name daemon. .PP.B Nonamedaccepts both UDP and TCP queries under Minix-vmd. Under standard Minixonly UDP queries are accepted. \*(NI relayed UDP queries can be outstandingbefore it forgets where the first one came from..PPIn answer mode.B nonamedcan answer simple DNS queries to translate a host name to an IP address, oran IP address to a host name. Suppose.B /etc/hostslooks like this:.PP.RS.ta +15n.nf127.0.0.1 localhost192.9.200.1 darask.home.cs.vu.nl192.9.200.2 burask.home.cs.vu.nl.fi.RE.PPThen queries for the host names listed can be answered with the IP addressesto the left of them. If the name can't be found then it is retried with thedomain name stripped of, this is because "localhost" is looked up as"localhost.home.cs.vu.nl" in the above example. Reverse lookups areanswered with the first hostname on the line with the IP address..PPUDP queries are immediately answered on startup if the answer can be foundin the hosts file. Failure answers, and answers to TCP queries are delayeduntil it decides that there are no real name servers out there..PP.B Nonamedemploys several timeouts for efficient operation:.PPIf \*(NS broadcasts, \*(ST apart fail to produce a name server on startupthen it decides that there are no real name servers around..PPAfter \*(TT it will again look for a name server. (We don't want to hog thesame one indefinitely.).PPIf no UDP reply is seen in \*(MT than a simple probe is sent the nameserver. If that doesn't provoke an answer in \*(ST then it will look for anew name server. A failing TCP connection will also invoke a search, theTCP connection is then made to the new name server. A client using UDP willretry eventually, a client using TCP will notice nothing but a short delay.The daemon drops back into answer mode if the search fails and it has ahosts file with a "localhost" entry..PPIt waits \*(LT for any action on a TCP stream before the connection isaborted..PPIn answer mode it will generate data with a TTL (time to live) of \*(TT..SH OPTIONSThe options are only useful when debugging.BR nonamed ,although it can be very instructive to watch DNS queries being done..TP.BR \-d [\fIlevel\fP]Set debugging level to.I level(a single digit, by default.BR 1 .)Debug mode 1 makes.B nonameddecode and display the DNS queries and replies that it receives, sends andrelays. The decoding only handles the common cases. In debug mode 2 itprints tracing information about the internal jobs it executes. In debugmode 3 it core dumps when an error causes it to exit. The debugging levelmay also be increased by 1 at runtime by sending signal.B SIGUSR1or turned off (set to 0) with.BR SIGUSR2 ..TP.RB [ \-p " \fIport\fP]Port to use instead of the normal.B domainport..TP.RB [ \-n " \fIaddress\fP[/\fIport\fP]]Use this IP address and port to find a real name server. It can be used tomake.B nonamedrelay to another.BR nonamed .(They do not listen to broadcasts, of course.) You can run two daemons onone machine if you choose a new port number for one of them. You can force.B nonamedout of relay mode by sending it a hangup signal..SH FILES.TP 15n/etc/hostsHosts to address translation table when in answer mode..SH "SEE ALSO".BR gethostbyname (3),.BR resolver (3),.BR hosts (5),.BR set_net_default (8),.BR boot (8),.BR inetd (8),.BR irdpd (8),.BR rarpd (8)..SH NOTESYou can specify a remote name server in.B /etc/resolv.confto circumvent.BR nonamed .But then you lose its talent for automatically finding new name servers whenthe remote name server becomes unreachable..PPDon't add a "localhost" entry to the hosts file if there are remote nameservers. It makes.B nonameddrop back in answer mode on a flaky network..SH BUGSIf you can get a remote.B nonamedto listen to your name server then you can make it believe anything youwant to. You need access to a machine on the same subnet of course..SH AUTHORKees J. Bot (kjb@cs.vu.nl)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -