bootp(1Mtcp)


bootp -- remote bootstrap configuration client

Synopsis

bootp [-a interface_name] [-c number_of_tries] [-d] device [hostname]

Description

The bootp command gives client hosts the ability to obtain network configuration information from a central Internet Bootstrap Protocol (BOOTP) server (see bootpd(1Mtcp)).

Files

/etc/inet/bootptab
database file read by bootpd

Usage

bootp can be run at system installation time, or in cases where the characteristics of the network change (for example, when a new domain name server is added) and the client's configuration files must be updated to reflect the changes to the network.

bootp can be run by a privileged user only. When invoked, bootp broadcasts a BOOTP request containing the hardware address of the Ethernet interface interface_name through the Ethernet device device. bootpd responds to the request on the BOOTP server. bootp interprets the response and outputs attribute values contained in the response as shell variable assignments. If a randomly varied time-out period expires without a response, bootp resends the request and increases the time-out period. The request is retried until number_of_tries (default 5) is reached.

To avoid the possibility of exhausting the space in the 64 byte vend area of the request/response packet, the host name and domain name attributes are obtained via reverse DNS lookup. The local hosts(4tcp) file and the resolv.conf(4tcp) file are not consulted for this operation; any DNS servers specified in the vend area are consulted instead.

The BOOTP attributes that are currently used, together with the shell variables output by bootp, are summarized in the following tables:

RFC 951 field name BOOTP server attribute name BOOTP client shell variable
file bf INET_BOOT_FILE_NAME
ciaddr ip INET_YOUR_IP_ADDRESS
siaddr sa INET_SERVER_IP_ADDRESS
vend - see following table

 
 ----------------------------------------------------------------------- 
| RFC 951 field name|  BOOTP server   |  BOOTP client shell variable   | 
|                   |  attribute name |                                | 
|-------------------|-----------------|--------------------------------| 
| file              |  bf             |  INET_BOOT_FILE_NAME           | 
|-------------------|-----------------|--------------------------------| 
| ciaddr            |  ip             |  INET_YOUR_IP_ADDRESS          | 
|-------------------|-----------------|--------------------------------| 
| siaddr            |  sa             |  INET_SERVER_IP_ADDRESS        | 
|-------------------|-----------------|--------------------------------| 
| vend              |  -              |  see following table           | 
|-------------------|-----------------|--------------------------------| 

RFC 1533 vendor extension field BOOTP server attribute name BOOTP client shell variable
Ethernet Frame Type T36 INET_ETHER_ENCAPSULATION
NIS Domain Name T40 INET_NIS_DOMAIN_NAME
Domain Name dn INET_DOMAIN_NAME
Domain Name Server ds INET_DNS_SERVER[instance]
Router gw INET_ROUTER[instance]
Host Name hn INET_HOSTNAME
Subnet Mask sm INET_SUBNET_MASK
Time Offset to INET_TIME_OFFSET
Time Server ts INET_TIME_SERVER[instance]

 
 ------------------------------------------------------------------------ 
| RFC 1533 vendor    |  BOOTP server   |  BOOTP client shell variable   | 
| extension field    |  attribute name |                                | 
|--------------------|-----------------|--------------------------------| 
| Ethernet Frame Type|  T36            |  INET_ETHER_ENCAPSULATION      | 
|--------------------|-----------------|--------------------------------| 
| NIS Domain Name    |  T40            |  INET_NIS_DOMAIN_NAME          | 
|--------------------|-----------------|--------------------------------| 
| Domain Name        |  dn             |  INET_DOMAIN_NAME              | 
|--------------------|-----------------|--------------------------------| 
| Domain Name Server |  ds             |  INET_DNS_SERVER[instance]     | 
|--------------------|-----------------|--------------------------------| 
| Router             |  gw             |  INET_ROUTER[instance]         | 
|--------------------|-----------------|--------------------------------| 
| Host Name          |  hn             |  INET_HOSTNAME                 | 
|--------------------|-----------------|--------------------------------| 
| Subnet Mask        |  sm             |  INET_SUBNET_MASK              | 
|--------------------|-----------------|--------------------------------| 
| Time Offset        |  to             |  INET_TIME_OFFSET              | 
|--------------------|-----------------|--------------------------------| 
| Time Server        |  ts             |  INET_TIME_SERVER[instance]    | 
|--------------------|-----------------|--------------------------------| 
Note that, in cases where reverse DNS lookup is used, bootp outputs the INET_HOSTNAME and INET_DOMAIN_NAME variables.

The attribute names shown in these tables are implemented as parameter declarations in the BOOTP server configuration file /etc/inet/bootptab (see bootptab(4tcp)).

Options

bootp takes the following options:

-a interface_name
Causes the Ethernet interface interface_name to be reconfigured with an address of zero. interface_name should be the name of the interface associated with the Ethernet device. This allows bootp to receive a response even if it is directed to a different IP address because the current IP address does not match the BOOTP server's configuration. To avoid an error condition, do not invoke bootp with the -a option from a multi-user system when interface_name is in use.

-c number_of_tries
Specifies the number of unanswered BOOTP requests to send before giving up. The default value is 5.

-d
Do not use DNS to obtain the host name and the domain name.

Exit codes

On success, bootp returns zero.

On a timeout, it returns 254 and prints the message INET_BOOTP_TIMEDOUT=yes to the standard error output.

References

bootpd(1Mtcp), bootptab(4tcp), ifconfig(1Mtcp)

RFC 951, RFC 1533

Examples

A sample client host entry in /etc/inet/bootptab might look like this:
   ..default:\ 
   	:ds=128.212.64.29 128.212.64.5 128.212.64.2:\ 
   	:ts=128.212.64.29:\ 
   	:gw=128.212.64.29:\ 
   	:sm=255.255.255.0:\ 
   	:vm=auto:to=auto: 
   mcfeely:ht=1:ha=0080298356B4:ip=128.212.64.146:tc=default: 

The ht (hardware address type) and ha (hardware address) attributes are used by the BOOTP server to locate the proper entry in its configuration file. Note that this client host forces the BOOTP server to choose an address by always setting the ciaddr field in the request to zero. The value of the bootp argument hostname is placed in the request vend area ``Host Name'' field so that a server may choose to respond based on this hostname if a lookup by hardware address fails. The Class Identifier of ``UnixWare'' is also provided in the request to identify the client as a UnixWare system.


30 January 1998
© 1998 The Santa Cruz Operation, Inc. All rights reserved.