SUMMARY: Adding NIS for JavaStation

Paul Silvey (psilvey@mitre.org)
Wed, 02 Apr 1997 10:32:25 -0500

Thanks to the following folks for sending replies:

Scott Tinsley
Caleb Warner
Benjamin Cline
Louis Hoo
Pater Marelas
Glenn Satchell
Jeff Sanders
Matthew Stier
Erick Cedeqo

My original Question:

Sun Managers,

We recently received a couple of JavaStations for evaluation
and prototyping, and I'm trying to configure a Sparc 10
running Solaris 2.5.1 to be their mothership. After
downloading and installing the necessary packages from Sun's
JavaStation web site (http://www.sun.com/javastation), I've
discovered that I also need to have NIS configured on the
Solaris box.

We have always run stand-alone servers with DNS, but without
NIS, and I didn't know I would need it when I first
configured the system. My question is how do I add NIS
server capability to Solaris 2.5? I'm reading man pages on
ypinit, nis+, etc., and I've looked at the /etc/nsswitch.nis
settings (which appear to be related to NIS client setup),
but I'm still rather uncertain about how to proceed.

Any advice or guidance would be greatly appreciated. I'll
summarize to the list. Thanks.

-Paul Silvey
Lead Information Systems Engineer
The MITRE Corporation

The bottom line is that we got the JavaStations to work using NIS+.
In the process, we installed the recommended Solaris 2.5.1 patch
cluster, and set NIS+ to support NIS compatibility. I don't know
for sure if either of those actions were strictly necessary.

A couple of things I learned in the process:
- NIS+ is newer (better?) but different from NIS (yp).
- NIS+ is complicated (i.e. has a learning curve). Entire books
have been written on the subject.
- GUI based tools for NIS+ are not provided by Sun (yet?)
- A great web resource for getting started with NIS+ is the FAQ at:
http://www.eng.auburn.edu/users/rayh/solaris/NIS+_FAQ.html

Here are the individual responses I received:

-------------------------------------------------------------------
>From Scott Tinsley:

You will need the Name Sevice Transition Kit off the 2.5 CDs. These
include the NIS server side support.

Pick a NIS domain name, like "nis.mitre.org". Edit this name in to
the /etc/defaultdomain file.

So you do not have to reboot to set the domain, set the domain name
manually

# domainname "nis.mitre.org"

Run ypinit to build your server as the NIS master and construct
an initial copy of the NIS maps

# ypinit -m

Enter your server as the only server

Replace your current nsswitch.conf file that references "files"
with the one that references nis.

# ls -l /etc/nsswitch.*

Make sure to put you dns entry back in the hosts entry of the
new switch file.

Reboot your machine to make sure all is well.

Check access to your maps

#ypcat -k passwd

You should be running NIS.

Good Luck!

-------------------------------------------------------------------
>From Caleb Warner:

I am sure someone has already replied to this but to install NIS (not NIS+) you
need to add the NSKit v1.2 package which is available off the SUN web pages or
on an additional CD if you have the Server version of the Solaris 2.5.1 install
media. Included in the NSKit package is an answerbook which walks you through
the installation of NIS. The setup of a basic system is very straight forward.

Hope This Helps

Caleb Warner
Raytheon Company

-------------------------------------------------------------------
>From Benjamin Cline:

Solaris doesn't ship with NIS support, so you've got two options: you can
set up NIS+, and configure it to provide backwards compatible NIS support,
or you could install Sun's port of NIS to Solaris (called the NSKit),
which is available from
http://www.sun.com/smcc/solaris-migration/tools/tools.html

benji

- --
Benjamin R. Cline Harrison & Troxell, Inc. benji@hnt.com
Quis Custodiet Ipsos Custodes?

-------------------------------------------------------------------
>From Louis Hoo:

You need to add the appropriate packages. It is not on the Solaris CD, but if
you bought the server version, it is on the 2.5 Server Supplement CD. This CD
also contains Sys Admin Answerbook.

The packages that you need are in the Naming Services Transition Kit.

Hope this helps.

Louis Hoo
Knight-Ridder New Media
Voice: (408)938-6116 Fax: (408)938-6098
email: lhoo@newmedia.kri.com

-------------------------------------------------------------------
>From Peter Marelas:

You need to either install the niskit, or setup NIS+ and run it in
nis compatability mode with the -Y flag to rpc.nisd.

Regards
Peter Marelas
- --
The Fulcrum Consulting Group Peter Marelas - Consultant
12/10-16 Queen St, Melbourne VIC 3000,Australia Ph: +61-3-9621-2100
PGP Key -> finger maral@fusion.mel.sprint.com.au Fx: +61-3-9621-2724

-------------------------------------------------------------------
>From Glenn Satchell:

Look in your Solaris 2.5.1 box - there should be a CD in there with
NSkit 1.2. Install the packages (including the answerbook!) and this
will explain how to set up NIS. You can still use NIS and DNS for
hostname lookups.

regards,
- --
Glenn Satchell glenn@uniq.com.au www.uniq.com.au | Windows:
Uniq Professional Services Pty Ltd ACN 056 279 335 |
PO Box 70, Paddington, NSW 2021, (Sydney) Australia | Just another pane
Phone 02 9380 6360 Pager 016 287 000 Fax 02 9380 6416 | in the glass...
VISIT OUR WEB SITE http://www.uniq.com.au

-------------------------------------------------------------------
>From Jeff Sanders:

you need the "NSkit" package so solaris can be a master (ypserv).
i think it came with the cd set and it's not on the solaris 2 cd.
if you don't have it, look in the sun archives somewhere in
www.sun.com.

don't have the online details yet, but let me know if someone else
on the list doesn't and i'll dig it out for you.

jeff

- --
____________________________________________r. j. "jeff" sanders________
__________tandem computers development computing and network support____
"...let everybody get together then and we'll try to make it." - H. Wolf

-------------------------------------------------------------------
>From Matthew Stier:

NIS+ is native with Solaris 2.x. To have NIX, you need the Naming Service
Transition Kit. It contains the NIS components you need to build an NIS server.

The need for NIS (or NIS+) is that the Javastation needs access to a network
based directory service (passwords, groups, hosts, etc ...) and being Sun
.........

Matthew Stier
mstier@hotmail.com

-------------------------------------------------------------------
>From Erick Cedeqo:

We had the same when we try configuring our JavaStation.

Before attemping any NIS configuration I tried booting the JS without NIS
to make sure the DHCP was working good. It boots, only that logins are not
possible, only as a guest. NIS is needed for login and printing. I guess
you should test your DHCP first before setting NIS.

We did activate NIS+ with NIS compatibility like this (all programs on
/usr/lib/nis )

# nisserver -r -Y

- -r : NIS root server
- -Y NIS compatibility

This creates the NIS tables under the /var/nis directory. You should see
under /var/nis/data all the *.org_dir files.

you must populate the tables by doing (assuming you have all your tables
correctly setup on /etc)

# cd /etc
# nispopulate -F

This will populate all your NIS+ tables from every /etc file (hosts,
passwd, etc.) You can see its content by doing niscat -o passwd.org_dir or
the table you want.

Then, you must manually create the table for dhcp as this is not
automatically created.

# nisaddent -rv -f /etc/default/dhcptab dhcptab

or whichever is your dhcptab file.

do a niscat -o dchptab.org_dir to make sure it has the contents.

the file /etc/nsswitch.conf file is replaced by the contents of
nsswitch.nisplus, the only manual change needed is suggested on the file
itself. If you're using DNS comment the line
hosts: nisplus [NOTFOUND=return] files
and uncomment the line:
#hosts: nisplus dns [NOTFOUND=return] files

Not bad if you do /etc/init.d/rpc stop and /etc/init.d/rpc start to reinit
the rpc service.

That should do it.

Remember the man pages for nis, nisserver, nispopulate, niscat, nisaddent
are all available for you to read.

Hope this helps.

-
-------------------------------------------------------------------------------
Erick Cedeqo Voice: (507) 263 - 9800 ext 135
System Engineer Fax: 223 - 6875
Sonitel,S.A. Beeper: 270 - 0000
P.O. Box 4349 E-mail: erickc@sonitel.com
Panama 5, Panama URL: http://www.sonitel.com

-------------------------------------------------------------------

Thanks again to all the Sun Managers. The list is a great resource.

-Paul Silvey
The MITRE Corporation