Processes lock requests.
/usr/sbin/rpc.lockd [ -t TimeOut ] [ -g GracePeriod ] [ -d debug ] [ -x xnfs ] [ -T RetransmissionsTimeout ] [ number of server ]
The lockd daemon processes lock requests that are either sent locally by the kernel or remotely by another lock daemon. The lockd daemon forwards lock requests for remote data to the server site lock daemon through the RPC package. The lockd daemon then asks the statd (status monitor) daemon for monitor service. The reply to the lock request is not sent to the kernel until both the statd daemon and the server site lockd daemon reply. The statd daemon should always be started before the lockd daemon.
If either the status monitor or the server site lock daemon is unavailable, the reply to a lock request for remote data is delayed until all daemons become available.
When a server recovers, it waits for a grace period for all client site lockd daemons to submit reclaim requests. The client site lockd daemons, on the other hand, are notified of the server recovery by the statd daemon. These daemons promptly resubmit previously granted lock requests. If a lockd daemon fails to secure a previously granted lock at the server site, the lockd daemon sends a SIGLOST signal to the process.
startsrc -s rpc.lockd
stopsrc -s rpc.lockd
chssys -s rpc.lockd Parameters...
The status monitor maintains information about the location of connections as well as the status in the /var/statmon/sm directory, the /var/statmon/sm.bak file, and the /var/statmon/state file. When restarted, the statd daemon queries these files and tries to reestablish the connection it had prior to termination. To restart the statd daemon, and subsequently the lockd daemon, without prior knowledge of existing locks or status, delete these files before restarting the statd daemon.
lockd 16001/tcp
lockd 16001/udp
Item | Description |
---|---|
-d debug | Specifies the debug level of the rpc.statd daemon. By default, the debug level is disabled. |
-g GracePeriod | Uses the GracePeriod variable to specify the amount of time, in seconds, that the lockd daemon should wait for reclaim requests for previously granted locks. The default value of the GracePeriod variable is 45 seconds. |
-T RetransmissionsTimeout | Specifies the timeout for one-way RPC connections. One-way RPC connections stay valid for RetransmissionsTimeout number of seconds. If this variable is set to 0, then there is no client cache for one-way RPC calls. The default value for the RetransmissionsTimeout variable is 300 seconds. |
-t TimeOut | Uses the TimeOut variable to specify the interval between retransmitting lock requests to the remote server. The default value for the TimeOut variable is 15 seconds. |
-x xnfs | Specifies if the rpc.lockd daemon needs to follow the xnfs specification. By default, this flag is turned off. |
Item | Description |
---|---|
number of server | Specifies the number of daemons to start. |
/usr/sbin/rpc.lockd -g 60
In
this example, the grace period is set for 60 seconds./usr/sbin/rpc.lockd -t 30
In this example,
the retransmissions occur after 30 seconds.Item | Description |
---|---|
/etc/services | Contains lockd parameter information entries. |