87 lines
3.5 KiB
HTML
87 lines
3.5 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
|
|
<!--Converted with LaTeX2HTML 96.1-c (Feb 29, 1996) by Nikos Drakos (nikos@cbl.leeds.ac.uk), CBLU, University of Leeds -->
|
|
<HTML>
|
|
<HEAD>
|
|
<TITLE>Setting up a NIS Client with NYS</TITLE>
|
|
</HEAD>
|
|
<BODY LANG="EN">
|
|
<A HREF="node1.html"><IMG WIDTH=65 HEIGHT=24 ALIGN=BOTTOM ALT="contents" SRC="contents_motif.gif"></A> <BR>
|
|
<B> Next:</B> <A HREF="node136.html">Choosing the Right Maps</A>
|
|
<B>Up:</B> <A HREF="node130.html">The Network Information System</A>
|
|
<B> Previous:</B> <A HREF="node134.html">Running a NIS Server</A>
|
|
<BR> <P>
|
|
<H1><A NAME="SECTION0012500000">Setting up a NIS Client with NYS</A></H1>
|
|
<P>
|
|
<A NAME="nisyp"></A>
|
|
<A NAME="5105"></A>
|
|
<A NAME="5106"></A>
|
|
<P>
|
|
Throughout the remainder of this chapter, we will cover the
|
|
configuration of a NIS client.
|
|
<P>
|
|
<A NAME="5332"></A>
|
|
<A NAME="5108"></A>
|
|
Your first step should be to tell NYS which server to use for NIS
|
|
service, setting it in the /etc/yp.conf configuration file.
|
|
A very simple sample file for a host on the Winery's network may look
|
|
like this:
|
|
<P>
|
|
<P><P>
|
|
<P>
|
|
The first statement tells all NIS clients that they belong to the
|
|
winery NIS domain. If you omit this line, NYS will use the
|
|
domain name you assigned your system through the domainname
|
|
command. The server statement names the NIS server to use.
|
|
Of course, the IP address corresponding to vbardolino must be set
|
|
in the hosts file; alternatively, you may use the IP-address
|
|
itself with the server statement.
|
|
<P>
|
|
In the form shown above, the server command tells NYS to use the
|
|
named server whatever the current NIS domain may be. If, however, you are
|
|
moving your machine between different NIS domains frequently, you may want
|
|
to keep information for several domains in the yp.conf file. You can
|
|
have information on the servers for various NIS domains in yp.conf
|
|
by adding the NIS domain name to the server statement. For
|
|
instance, you might change the above sample file for a laptop to look like
|
|
this:
|
|
<P>
|
|
<P><P>
|
|
<P>
|
|
This allows you to bring up the laptop in any of the two domains by simply
|
|
setting the desired NIS domain at boot time through the domainname
|
|
command.
|
|
<A NAME="5333"></A>
|
|
<P>
|
|
<A NAME="5334"></A>
|
|
<A NAME="5127"></A>
|
|
After creating this basic configuration file and making sure it is
|
|
world-readable, you should run your first test to check if you can
|
|
connect to your server. Make sure to choose any map your server
|
|
distributes, like hosts.byname, and try to retrieve it by using
|
|
the ypcat utility. ypcat, like all other administrative
|
|
NIS tools, should live in /usr/sbin.
|
|
<P>
|
|
<P><P>
|
|
<P>
|
|
<A NAME="5335"></A>
|
|
The output you get should look something like that shown above. If you
|
|
get an error message instead that says ``Can't bind to server
|
|
which serves domain'' or something similar, then either the NIS domain
|
|
name you've set doesn't have a matching server defined in
|
|
yp.conf, or the server is unreachable for some reason. In the
|
|
latter case, make sure that a ping to the host yields a positive
|
|
result, and that it is indeed running a NIS server. You can verify the
|
|
latter by using rpcinfo, which should produce the following
|
|
output:
|
|
<P>
|
|
<P><P><HR><A HREF="node1.html"><IMG WIDTH=65 HEIGHT=24 ALIGN=BOTTOM ALT="contents" SRC="contents_motif.gif"></A> <BR>
|
|
<B> Next:</B> <A HREF="node136.html">Choosing the Right Maps</A>
|
|
<B>Up:</B> <A HREF="node130.html">The Network Information System</A>
|
|
<B> Previous:</B> <A HREF="node134.html">Running a NIS Server</A>
|
|
<P><ADDRESS>
|
|
<I>Andrew Anderson <BR>
|
|
Thu Mar 7 23:22:06 EST 1996</I>
|
|
</ADDRESS>
|
|
</BODY>
|
|
</HTML>
|