[Kea-users] kea dhcp4 doesn't record ip address, mac address and hostname in mysql
Makhdoom Naeem
makhdoomnaeem at nfciet.edu.pk
Fri May 14 13:36:40 UTC 2021
Hi all,
{ "Dhcp4":
{
"server-tag": "all",
// Kea is told to listen on ethX interface only.
"interfaces-config": {
"interfaces": [ "enp10s0" ]
},
"config-control": {
// A list of database backends to connect to. Currently, it is
limited
// to a single backend.
"config-databases": [
{
"type": "mysql",
"name": "research_platform_db",
"user": "makhdoomnaeem",
"password": "Naeem0000",
"host": "localhost",
"port": 3306
}
],
// Controls how often the server polls the database for the
// configuration updates. The setting below implies that it
// will take up to approx. 20 seconds for the server to
// discover and fetch configuration changes.
"config-fetch-wait-time": 20
},
// This defines a control socket. If defined, Kea will open a UNIX
socket
// and will listen for incoming commands. See section 17 of the Kea ARM
for
// details.
"control-socket": {
"socket-type": "unix",
"socket-name": "/tmp/kea4-ctrl-socket"
},
// Hooks libraries that enable configuration backend are loaded.
"hooks-libraries": [
// The libdhcp_mysql_cb.so is required to use MySQL Configuration
// Backend.
{
"library": "/usr/local/lib/kea/hooks/libdhcp_mysql_cb.so"
},
{
"library": "/usr/local/lib/kea/hooks/libdhcp_lease_cmds.so"
},
{
"command": "lease4-add",
"arguments": {
"ip-address": "192.168.100.150",
"hw-address": "34:17:eb:66:a4:9d"
}
}
],
// Addresses will be assigned with a lifetime of 4000 seconds.
"valid-lifetime": 4000,
"host-reservation-identifiers": [ "hw-address" ],
"hosts-database": {
"type": "mysql",
"name": "research_platform_db",
"user": "makhdoomnaeem",
"password": "Naeem0000",
"host": "localhost",
"port": 3306
},
"subnet4": [
{
"pools": [ { "pool": "192.168.100.101 - 192.168.100.200" } ],
"subnet": "192.168.100.0/24",
"interface": "enp10s0",
"reservation-mode": "all",
"reservations": [
// This is a reservation for a specific hardware/MAC address. It's a very
// simple reservation: just an address and nothing else.
{
"hw-address": "34:17:eb:66:a4:9d",
"ip-address": "192.168.100.150",
"hostname": "12345"
}
]
}
]
}
}
Please let me know
Best Regards
--
Makhdoom Muhammad Naeem
Assistant Professor
Department of Electrical Engineering
NFC Institute of Engineering and Technology
Multan
Phone # +92619220012, Ext 2289 <%2B92619220012%2C%20Ext%202231>
Email: makhdoomnaeem at gmail.com
makhdoomnaeem at nfciet.edu.pk
--
_____
Note:
1. The email and any files transmitted with it will be
confidential and
intended solely for the use of the *individual* or
*entity* to which they
will be addressed.
2. If you are not the named
*addressee*, you should not *disseminate*,
*distribute* or *copy* the
e-mail. If you are not the intended recipient,
you are notified that
*disclosing*, *copying*, *distributing*, or taking any
action in reliance
on the contents of the information is strictly
prohibited. Any unauthorized
reproduction of the message may result in
legal and disciplinary action.
3.
*NFC IET* shall not be liable for improper or incomplete or
delayed
transmission of the message. *NFC IET* will not accept
liability for any
errors or omissions in the contents of the message,
which arise as a result
of email transmission.
4. *NFC IET* does not guarantee that the integrity
of the email
has been maintained or that that communication will be free of
viruses,
interceptions, or interference. Although *NFC IET* will take
reasonable precautions to ensure that no viruses will be present in the
mail, *NFC IET* cannot accept responsibility for any loss or
damage arising
from the use of the email or attachments.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.isc.org/pipermail/kea-users/attachments/20210514/66c574c3/attachment-0001.htm>
More information about the Kea-users
mailing list