NIS-Slave

Like many others, I had been fighting with the error...

"Can't enumerate maps from <master_server>. Please check that it is
running."

...generated when running...

/usr/lib/yp/ypinit -s <master_server>

...to configure a Red Hat NIS slave server.

I resolved the problem by pulling together a couple of separate suggestions.
The essence of the problem is that the /usr/lib/yp/ypinit script does not
have a good reputation! Two consecutive lines were originally as follows:

#  maps=`ypwhich -m | egrep $MASTER$| awk '{ printf("%s ",$1) }' -`
  maps=`$YPBINDIR/yphelper --maps $MASTER`

Changing them as follows allows you to run the /usr/lib/yp/ypinit -s
<master_server> command successfully, with the map files being copied into
/var/yp/<domain>:

  maps=`ypwhich -m | egrep $MASTER| awk '{ printf("%s ",$1) }' -`
#  maps=`$YPBINDIR/yphelper --maps $MASTER`

The specific changes are:
- use the 'ypwhich' line instead of the 'yphelper' line.
- remove the extraneous '$' after 'MASTER'.

Hope this is of help to someone! It took me long enough to sort it out.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值