您的位置:首页 > 运维架构 > Linux

CentOS5.5 NFS不能启动问题解决

2010-09-08 08:45 495 查看
今天重新启动自己的CentOS5.5系统的时候,突然NFS不能启动,手动启动出现以下错误

# /etc/init.d/nfs restart
Shutting down NFS mountd:                                  [FAILED]
Shutting down NFS daemon:                                  [FAILED]
Shutting down NFS quotas:                                  [FAILED]
Shutting down NFS services:                                [FAILED]
Starting NFS services:                                     [  OK  ]
Starting NFS quotas: Cannot register service: RPC: Unable to receive; errno = Connection refused
rpc.rquotad: unable to register (RQUOTAPROG, RQUOT***ERS, udp).
                                                           [FAILED]
Starting NFS daemon:                                       [FAILED]
# /etc/init.d/portmap restart
Stopping portmap:                                          [FAILED]
Starting portmap: portmap: error while loading shared libraries: libnsl.so.1: cannot open shared object file: No such file or directory




开始以为是前两天系统升级导致的,所以就重新安装的portmap和相关的包,并做好相关配置,但是再次启动时又出现以下错误

# /etc/init.d/nfs restart
Shutting down NFS mountd:                                  [FAILED]
Shutting down NFS daemon:                                  [FAILED]
Shutting down NFS quotas:                                  [FAILED]
Shutting down NFS services:                                [FAILED]
Starting NFS services:                                     [  OK  ]
Starting NFS quotas: Cannot register service: RPC: Unable to receive; errno = Connection refused
rpc.rquotad: unable to register (RQUOTAPROG, RQUOT***ERS, udp).
                                                           [FAILED]
Starting NFS daemon: rpc.nfsd: error while loading shared libraries: libc.so.6: failed to map segment from shared object: Permission denied
                                                           [FAILED]




没有办法,运行了一下restorecon命令

# restorecon -R /




然后再次重新启动机器,问题解决了。



后来查了一下restorecon命令的手册,说明如下:

This program is primarily used to set the security context (extended attributes) on one or more files.

It can be run at any time to correct errors, to add support for new policy, or with the -n option it can just check

whether the file contexts are all as you expect.



所以也许开始不需要重新安装包,运行一下这个命令就搞定了,但是没法再做测试了。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: