AIX 5.3 问题描述:
Linux 服务器上共享了/nfs 这个目录,如何将这个共享目录正确的挂载到AIX 的/data/wuxf 这个挂点。
解答:
1.在Linux 服务器上共享/nfs 这个目录, 在/etc/exports文件定义:
/nfs *(rw,no_root_squash,sync) hostname : testcom #service portmap start #service nfslock start #service nfs start
2.在AIX 端检查Linux的nfs 共享目录有没有存在:whoselife@/data>showmount -e testcom
*:/nfs 如果AIX上portmap 没有启动,运行showmount -e会出现如下报错:whoselife@/data>showmount -e whoselife: RPC: 1832-019 Program not registered
如果出现1832-019的报错需要重新启动portmap 和nfs 的服务:
whoselife@/data>stopsrc -g nfs 0513-044 The biod Subsystem was requested to stop. 0513-044 The nfsd Subsystem was requested to stop. 0513-044 The rpc.mountd Subsystem was requested to stop. 0513-044 The rpc.lockd Subsystem was requested to stop. 0513-044 The rpc.statd Subsystem was requested to stop.whoselife@/data>stopsrc -s portmap 0513-044 The portmap Subsystem was requested to stop.whoselife@/data>startsrc -s portmap 0513-059 The portmap Subsystem has been started. Subsystem PID is 954432.whoselife@/data>startsrc -g nfs 0513-059 The biod Subsystem has been started. Subsystem PID is 344286. 0513-059 The nfsd Subsystem has been started. Subsystem PID is 618542. 0513-059 The rpc.mountd Subsystem has been started. Subsystem PID is 975026. 0513-059 The nfsrgyd Subsystem has been started. Subsystem PID is 380956. 0513-059 The gssd Subsystem has been started. Subsystem PID is 380958. 0513-059 The rpc.lockd Subsystem has been started. Subsystem PID is 380960. 0513-059 The rpc.statd Subsystem has been started. Subsystem PID is 143412.whoselife@/data>showmount -e testcom *:/nfs
这样就成功检测到了共享文件。
3. 检查/etc/hosts ,确定服务器和客户机的主机名地址可以正确解析。
whoselife@/>traceroute testcom trying to get source for testcom source should be 9.123.x.y traceroute to testcom (9.123.a.b) from 9.123.x.4 (9.123.x.y), 30 hops max outgoing MTU = 1500 1 9.123.x.4 (9.123.x.4) 1 ms 1 ms 1 ms 2 testcom (9.123.130.34) 1 ms 1 ms 1 mswhoselife@/>host 9.123.a.b testcom is 9.123.a.bwhoselife@/>host 9.123.x.y whoselife is 9.123.x.y
如果检查到0827-803的错误,需要在服务器和客户机的/etc/hosts加入两边正确的主机名和ip地址。whoselife@/data>host 9.123.131.147
host: 0827-803 Cannot find address 9.123.131.147.
4。挂载Linux nfs 文件系统到AIX 的目录/data/wuxfwhoselife@/>mount testcom:/nfs /data/wuxf
如果出现下列不能挂载的问题:whoselife@/>mount testcom:/nfs/ data/wuxf
mount: giving up on: testcom:/nfs/ vmount: Not owner
需要检查nfso -a:whoselife@/data>nfso -a | grep nfs_use_reserved_ports
nfs_use_reserved_ports = 0
默认情况,AIX系统执行mount命令请求时并不使用预先定义好的端口,设置nfs_use_reserved_ports后可使用1024以下的预定义端口。whoselife@/>nfso -o nfs_use_reserved_ports=1
Setting nfs_use_reserved_ports to 1
这样AIX 就可以正确挂载Linux 的nfs 共享文件了
AIX5.3 Linux
问题描述
mount linux nfs 服务器时,报错如下:
nfsmnthelp: invalid option insecure ignored mount: 1831-011 access denied for 10.1.1.74:/tpdata/test mount: 1831-008 giving up on: 10.1.1.74:/tpdata/test The file access permissions do not allow the specified action.
解答
1.检查域名解析,一切正常
2.在linux服务器上执行:showmount -e,结果如下:
[root@rigelrh ~]# more /etc/exports /natsys_net/ *(sync,no_root_squash,rw) /natsys_net/products_rigelrh *(sync,no_root_squash,rw) /natsys_net/archives_rigelrh *(sync,no_root_squash,rw) /natsys_net/archives_rigelrh/cvs *(sync,no_root_squash,rw) #/natsys_net/backup *(sync,no_root_squash,rw) /natsys_net/backup/WCS_rigelrh *(sync,no_root_squash,rw) /natsys_net/archives_rigelrh/admin *(sync,no_root_squash,rw) /natsys_net/archives_rigelrh/integ *(sync,no_root_squash,rw 3.nfso -a|grep port 返回结果 portcheck = 0 nfs_use_reserved_ports = 0
4.执行命令:nfso -o nfs_use_reserved_ports=1
问题解决,mount成功.
默认情况,AIX系统执行mount命令请求时并不通过预先定义好的端口.即用nfso -a查询出的
nfs_use_reserved_ports = 0.
要解决此类问题,可以在Linux exports文件中做如下修改:
/natsys_net/archives_rigelrh *(sync,insecure,no_root_squash,rw)
或者可以在每个AIX 客户端做如下修改:
nfso -o nfs_use_reserved_ports=1
相关补丁:IY81908: TRAILING COLON CAN ALLOW HOSTS UNRESTRICTED ACCESS TO NFS