|
Home > Archive > Unix administration > June 2005 > Putting DNS names in NIS tables.
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Putting DNS names in NIS tables.
|
|
| george.e.sullivan@saic.com 2005-05-24, 8:38 am |
| Do most of you Unix admins put your DNS names in your NIS host tables?
Just wondering, I've heard differing options like you don't need it
with resolv.conf or you do if you turn the switch on in
/var/yp/Makefile, etc.
Anyway an example would be:
# NIS Hosts with DNS names also
123.4.5.6 fred fred.flintstone.org
123.4.5.7 wilma wilma.flintstone.org
What do you do?
Thanks
| |
|
| When I was running NIS, long long ago, we explicitly did not keep NIS
host tables.
Our /etc/hosts file kept the hosts we needed to maintain access to
despite DNS failures - NFS servers, NIS servers, and so on, and that
was it. We didn't want to move that into NIS, because we needed the
NIS entries before NIS was up, so we'd be splitting our local entries
into multiple places.. it just seemed like unnecessary work.
*rereads article*
Hm. Are you talking about FQDNs, rather than just shortnames? whoof.
No matter what, if I were using NIS for host name service, I'd put any
hostname I'd be likely to refer to the server with into NIS, to avoid
the risk of having one name resolved by one service, and another by the
other. Consistency of behavior and all that.
| |
| Thomas Schulz 2005-05-24, 6:04 pm |
| In article <1116942220.307681.265600@g47g2000cwa.googlegroups.com>,
<george.e.sullivan@saic.com> wrote:
>Do most of you Unix admins put your DNS names in your NIS host tables?
>Just wondering, I've heard differing options like you don't need it
>with resolv.conf or you do if you turn the switch on in
>/var/yp/Makefile, etc.
>
>Anyway an example would be:
>
># NIS Hosts with DNS names also
>
>123.4.5.6 fred fred.flintstone.org
>123.4.5.7 wilma wilma.flintstone.org
>
>What do you do?
>
>Thanks
The main reason for wanting to have host names that are available by dns
appear in NIS is if you have machines that do not understand dns. For
example, our old SunOS 4.1.* (Solaris 1.*) machines do not know how to
use dns (mostly, there are some parts that do). If you need just a few
names to appear in NIS, you can enter them in the hosts file on your NIS
master. If you want everything to be available, you would edit the NIS
make file (/var/yp/Makefile) and place the line 'B=-b' in it near the top.
There is a comment showing you where. This does not actually load the
host names into the NIS hosts map. Instead, it causes any query for a name
not already in the map to cause a dns query to happen and then the result
is returned as though the name were in the map. If you put the 'B=-b'
line in your make file, then the only entries that you would need in the
NIS master's hosts file would be those not in dns or those that you might
need if dns is down.
--
Tom Schulz
schulz@adi.com
| |
| Doug Freyburger 2005-05-26, 6:00 pm |
| george.e.sullivan@saic.com wrote:
>
> Do most of you Unix admins put your DNS names in your NIS host tables?
> Just wondering, I've heard differing options like you don't need it
> with resolv.conf or you do if you turn the switch on in
> /var/yp/Makefile, etc.
>
> Anyway an example would be:
>
> # NIS Hosts with DNS names also
> 123.4.5.6 fred fred.flintstone.org
> 123.4.5.7 wilma wilma.flintstone.org
>
> What do you do?
Reasons I can think of that someone would want to do this:
1) DNS is too slow. Actual fix is to correct your broken
DNS config. Any correct DNS config is at least as fast
as NIS.
2) DNS goes down too often. Irrational fear.
I only put hosts in /etc/hosts that need to be there
without DNS running.
In the past I have build NIS tables with all local
hosts, but the only reason I did that was to build my local
DNS tables from it.
| |
| george.e.sullivan@saic.com 2005-05-27, 5:56 pm |
| Thanks to all who have given input to this. I will keep my DNS healthy
and my host lite.
| |
| Vanton 2005-06-23, 2:48 am |
| check my short story out..
http://nova.powix.org/~seeweed/web/motgate.com/
I tend to put a + for my domain name, since I usually run older BSD-based
SunOS (4.1.3U1) so my stuff looks like this. (btw, I like the bsd-based
Operating System using Disk Suite 1.0 so I can have larger that 2.1 Gig )
/etc/domainname
+OPENSUNOS.COM
/var/yp/Makefile.yp
has
b=-b
and walla..
<george.e.sullivan@saic.com> wrote in message
news:1116942220.307681.265600@g47g2000cwa.googlegroups.com...
> Do most of you Unix admins put your DNS names in your NIS host tables?
> Just wondering, I've heard differing options like you don't need it
> with resolv.conf or you do if you turn the switch on in
> /var/yp/Makefile, etc.
>
> Anyway an example would be:
>
> # NIS Hosts with DNS names also
>
> 123.4.5.6 fred fred.flintstone.org
> 123.4.5.7 wilma wilma.flintstone.org
>
>
> What do you do?
>
> Thanks
>
>
|
|
|
|
|