dhcpc.conf -- configuration file for the DHCP client daemon


# comment
[ command:flag:path:arguments... ]
[ command_timeout:seconds ]
[ debug:debug_level ]
[ dynamic_dns:boolean ]
[ lease_time:seconds ]
[ gratuitous:boolean ]
[ hostname:name ]
[ interface:network interface ]
[ max_message_size:bytes ]
[ param_req:option [option ...]
[ request_address:IP_address ]
[ select_timeout:seconds ]
[ user_id:user_class ]
[ vendor_id:vendor_classvendor:vendor_class:number:format:name... ]


The DHCP client configuration file, /etc/dhcpc.conf, defines how dhcpc(ADMN) will operate and which DHCP options it will request.

The following keyword lines are recognized:

Specify a command that dhcpc will run to configure the system. If flag is Y or y, the command path is run. If flag is set to any other character, the command is not run. The final field is used to define any arguments required by the command. The commands are run in the order that they are defined. A set of commands exists in /etc/dhcpc.d.

Specify how long dhcpc should wait for a re-run command to execute. If the time period expires without the command exiting, its process is killed. When dhcpc starts up, it ignores the value of command_timeout and waits indefinitely for a command to exit.

Set the debug level. The value of debug_level can be in the range 0 (no debug messages) to 4. The default value is 1 which reports startup messages.

Control whether dhcpc will request that the DNS master server delete the client's A (name to address translation) and PTR (address to name translation) records when dhcpc exits. If the value of dynamic_dns is 1, a request is sent. By default, no request is sent.

This keyword is used in conjunction with the command /etc/dhcpc.d/ which requests that the DNS master server update the client's A and PTR records. The client's name is the same as that obtained using the command uname -n.

WARNING: No authentication of the client is performed: this is a potential security hole.

The design and implementation of dynamic DNS is subject to change. In future releases, it is likely that the DHCP server will notify the DNS server on behalf of the client.

Specify a preferred lease time. The DHCP server will assign a lease time that is the minimum of the preferred lease time and the maximum lease time.

Control whether the client will broadcast a gratuitous ARP request on accepting an offered IP address. This allows other systems on the network to update the IP address that is associated with the client's hardware MAC address in their ARP cache. A value of 1 enables the broadcasting of a gratuitous ARP request (the default behavior). A value of 0 disables it.

Specify a client ID the DHCP server will use to identify your server as a DHCP client.

interface:network interface
Specify the network interface the DHCP cleint daemon will use. This option is useful if you have more than one network interface.

Specify the maximum size (in bytes) that the client will allow for DHCP packets received from a server. By default, no maximum size is specified.

param_req:option [option ...]
Specify the DHCP options that the client would like the server to provide. Received options are written to the file /var/adm/dhcpc.opt. Multiple param_req definitions are allowed.

Specify an IP address with which the client would like to be configured by the DHCP server.

Specify a selection timeout period in seconds for offers from DHCP servers.

Select a complete set of user options with which the client should be configured. Received options are written to the file /var/adm/dhcpc.opt.

Select a complete set of vendor options with which the client should be configured. The options are written as raw data to the file /var/adm/dhcpc.eopt so that they can processed according to rules specified by vendor keyword definitions.

Read a vendor-specific option identified by its number (for example, ``12'' for vendor-specific option ``option012'') from the file /var/adm/dhcpc.eopt, and write an entry for it to /var/adm/dhcpc.opt using the specified name and format. One of the following conversion formats may be specified:

boolean value: 0 for false, 1 for true

signed 8-bit integer value

list of signed 8-bit integer values

IP address in dotted decimal notation

list of IP addresses in dotted decimal notation

signed 32-bit integer value

list of signed 32-bit integer values

signed 16-bit integer value

list of signed 16-bit integer values

string of text characters
Lines beginning with the character ``#'' are treated as comments.


DHCP client configuration file

DHCP server configuration file

configuration commands that may be used by dhcpc

DHCP options obtained from server in a form suitable for shell scripts

raw encapsulated DHCP vendor options obtained from server

DHCP information obtained from server in a form suitable for shell scripts

See also

dhcpc(ADMN), dhcpd(ADMN), dhcpd.conf(SFF)


The following example dhcpc.conf file requests the vendor-specific option ``option001'' from the vendor class ``acme_opts''. This option is converted to a list of IP addresses and is given the name ``DNS_SEARCH''.
   # Set a debugging level of 4 (highest)

# Request an IP address request_address:

# Request DHCP options param_req:subnet_mask routers param_req:hostname domain_name dns_servers ntp_servers param_req:nis_domain nis_servers param_req:nb_name_servers nb_dd_servers nb_node_type nb_scope param_req:time_offset

# Request options from vendor class acme_opts vendor_id:acme_opts

# Convert option001 to a shell variable with a string value vendor:acme_opts:1:STRING:DNS_SEARCH

# Specify configuration commands to be run command:y:/etc/dhcpc/opt: command:y:/etc/dhcpc/info:

# Set search keyword in /etc/resolv.conf using DNS_SEARCH command:y:/usr/local/acme/set_search:-f /etc/resolv.conf

# Uncomment the following lines to update the client's DNS entry dynamically # dynamic_dns:1 # command:y:/etc/dhcpc/dupdate:

© 2003 Caldera International, Inc. All rights reserved.
SCO OpenServer Release 5.0.7 -- 11 February 2003