NetBSD2 | NetBSD | 1.6 | amd | autoconf | apache | bind | booting | boot/install/disk | boot-cd | build.sh | (daily) | Canna | CF+sendmail | cvs | dhcpd | dvi2ps | emacs-20 | ftpmirror | fvwm2 | gcc | gettext | ghostscript | inn | IPv6 | jitterbug | Install(OHP) | kernel | (old) | majordomo | make build | MHonArc | MRTG | namazu | ndtpd | PHP + PostgreSQL | netatalk | netboot | NFS | NIS | ntp | opie | Open Firmware | perl | procmail | sendmail | sharutils | smtpfeed | tcsh | TeX | time make | ucspi-tcp | w3 | wget | Wnn | wu-ftpd | X11 | Site Map |
全文検索

NIS for NetBSD

necessary setup for NIS, NIS に必要な設定
種類/etc/rc.confypinit/etc/master.passwd
ypservypbind
master yes
slave
client× vipw
ypinit をすると
/var/yp/Makefile.yp 
/var/yp/Makefile.main
/var/yp/bind
の隣に /var/yp/Makefile が出来る
で、そこで make をしておく


○ 次のような記述がある。これらが設定出来るはず。
root@tateyama 23:42:15/980629(/var/yp)# egrep '^[a-z]+' Makefile.yp | grep DIR passwd.time: ${DIR}/master.passwd aliases.time: ${DIR}/aliases amd.home.time: ${AMDDIR}/amd.home ethers.time: ${DIR}/ethers group.time: ${DIR}/group hosts.time: ${DIR}/hosts netgroup.time: ${DIR}/netgroup networks.time: ${DIR}/networks protocols.time: ${DIR}/protocols rpc.time: ${DIR}/rpc services.time: ${DIR}/services netid.time: ${DIR}/passwd ${DIR}/group ${DIR}/hosts ${DIR}/netid ypservers.time: ${.CURDIR}/ypservers
設定するのは /etc の下
root@tateyama 23:42:38/980629(/var/yp)# grep ^DIR Makefile.yp DIR= /etc root@tateyama 23:42:39/980629(/var/yp)#
○ man ypserv を見る。

ypinit

○ 次のようにして見る。nis-domain-name-here は仮名 root@tateyama 23:48:06/980629(/var/yp)# ypinit -m nis-domain-name-here Server type: master Domain: nis-domain-name-here Installing the YP database may require that you answer a few questions. Any configuration questions will be asked at the beginning of the procedure. Can we destroy the existing /var/yp/nis-domain-name-here and its contents? [y/n: n] y Done. Be sure to run `make' in /var/yp. root@tateyama 23:48:52/980629(/var/yp)# ls -lt total 14 drwx------ 2 root wheel 512 Jun 29 23:48 nis-domain-name-here -rw------- 1 root wheel 216 Jun 29 23:48 Makefile -r--r--r-- 1 bin bin 200 Dec 6 1997 Makefile.main -r--r--r-- 1 bin bin 9839 Dec 6 1997 Makefile.yp drwxr-xr-x 2 root wheel 512 Dec 6 1997 binding ○ make して下さいと言われたので、入力して見る。 root@tateyama 23:48:59/980629(/var/yp)# make all ===> nis-domain-name-here updated passwd yppush: error binding to nis-domain-name-here: Can't communicate with ypbind yppush: error binding to nis-domain-name-here: Can't communicate with ypbind yppush: error binding to nis-domain-name-here: Can't communicate with ypbind yppush: error binding to nis-domain-name-here: Can't communicate with ypbind pushed passwd Warning: .cf file is out of date: sendmail 8.9.0 supports version 8, .cf file is version 7 /var/yp/nis-domain-name-here/nis-domain-name-here-aliases: 44 aliases, longest 99 bytes, 1560 bytes total mkalias: problem storing makoto@ki.nu postmaster updated aliases yppush: error binding to nis-domain-name-here: Can't communicate with ypbind yppush: error binding to nis-domain-name-here: Can't communicate with ypbind pushed aliases couldn't find /etc/amd/amd.home couldn't find /etc/ethers updated group yppush: error binding to nis-domain-name-here: Can't communicate with ypbind yppush: error binding to nis-domain-name-here: Can't communicate with ypbind pushed group updated hosts yppush: error binding to nis-domain-name-here: Can't communicate with ypbind yppush: error binding to nis-domain-name-here: Can't communicate with ypbind pushed hosts couldn't find /etc/netgroup updated networks yppush: error binding to nis-domain-name-here: Can't communicate with ypbind yppush: error binding to nis-domain-name-here: Can't communicate with ypbind pushed networks updated rpc yppush: error binding to nis-domain-name-here: Can't communicate with ypbind pushed rpc updated services yppush: error binding to nis-domain-name-here: Can't communicate with ypbind pushed services updated protocols yppush: error binding to nis-domain-name-here: Can't communicate with ypbind yppush: error binding to nis-domain-name-here: Can't communicate with ypbind pushed protocols updated netid yppush: error binding to nis-domain-name-here: Can't communicate with ypbind pushed netid root@tateyama 23:50:04/980629(/var/yp)#
○ 確かに ypbind が動いていないので、
root@tateyama 23:50:04/980629(/var/yp)# ps ax | grep ypbind 2667 p0 S+ 0:00.50 grep ypbind ○ 動かしてから ypwhich や ypcat をすると、動いているようだ。 root@tateyama 23:54:04/980629(/var/yp)# ypbind root@tateyama 23:54:08/980629(/var/yp)# ypwhich LOCALHOST root@tateyama 23:54:12/980629(/var/yp)# ypcat passwd | less ○ /etc/rc.conf の(次で言えば) 70,71 行目を生かしておく必要がありそう。 root@tateyama 23:57:22/980629(/var/yp)# grep -2n YP /etc/rc.conf 67-xdm=NO xdm_flags="" # x11 display manager 68- 69:# YP (NIS) daemons 70-ypbind=NO ypbind_flags="" 71-ypserv=NO ypserv_flags="-d" ○隣の機械で見えるか試して見る。 makoto@ci 0:01:11/980630(~)> su Password: # domainname nis-domain-name-here # ypwhich ypwhich: clntudp_create: localhost: Can't communicate with ypbind # ypbind # ypwhich ml.domain.name # ypcat passwd | less # ○ 別の日に make した時の様子 root@tateyama 8:28:46/981015(/var/yp)# make all ===> nis-domain-name-here updated passwd yppush: Master's version not newer yppush: Master's version not newer yppush: Master's version not newer yppush: Master's version not newer pushed passwd Warning: .cf file is out of date: sendmail 8.9.1+3.0W supports version 8, .cf file is version 7 /var/yp/nis-domain-name-here/nis-domain-name-here-aliases: 68 aliases, longest 114 bytes, 2940 bytes total mkalias: problem storing makoto@yy.xx.zz owner-alias1 mkalias: problem storing makoto@yy.xx.zz owner-alias2 mkalias: problem storing makoto@yy.xx.zz owner-alias3 mkalias: problem storing makoto@yy.xx.zz postmaster updated aliases yppush: Master's version not newer yppush: Master's version not newer pushed aliases couldn't find /etc/amd/amd.home couldn't find /etc/netgroup updated netid yppush: Master's version not newer pushed netid root@tateyama 8:29:27/981015(/var/yp)#