NAME
inidhcp - Works with DHCP information stored in INI files.
SYNOPSIS
inidhcp -c <config> -a rm -s <scope>
inidhcp -c <config> -a gen [-V <vars section>]
inidhcp -c <config> -a add -s <scope> -m <mask> [-g <gateways>] [-t <TFTP server>] [-n <NTP servers>] [-B <broadcast>] [-M <MTU>] [-d <DNS servers>] [-w <URL>] [-l <time>] [-b <bootfile>] [-R <IP IP>]
inidhcp -c <config> -a check
ACTIONS
These are specified via the -a flag.
rm
This removes the scope specified via -s <scope>.
gen
This generates the ISC DHCPD config.
You can specify the vars sections in the INI file to use via them the -V flag.
add
This adds a new subnet. The minimum required values are -m <mask> and -s <scope>.
The following are additional flags that can be used with this.
B<-g> <gateways>
B<-t> <TFTP server>
B<-n> <NTP servers>
B<-B> <broadcast>
B<-M> <MTU>
B<-d> <DNS servers>
B<-w> <URL>
B<-l> <time>
B<-b> <bootfile>
B<-R> <IP IP>
FLAGS
-a <action>
The action to perform.
xs=head2 -c <config>
The config file to use.
-g <IPs>
Comma seperated list of gateways.
-s <scope>
The base IP of the subnet.
-m <mask>
Subnet mask
-t <IP>
TFTP server
-n <IPs>
Comma seperated list of NTP servers.
-b <file>
The name of the boot file.
-B <IP>
Broadcast address.
-R <IP IP>
The range to use.
-d <IPs>
Comma seperated list of DNS servers.
-M <MTU>
The MTU for the subnet.
-w <URL>
The web proxy for the subnet.
-l <time>
The lease time.
-r <path>
Root path for netboot via NFS.
-V <vars section>
The variable section to pass to generator for use in the templates.
CONFIGURATION
Below is a example config in which inidhcp is ran out of the current directory.
dir=./
[generator]
header=header
footer=footer
output=output
SECTIONS
ROOT
directory
This is the directory that has the ini.dhcp files in it.
generator
header
This is the header template to use. Template is used for templating.
footer
This is the footer template to use. Template is used for templating.
output
This is the file to output to.
EXAMPLE TEMPLATES
Header...
default-lease-time 600;
max-lease-time 7200;
ddns-update-style none;
authoritative;
option web-proxy code 252 = text;
log-facility local7;
Footer...