yp_host - update NIS "hosts" database
yp_host -r -h host [ -n net [ -m mask ] ] [ -a aliases ]
yp_host -c -h host -w newname [ -a aliases ]
yp_host -d -h host
yp_host is the user command to update the NIS hosts database directly
from a client workstation. yp_host uses the ypupdated(1M) service on the
NIS master to update the NIS hosts database. The single-threaded nature
of ypupdated(1M) guarantees the database will remain consistent even when
multiple updates are attempted at the same time.
Users can add, change, or delete an entry to the database. As long as
the hostname is not used in the current database, there are no
restrictions for creating an entry. However, to modify or delete an
entry, users are prompted for the root password of the NIS master.
-c Change an existing entry.
-d Delete an entry.
-r Register the hostname in the NIS hosts database.
-h host Use host as the key when updating the hosts database.
-n net Specifies the network that host will be on. This parameter
should follow the ``dot'' notation for Internet addresses
(see inet(3N)). If -m is used, the net should be a fourbyte
Internet address. If -m is not used, the net should be
an Internet network number.
-m mask Specifies the network mask, as described in ifconfig(1M).
This parameter, when logically-ANDed with net, represents
the target Internet subnet number.
-a aliases Specifies the aliases of the new host. Multiple aliases
should be surrounded with double-quote (") marks and
separated with spaces.
-w newname Modifies the entry to use newname as the new key for the
yp_host -a -h bonnie -n 192.26.88 -a "jake clyde"
Creates an entry on the NIS master for bonnie. The network that the new
IP address will be using is "192.26.88".
yp_host -a -h bonnie -n 126.96.36.199 -m 0xffffffc0 -a "jake clyde"
The subnet that the new IP address will be on is "188.8.131.52".
/usr/include/rpcsvc/ypclnt.h error code listing
PPPPaaaaggggeeee 2222 [ Back ]