# Dhcpd

BIND dhcp 3 server configuration module for Augeas

Author: Francis Giraldeau francis..nosp@m.giraldeau@usherbr.nosp@m.ooke.ca

Summary

Dhcpd | BIND dhcp 3 server configuration module for Augeas
Reference | Reference: manual of dhcpd.conf and dhcp-eval Follow dhclient module for tree structure
License | This file is licensed under the GPL.
Lens Usage | Sample usage of this lens in augtool
Configuration files | This lens applies to /etc/dhcpd3/dhcpd.conf.

### Reference

Reference: manual of dhcpd.conf and dhcp-eval Follow dhclient module for tree structure

### License

This file is licensed under the GPL.

### Lens Usage

Sample usage of this lens in augtool

Directive without argument. Set this dhcpd server authoritative on the domain.

>     clear /files/etc/dhcp3/dhcpd.conf/authoritative

Directives with integer or string argument. Set max-lease-time to one hour:

>     set /files/etc/dhcp3/dhcpd.conf/max-lease-time 3600

Options are declared as a list, even for single values. Set the domain of the network:

>     set /files/etc/dhcp3/dhcpd.conf/option/domain-name/arg example.org

Set two name server:

>     set /files/etc/dhcp3/dhcpd.conf/option/domain-name-servers/arg[1] foo.example.org
>     set /files/etc/dhcp3/dhcpd.conf/option/domain-name-servers/arg[2] bar.example.org

#### Create the subnet 172.16.0.1 with 10 addresses

>     clear /files/etc/dhcp3/dhcpd.conf/subnet[last() + 1]
>     set /files/etc/dhcp3/dhcpd.conf/subnet[last()]/network 172.16.0.0
>     set /files/etc/dhcp3/dhcpd.conf/subnet[last()]/netmask 255.255.255.0
>     set /files/etc/dhcp3/dhcpd.conf/subnet[last()]/range/from 172.16.0.10
>     set /files/etc/dhcp3/dhcpd.conf/subnet[last()]/range/to 172.16.0.20

Create a new group “foo” with one static host. Nodes type and address are ordered.

>     ins group after /files/etc/dhcp3/dhcpd.conf/subnet[network='172.16.0.0']/*[last()]
>     set /files/etc/dhcp3/dhcpd.conf/subnet[network='172.16.0.0']/group[last()]/host foo
>     set /files/etc/dhcp3/dhcpd.conf/subnet[network='172.16.0.0']/group[host='foo']/host/hardware/type "ethernet"
>     set /files/etc/dhcp3/dhcpd.conf/subnet[network='172.16.0.0']/group[host='foo']/host/hardware/address "00:00:00:aa:bb:cc"
>     set /files/etc/dhcp3/dhcpd.conf/subnet[network='172.16.0.0']/group[host='foo']/host/fixed-address 172.16.0.100

### Configuration files

This lens applies to /etc/dhcpd3/dhcpd.conf. See filter.

Close