│ 客户端 │ │ 主服务端 │ │ stub │ │ stub │ └—┬——┘ └┬————┘ 系统呼叫 │ 《 │ 《 (2) │ │ (9) (7) │ │ (4) 》 │ 》 │ ┌———┴┐ (8) ┌————┴┐ │network │ <——————┤ network │ │routines├——————> │ routines │ └————┘ (3) └—————┘ 本地系统核心 网路通讯 远端系统核心
(1) client 送出讯息,请求服务 (2) client stub (客户株) 把client 送出的参数转换成XDR---标准资料 格式并用系统呼叫(system call) 把讯息送到网路上 (3) 讯息经过网路送达远端主机系统 (4) 远端主机将接受到的讯息传给server stub (服务站株) (5) 把XDR形式的资料,转换成符合主机端的格式,取出client发出的服务 请求参数,送给server (6) -- (10) 则是逆向而行 , server 送出服务给 client
□ rc.local 启动守护程式
一个NFS server 要 inet , portmap , nfs , mount 此四个守护程式,保 持在背景执行的状态下才能运作. (if running NIS must add ypbind daemon)
◆ 当启动 NFS file server 时,
the /etc/rc.local script 会做如下的动作 1. 执行exportfs , 读取server's /etc/exports 告诉kernel 所要输出的file hierarchies 和 存取的权限 ( exportfs -a ) 2. 启动 rpc.mountd daemon 和 nfsd daemon (通常是 8 个) ( rpc.mountd -n nfsd 8 & echo -n 'nfsd' )
◆ 当启动 NFS client 时
rc.local 会做如下的动作 1. 启动 boid daemons 处理读写的程序 (biod 8 echo -n ' biod' ) 2. 执行 mount -vat nfs 读取client's /etc/fstab 并且 mount 所 有属於 NFS-type 的files
□ NFS daemons (守护程式) 的功用
nfsd, biod, rpc.mountd, inetd, portmap 都可在/u上一页 [1] [2] [3] [4] [5] [6] [7] [8] [9] 下一页 |