source: networking/connect/kea.xml@ baf6d5a0

12.0 12.1 12.2 gimp3 kea ken/TL2024 ken/tuningfonts lazarus plabs/newcss python3.11 rahul/power-profiles-daemon renodr/vulkan-addition trunk xry111/for-12.3 xry111/llvm18 xry111/spidermonkey128 xry111/xf86-video-removal
Last change on this file since baf6d5a0 was baf6d5a0, checked in by Thomas Trepl <thomas@…>, 16 months ago

'Downgrade' to stable 2.2.0 as former used 2.3.7 is a development version

  • Property mode set to 100644
File size: 16.4 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY kea-download-http "https://downloads.isc.org/isc/kea/&kea-dhcp-version;/kea-&kea-dhcp-version;.tar.gz">
8 <!ENTITY kea-download-ftp "ftp://ftp.isc.org/isc/kea/&kea-dhcp-version;/kea-&kea-dhcp-version;.tar.gz">
9 <!ENTITY kea-md5sum "64c75b4cdbe7b1208ab0929865d2bd12">
10 <!ENTITY kea-size "9.5 MB">
11 <!ENTITY kea-buildsize "1.9 GB">
12 <!ENTITY kea-time "5 SBU"> <!-- CHECK -->
13 <!ENTITY kea-arm-vers "2.2.0">
14]>
15
16<sect1 id="kea" xreflabel="KEA-&kea-dhcp-version;">
17 <?dbhtml filename="kea.html"?>
18
19
20 <title>Kea &kea-dhcp-version;</title>
21
22 <indexterm zone="kea">
23 <primary sortas="a-KEA">Kea</primary>
24 </indexterm>
25
26 <sect2 role="package">
27 <title>Introduction to ISC Kea</title>
28
29 <para>
30 The <application>ISC Kea</application> package contains the
31 server programs for DHCP. It is the successor of the
32 <xref linkend="dhcp"/> server which is end-of-life since December 2022.
33 </para>
34
35 &lfs113_checked;
36
37 <bridgehead renderas="sect3">Package Information</bridgehead>
38 <itemizedlist spacing="compact">
39 <listitem>
40 <para>
41 Download (HTTP): <ulink url="&kea-download-http;"/>
42 </para>
43 </listitem>
44 <listitem>
45 <para>
46 Download (FTP): <ulink url="&kea-download-ftp;"/>
47 </para>
48 </listitem>
49 <listitem>
50 <para>
51 Download MD5 sum: &kea-md5sum;
52 </para>
53 </listitem>
54 <listitem>
55 <para>
56 Download size: &kea-size;
57 </para>
58 </listitem>
59 <listitem>
60 <para>
61 Estimated disk space required: &kea-buildsize;
62 </para>
63 </listitem>
64 <listitem>
65 <para>
66 Estimated build time: &kea-time;
67 </para>
68 </listitem>
69 </itemizedlist>
70
71 <bridgehead renderas="sect3">Kea Dependencies</bridgehead>
72
73 <bridgehead renderas="sect4">Required</bridgehead>
74 <para role="required">
75 <xref linkend="boost"/>,
76 <xref linkend="log4cplus"/>
77 </para>
78
79 <bridgehead renderas="sect4">Optional for documentation</bridgehead>
80 <para role="optional">
81 <xref linkend="doxygen"/>,
82 <xref linkend="graphviz"/>,
83 <xref linkend="mitkrb"/>,
84 <xref linkend="sphinx_rtd_theme"/>
85 </para>
86
87 <bridgehead renderas="sect4">Optional database backends</bridgehead>
88 <para role="optional">
89 <xref linkend="mariadb"/> or <ulink url="https://www.mysql.com/">MySQL</ulink>,
90 <xref linkend="postgresql"/>
91 </para>
92
93 <para condition="html" role="usernotes">User Notes:
94 <ulink url="&blfs-wiki;/kea"/>
95 </para>
96 </sect2>
97
98 <sect2 role="kernel" id="kea-dhcp-kernel">
99 <title>Kernel Configuration</title>
100
101 <para>
102 You must have Packet Socket support. IPv6 support is optional.
103 </para>
104
105<screen><literal>[*] Networking support ---&gt; [CONFIG_NET]
106 Networking options ---&gt;
107 &lt;*&gt; Packet socket [CONFIG_PACKET]
108 &lt;*&gt; The IPv6 Protocol ---&gt; [CONFIG_IPV6]</literal></screen>
109 <indexterm zone="kea kea-dhcp-kernel">
110 <primary sortas="k-KEA">Kea</primary>
111 </indexterm>
112
113 </sect2>
114
115 <sect2 role="installation">
116 <title>Installation of ISC Kea DHCP</title>
117
118 <para>
119 Install <application>ISC Kea DHCP</application> by running
120 the following commands:
121 </para>
122
123<screen><userinput>./configure --prefix=/usr \
124 --sysconfdir=/etc \
125 --docdir=/usr/share/doc/kea-&kea-dhcp-version; \
126 --localstatedir=/var \
127 --enable-shell \
128 --with-openssl &amp;&amp;
129make</userinput></screen>
130
131 <para>
132 To test the results, issue: <command>make check</command>.
133 </para>
134
135 <para>
136 To install the <application>ISC Kea DHCP</application> suite,
137 issue the following commands as the
138 <systemitem class="username">root</systemitem> user:
139 </para>
140
141<screen role="root"><userinput>make -j1 install</userinput></screen>
142
143 </sect2>
144
145 <sect2 role="commands">
146 <title>Command Explanations</title>
147
148 <para>
149 <parameter>--with-pgsql</parameter> or <parameter>--with-mysql</parameter>:
150 <application>ISC Kea</application> can store the leases on a
151 database. This might be useful in large environments running
152 a cluster of DHCP servers. Using the <emphasis>memfile</emphasis>
153 backend (which is a CSV file stored locally) is possible anyhow.
154 </para>
155
156 <para>
157 <parameter>--enable-generate-docs</parameter>:
158 If documentation is to be rebuilt, add that option. Several
159 dependencies must be installed for generating the documentation.
160 </para>
161
162 <para>
163 <parameter>make -j1 install</parameter>: ISC does not recommend
164 any form of parallel or job server options when doing the install.
165 </para>
166
167 </sect2>
168
169 <sect2 role="configuration">
170 <title>Configuring ISC Kea DHCP</title>
171
172 <para>The support of IPv4, IPv6 and DDNS has been splitted into
173 separate servers which runs independently from each other. Each
174 of them has its own configuration file. Additional configuration
175 files come from the keactrl agent which is uses to control the
176 servers in an easy way.</para>
177
178 <para>Consult the
179 <ulink url="https://kea.readthedocs.io/en/kea-&kea-arm-vers;/">Kea Administrator Reference Manual</ulink>
180 for detailled information about the configuration of <application>ISC Kea</application>
181 as it is a quite capable system. The configuration shown a bare
182 minimum to get a DHCP server running but it already includes
183 configuration for DDNS (Dynamic DNS). That setup might be working
184 for small networks with a few clients and low traffic. For greater
185 installations with thousands of clients, <application>ISC Kea</application>
186 can be configured to use databases (mariadb or postgresql) to store
187 the leases and build a cluster with multiple nodes. It can
188 be integrated to <ulink url="https://www.isc.org/categories/stork/">ISC Stork</ulink>
189 which is a management dashboard to <application>ISC Kea</application>.</para>
190
191 <sect3 id="kea-dhcp-config">
192 <title>Config Files</title>
193
194 <para>
195 <filename>/etc/kea/keactrl.conf</filename>,
196 <filename>/etc/kea/kea-ctrl-agent.conf</filename>,
197 <filename>/etc/kea/kea-dhcp4.conf</filename>,
198 <filename>/etc/kea/kea-dhcp6.conf</filename> and
199 <filename>/etc/kea/kea-dhcp-ddns.conf</filename>
200 </para>
201
202 <indexterm zone="kea keactrl-config">
203 <primary sortas="e-etc-kea-keactrl.conf">/etc/kea/keactrl.conf</primary>
204 </indexterm>
205<!--
206 <indexterm zone="kea kea-ctrl-agent-config">
207 <primary sortas="e-etc-kea-kea-ctrl-agent.conf">/etc/kea/kea-ctrl-agent.conf</primary>
208 </indexterm>
209-->
210 <indexterm zone="kea kea-dhcp4-config">
211 <primary sortas="e-etc-kea-dhcp4.conf">/etc/kea/kea-dhcp4.conf</primary>
212 </indexterm>
213<!--
214 <indexterm zone="kea kea-dhcp6-config">
215 <primary sortas="e-etc-kea-dhcp6.conf">/etc/kea/kea-dhcp6.conf</primary>
216 </indexterm>
217-->
218 <indexterm zone="kea kea-dhcp-ddns-config">
219 <primary sortas="e-etc-kea-dhcp-ddns.conf">/etc/kea/kea-dhcp-ddns.conf</primary>
220 </indexterm>
221 </sect3>
222
223 <sect3 id="keactrl-config">
224 <title>Kea Control Configuration</title>
225
226 <para><command>keactrl</command> is used to control the
227 independend servers (IPv4, IPv6, DDNS). Its configuration file
228 <filename>/etc/kea/keactrl.conf</filename> is installed by
229 default and includes many path settings which are defined
230 due to the <command>configure</command> at build time. It also
231 includes settings to specify which of the servers should be
232 started.</para>
233
234 <itemizedlist>
235 <listitem>
236 <para>IPv4 DHCP server</para>
237 <para>This daemon handles requests for IPv4 addresses.
238 Set <literal>dhcp4=yes</literal> to start it, set
239 <literal>dhcp4=no</literal> in case DHCP service for IPv4
240 is not wanted.</para>
241 </listitem>
242 <listitem>
243 <para>IPv6 DHCP server</para>
244 <para>This daemon handles requests for IPv6 addresses.
245 Set <literal>dhcp6=yes</literal> to start it, set
246 <literal>dhcp6=no</literal> in case DHCP service for IPv6
247 is not wanted.</para>
248 </listitem>
249 <listitem>
250 <para>Dynamic DNS</para>
251 <para>This daemon is used to update a DNS server dynamically
252 when Kea assignes an IP address to a device.
253 Set <literal>dhcp_ddns=yes</literal> to enable it, set
254 <literal>dhcp_ddns=no</literal> in case dynamic DNS updates
255 are not wanted.</para>
256 </listitem>
257 <listitem>
258 <para>Control Agent</para>
259 <para>The Control Agent is a daemon which allows the
260 (re)configuration of the Kea DHCP service via REST API.
261 Set <literal>ctrl_agent=yes</literal> to start the
262 control agent (service providing a REST API), set
263 <literal>ctrl_agent=no</literal> in case the control agent
264 is not needed.</para>
265 </listitem>
266 </itemizedlist>
267
268 <para>The Netconf service is not installed because required
269 dependencies are not covered by the current BLFS book.</para>
270
271 <para>With the following command, Kea will be configured to
272 start the dhcp service for IPv4 and the
273 dynamic DNS update, while the control agent and
274 the dhcp service for IPv6 remains down. Tweak the command to
275 match your needs on started services and execute as the
276 <systemitem class="username">root</systemitem> user:</para>
277
278<screen><userinput role="root">sed -e "s/^dhcp4=.*/dhcp4=yes/" \
279 -e "s/^dhcp6=.*/dhcp6=no/" \
280 -e "s/^dhcp_ddns=.*/dhcp_ddns=yes/" \
281 -e "s/^ctrl_agent=.*/ctrl_agent=no/" \
282 -i /etc/kea/keactrl.conf
283</userinput></screen>
284
285 </sect3>
286
287 <sect3 id="kea-dhcp4-config">
288 <title>IPv4 DHCP Server Configuration</title>
289
290 <para>
291 If you want to start the DHCP Server at boot, install the
292 <phrase revision="sysv"><filename>/etc/rc.d/init.d/kea-dhcpd</filename>
293 init script</phrase>
294 <phrase revision="systemd"><filename>kea-dhcpd.service</filename>
295 unit</phrase> included in the
296 <xref linkend="bootscripts" revision="sysv"/>
297 <xref linkend="systemd-units" revision="systemd"/>
298 package:
299 </para>
300
301<screen role="root"><userinput>make install-kea-dhcpd</userinput></screen>
302
303 <para>
304 A sample configuration file is created in <filename>/etc/kea/kea-dhcpd4.conf</filename>.
305 Adjust the file to suit your needs or overwrite it by using
306 the following sample as the <systemitem class="username">root</systemitem>
307 user:
308 </para>
309
310<screen role="nodump" ><userinput>cat &gt; /etc/kea/kea-dhcpd4.conf &lt;&lt; "EOF"
311<literal>// Begin /etc/kea/kea-dhcpd4.conf
312{
313 "Dhcp4": {
314 // Add names of your network interfaces to listen on.
315 "interfaces-config": {
316 "interfaces": [ "eth0", "eth2" ]
317 },
318
319 "control-socket": {
320 "socket-type": "unix",
321 "socket-name": "/tmp/kea4-ctrl-socket"
322 },
323
324 "lease-database": {
325 "type": "memfile",
326 "lfc-interval": 3600
327 },
328
329 "expired-leases-processing": {
330 "reclaim-timer-wait-time": 10,
331 "flush-reclaimed-timer-wait-time": 25,
332 "hold-reclaimed-time": 3600,
333 "max-reclaim-leases": 100,
334 "max-reclaim-time": 250,
335 "unwarned-reclaim-cycles": 5
336 },
337
338 "renew-timer": 900,
339 "rebind-timer": 1800,
340 "valid-lifetime": 3600,
341
342 // Enable DDNS - Kea will dynamically update the DNS
343 "ddns-send-updates" : true,
344 "ddns-qualifying-suffix": "your.domain.tld",
345 "dhcp-ddns" : {
346 "enable-updates": true
347 },
348
349 "subnet4": [
350 {
351 "subnet": "192.168.56.0/24",
352 "pools": [ { "pool": "192.168.56.16 - 192.168.56.254" } ],
353 "option-data": [
354 {
355 "name": "domain-name",
356 "data": "your.domain.tld"
357 },
358 {
359 "name": "domain-name-servers",
360 "data": "192.168.56.2, 192.168.3.7"
361 },
362 {
363 "name": "domain-search",
364 "data": "your.domain.tld"
365 },
366 {
367 "name": "routers",
368 "data": "192.168.56.2"
369 }
370 ]
371 }
372 ],
373
374 "loggers": [
375 {
376 "name": "kea-dhcp4",
377 "output_options": [
378 {
379 "output": "/var/log/kea-dhcp4.log",
380 "pattern": "%D{%Y-%m-%d %H:%M:%S.%q} %-5p %m\n"
381 }
382 ],
383 "severity": "INFO",
384 "debuglevel": 0
385 }
386 ]
387 }
388}
389// End /etc/kea/kea-dhcpd4.conf</literal>
390EOF</userinput></screen>
391
392 <para>
393 The configuration for IPv6 is similar to the configuration
394 of IPv4. The configuration file is
395 <filename>/etc/kea/kea-dhcpd6.conf</filename>.
396 </para>
397
398 </sect3>
399
400 <sect3 id="kea-dhcp-ddns-config">
401 <title>Dynamic DNS Configuration</title>
402
403 <para>
404 If there is a <xref linkend="bind"/> server running, <application>ISC Kea</application>
405 can update the DNS when it gives an IP address to a client.
406 A sample configuration file is created in <filename>/etc/kea/kea-dhcp-ddns.conf</filename>.
407 Adjust the file to suit your needs or overwrite it by using
408 the following sample as the <systemitem class="username">root</systemitem>
409 user:
410 </para>
411
412<screen role="nodump" ><userinput>cat &gt; /etc/kea/kea-dhcp-ddns.conf &lt;&lt; "EOF"
413<literal>// Begin /etc/kea/kea-dhcp-ddns.conf
414{
415 "DhcpDdns": {
416 "ip-address": "127.0.0.1",
417 "port": 53001,
418 "control-socket": {
419 "socket-type": "unix",
420 "socket-name": "/tmp/kea-ddns-ctrl-socket"
421 },
422
423 "tsig-keys": [
424 {
425 "name" : "rndc-key",
426 "algorithm" : "hmac-sha256",
427 "secret" : "1FU5hD7faYaajQCjSdA54JkTPQxbbPrRnzOKqHcD9cM="
428 }
429 ],
430
431 "forward-ddns" : {
432 "ddns-domains" : [
433 {
434 "name" : "your.domain.tld.",
435 "dns-servers" : [
436 {
437 "ip-address" : "127.0.0.1",
438 "port" : 53
439 }
440 ]
441 }
442 ]
443 },
444
445 "reverse-ddns" : {
446 "ddns-domains" : [
447 {
448 "name" : "56.168.192.in-addr.arpa.",
449 "dns-servers" : [
450 {
451 "ip-address" : "127.0.0.1",
452 "port" : 53
453 }
454 ]
455 }
456 ]
457 },
458
459 "loggers": [
460 {
461 "name": "kea-dhcp-ddns",
462 "output_options": [
463 {
464 "output": "/var/log/kea-ddns.log"
465 "pattern": "%D{%Y-%m-%d %H:%M:%S.%q} %-5p %m\n"
466 }
467 ],
468 "severity": "INFO",
469 "debuglevel": 0
470 }
471 ]
472 }
473}
474// End /etc/kea/kea-dhcp-ddns.conf</literal>
475EOF</userinput></screen>
476
477 <note>
478 <para>
479 The value of <literal>secret</literal> is just an example.
480 Generate the key for your installation by using the
481 <command>rndc-confgen -a</command> command or the
482 <command>tsig-keygen</command> command which both are
483 provided by <xref linkend="bind"/>.
484 </para>
485 </note>
486
487 </sect3>
488
489 </sect2>
490
491 <sect2 role="content">
492 <title>Contents</title>
493
494 <segmentedlist>
495 <segtitle>Installed Programs</segtitle>
496 <segtitle>Installed Libraries</segtitle>
497 <segtitle>Installed Directories</segtitle>
498
499 <seglistitem>
500 <seg>
501 keactrl, kea-admin, kea-ctrl-agent, kea-dhcp4, kea-dhcp6,
502 kea-dhcp-ddns, kea-lfc, kea-shell
503 </seg>
504 <seg>
505 libkea-*
506 </seg>
507 <seg>
508 /etc/kea,
509 /usr/include/kea,
510 /var/lib/kea
511 </seg>
512 </seglistitem>
513 </segmentedlist>
514
515 <variablelist>
516 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
517 <?dbfo list-presentation="list"?>
518 <?dbhtml list-presentation="table"?>
519
520 <varlistentry id="keactrl">
521 <term><command>keactrl</command></term>
522 <listitem>
523 <para>
524 Tool to control the server processes
525 </para>
526 <indexterm zone="kea keactrl">
527 <primary sortas="b-keactrl">keactrl</primary>
528 </indexterm>
529 </listitem>
530 </varlistentry>
531
532 <!-- ...to be completed... -->
533
534 </variablelist>
535
536 </sect2>
537
538</sect1>
Note: See TracBrowser for help on using the repository browser.