NAME

makedhcp - Creates new dhcp configuration files and updates live dhcp configuration using omapi.


SYNOPSIS

makedhcp -n

makedhcp -a

makedhcp -a -d

makedhcp -d noderange

makedhcp noderange [-s statements]

makedhcp [-h|--help]


DESCRIPTION

The makedhcp command configures the DHCP daemon on the local system so that xCAT can manage the nodes of the cluster during discovery, full install, diskless booting, and normal booting. With the -n option, makedhcp will create a dhcpd.conf file, including certain general parameters such as a dynamic range and omapi configuration. With a noderange or the -a option, makedhcp will inject configuration data (via omapi) pertinent to the specified nodes that immediately takes effect without a restart of DHCP.

If the -d flag is used with the -a flag then it will delete all nodes' dhcp host definitions. The -d flag followed by a noderange will delete the dhcp host definitons for the noderange.

The makedhcp command also uses the following attributes from the xCAT database: site.dhcpinterfaces, site.domain, networks.dynamicrange, networks.dhcpserver. See the xcatdb man page for details about the database attributes.

Note: This command is not supported for AIX clusters.


OPTIONS

-n

Create a new dhcpd.conf file with a network statement for each network dhcpd should listen on. The makedhcp command will automatically restart dhcpd after this operation.

-a

Define all nodes to the DHCP server. (Will only add nodes that can be reached, network-wise, by this DHCP server.) The dhcpd daemon does not have to be restarted after this.

noderange

Add the specified nodes to the DHCP server configuration.

[-s statements]

For the input noderange, the argument will be interpreted like dhcpd.conf text.

-a -d

Delete all nodes from the DHCP server configuration.

-d noderange

Delete all nodes in the noderange from the DHCP server configuration.

-h

Display usage message.


RETURN VALUE

0 The command completed successfully.

1 An error has occurred.


EXAMPLES

  1. Add the network definitions to DHCP by updating the dhcpd.conf file:

     makedhcp -n
  2. Define all nodes to the dhcp server:

     makedhcp -a
  3. Will cause dhcp on the next request to set root-path appropriately for only node5. Note some characters (e.g. ``) must be doubly escaped (once for the shell, and once for the OMAPI layer).

     makedhcp node5 -s 'option root-path  \"172.16.0.1:/install/freebsd6.2/x86_64\";'


SEE ALSO

noderange(3)