2008-01-07 17:37:19 +00:00
=head1 NAME
2008-03-14 20:54:31 +00:00
B<makedhcp> - Creates new dhcp configuration files and updates live dhcp configuration using omapi.
2008-01-07 17:37:19 +00:00
=head1 SYNOPSIS
2008-08-02 16:18:07 +00:00
B<makedhcp> B<-n>
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
B<makedhcp> B<-a>
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
B<makedhcp> B<-a -d>
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
B<makedhcp> B<-d> I<noderange>
2008-03-14 20:54:31 +00:00
B<makedhcp> I<noderange> [B<-s> I<statements>]
2008-01-07 17:37:19 +00:00
2011-01-05 08:11:32 +00:00
B<makedhcp> I<noderange> B<--hfi>
2008-08-02 16:18:07 +00:00
B<makedhcp> [I<-h|--help>]
2008-01-07 17:37:19 +00:00
=head1 DESCRIPTION
2008-08-02 16:18:07 +00:00
The B<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 B<-n> option, B<makedhcp> will create a dhcpd.conf file, including certain general parameters
such as a dynamic range and omapi configuration.
With a noderange or the B<-a> option, makedhcp will inject configuration data (via omapi) pertinent to the
specified nodes that immediately takes effect without a restart of DHCP.
2008-01-07 17:37:19 +00:00
2008-08-02 16:18:07 +00:00
If the B<-d> flag is used with the B<-a> flag then it will delete all nodes' dhcp host definitions.
The B<-d> flag followed by a I<noderange> will delete the dhcp host definitons for the noderange.
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
The B<makedhcp> command also uses the following attributes from the xCAT database:
B<site.dhcpinterfaces>, B<site.domain>, B<networks.dynamicrange>, B<networks.dhcpserver>. See
the xcatdb man page for details about the database attributes.
2008-01-07 17:37:19 +00:00
2009-03-08 19:31:44 +00:00
Note: This command is not supported for AIX clusters.
2008-01-07 17:37:19 +00:00
2008-03-14 20:54:31 +00:00
=head1 OPTIONS
2008-01-07 17:37:19 +00:00
2008-08-02 16:18:07 +00:00
=over 12
=item B<-n>
Create a new dhcpd.conf file with a network statement for each network dhcpd should listen on.
The B<makedhcp> command will automatically restart dhcpd after this operation.
=item B<-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.
=item I<noderange>
Add the specified nodes to the DHCP server configuration.
=item [B<-s> I<statements>]
2008-01-07 17:37:19 +00:00
2008-08-02 16:18:07 +00:00
For the input noderange, the argument will be interpreted like dhcpd.conf text.
2008-01-07 17:37:19 +00:00
2008-08-02 16:18:07 +00:00
=item B<-a -d>
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
Delete all nodes from the DHCP server configuration.
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
=item B<-d> I<noderange>
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
Delete all nodes in the noderange from the DHCP server configuration.
2011-01-05 08:11:32 +00:00
=item B<--hfi> I<noderange>
Add the specified nodes to the DHCP server configuration with HFI device type.
2008-08-02 16:18:07 +00:00
=item B<-h>
Display usage message.
=back
2008-01-07 17:37:19 +00:00
=head1 RETURN VALUE
0 The command completed successfully.
1 An error has occurred.
2008-08-02 16:18:07 +00:00
2008-01-07 17:37:19 +00:00
=head1 EXAMPLES
2008-08-02 16:18:07 +00:00
=over 3
=item 1.
Add the network definitions to DHCP by updating the dhcpd.conf file:
makedhcp -n
=item 2.
2008-01-07 17:37:19 +00:00
2008-08-02 16:18:07 +00:00
Define all nodes to the dhcp server:
2008-01-07 17:37:19 +00:00
2008-08-02 16:18:07 +00:00
makedhcp -a
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
=item 3.
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
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).
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
makedhcp node5 -s 'option root-path \"172.16.0.1:/install/freebsd6.2/x86_64\";'
2008-03-27 13:55:50 +00:00
2008-08-02 16:18:07 +00:00
=back
2008-03-27 13:55:50 +00:00
2008-01-07 17:37:19 +00:00
2008-08-02 16:18:07 +00:00
=head1 SEE ALSO
2008-01-07 17:37:19 +00:00
2008-08-02 16:18:07 +00:00
L<noderange(3)|noderange.3>
2008-01-07 17:37:19 +00:00