Tuesday, May 17, 2011

Network Information System (NIS)

NIS server configuration involves the following steps:
1. Setting the NIS domain name.
2. Configuring and starting the server daemon, ypbind.
3. Initializing the NIS maps.
4. Starting the NIS password daemon.
5. Starting the NIS transfer daemon if you use slave servers.
6. Modifying the startup process to start the NIS daemons when the system
With the NIS domain name set, at least temporarily, you can configure and start the primary NIS server daemon. The key configuration files are /var/yp/securenets and /etc/ypserv.conf. /etc/ypserv.conf is the configuration file for both ypserv, the primary NIS server daemon, and the NIS transfer daemon, ypxfrd. It contains runtime configuration options, called option lines, for ypserv, and host access information, called access rules, for both ypserv and ypxfrd. The default values in /etc/ypserv.conf, which are shown in Listing below, are sufficient for most NIS server configurations.  The Default ypserv.conf File Values for Red Hat Linux
Network Information Service is the most common used authentication service along with LDAP.
NIS is used to managae users centrally.
NIS was originally called as YellowPages or YP
Developed by SUN Microsystems.
Maintains a central directory of USers,groups,hostnames,email aliases,etc in  a computer network.
Packages required :   ypserv*, ypbind*, yptools*
Ypserv and ypbind are also required at client side
Port Number : Uses random ports.
To chk the port number  use command   rpcinfo -p
Configuration file :  /var/yp/MakeFile
Database : MAPS
give the NISDOMAINNAME  in  /etc/sysconfig/network file.
Edit the /etc/hosts file   by assigning the IPaddress to the NIS Domain Name
ex:   nisserver.abc.com    misserver
Change the system NIS DOMAIN NAME
#nisdomainname  nisserver
Now goto /var/yp/MakeFile and edit the following options
(line no:23)            NOPUSH=TRUE
(line no:109)           all:passwd group hosts\
Now restart the service ypserv
the command to craete the NIS database is
#/usr/lib/yp/ypinit -m
Now restart the service     yppasswdd   (This invokes the database)
NOW create the some users with passwords.
This makes database update about the creation or deletion of entries in NIS database
#service yppasswdd restart
install the packages ypbind and yptools
select USE NIS and next
give the domain name and server ip address
#Vi /etc/exports
save and exit
#Service nfs restart
No login as user reated in server  using su -
mount the shared(/home) directory in client
now chk by creating the files or folders.
The files and folders get stored in /home direcory of NIS server.

This the way to configure NIS Domain Name.