티스토리 뷰

OpenSUSE 11 NIS Server Configure NIS Client


Configure NIS Client

 

Configure NIS Client.




1. Install Ypbind to configure.


www:~ # zypper -n install ypbind

# set NIS domain

www:~ # ypdomainname srv.world 

www:~ # echo "srv.world" > /etc/defaultdomain 

www:~ # vi /etc/yp.conf

# add to the end: [domain name] [server] [NIS server's hostname] 

domain srv.world server otaec.srv.world


www:~ # vi /etc/nsswitch.conf

# change like follows

passwd: compat nis

group:  compat nis


hosts:  files dns nis

networks:       files dns


services:       files nis

protocols:      files

rpc:    files

ethers: files

netmasks:       files

netgroup:       files nis

publickey:      files


bootparams:     files

automount:      files

aliases:        files nis

shadow: compat


# set follows if needed (create home directory automatically if none)

www:~ # vi /etc/pam.d/common-session

# add to the end

session optional        pam_mkhomedir.so skel=/etc/skel umask=077


www:~ # echo '+::::::' >> /etc/passwd 

www:~ # echo '+' >> /etc/shadow 

www:~ # chkconfig ypbind on 

www:~ # reboot 

www login: suse     # NIS user

Password:

Creating directory '/home/suse'.

suse@www:~>     # just logined


# show binded NIS server

suse@www:~> ypwhich 

otaec.srv.world


# try to cgange password

suse@www:~> passwd 

Changing password for suse.

Old Password:     # old one

New Password:     # new one

Reenter New Password:

Changing NIS password for suse on otaec.srv.world.

Password changed.     # just changed

댓글