Network Information System (used to be Yellow Pages) basics for JumpStart configuration. Use LDAP for all other purposes.
Define your NIS domainname:
domainname your_domain > /etc/defaultdomain
Edit or create the /etc/ethers file (see the man page, should contain mac address and hostname per client). This is only necessary when you are going to use this NIS server as a JumpStart server.
Check that you have /etc/locale and /etc/timezone. See the man pages for possible choices, e.g.:
promt:> cat locale your_domain en_US prompt:> cat timezone MET your_domain
These files are also needed for Jumpstart using NIS.
Create a source file directory for NIS, e.g. /etc/nis.
Place all the files needed for the JumpStart in this directory:
cd /etc cp bootparams ethers hosts locale netgroup netmasks timezone nis/
This way, we don't have to work on original data from /etc and files from other hosts can be imported.
Edit the /var/yp/Makefile file: DIR and PWDIR should point to the location of your source file directory. Check the all target. You can use the timezone target as a template for adding locale.time. This is needed for JumpStarting clients without intervention. When customizing the NIS maps, don't forget to add a .time directive and a reference to the file to process at the bottom of the Makefile.
Initialize the NIS master server:
Answer the questions this asks.
Upon initializing the server, the make command will be called to create the NIS tablespaces from the Makefile. If the tables are made without any fatal errors, everything should be OK, however messy the output. If all the tables are updated, don't worry about warnings. When changing the NIS tablespaces, run /usr/ccs/bin/make manually after removing /var/yp/*.time.
Check that /var/yp/your_domain is populated with pairs of files (.pag and .dir, .dir may be empty).
Run /usr/lib/netsvc/yp/ypstart. This should start 5 daemon processes: ypserv, ypbind, rpc.yppasswd, ypxfrd and rpc.ypupdated.
Test your server running the ypwhich command, eventually with the -m option, this should show your NIS domain and, with the option, the NIS maps.
Normally not advised these days any more, but if you should be confronted with problems in NIS installations that are not migrated to LDAP yet, check the following:
The /etc/nsswitch.conf file should reflect the use of a NIS nameservice next to the normal files and, eventually, dns:
passwd: files nis group: files nis hosts: files nis dns ipnodes: files networks: files nis protocols: files nis rpc: files nis ethers: files nis netmasks: files nis bootparams: files nis publickey: files nis netgroup: files nis automount: files nis aliases: files nis services: files nis sendmailvars: files printers: user files nis auth_attr: files nis prof_attr: files nis project: files nis
The /etc/hosts file on the client should contain entries for all NIS master and slave servers.
Set the domainname, as for the server.
Has the client been initialized? Check the existence of /var/yp/binding/your_domain/ypservers. If the information in this file is not correct, remove it and run ypinit -c.
Is ypbind running? If not, start the daemon using the /usr/lib/netsvc/yp/ypstart program.