[Kea-users] Problem during running DHCP server on VLAN interface
Seyyed Hesam Ghasemi
s.hesam.ghasemi at gmail.com
Sat Jan 28 14:52:37 UTC 2023
Is it possible to have a DHCP server on a VLAN interface? I tried but I
receive "interface doesn't exist" error. Is there any issue with my
configuration?
I have created a vlan interface with name "vlan10" and ID of 10 on physical
interface named "port2":
user:~# ip a
3: port2: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state
DOWN group default qlen 1000
link/ether 00:0c:29:3d:0e:3c brd ff:ff:ff:ff:ff:ff
inet 2.2.2.1/24 scope global port2
valid_lft forever preferred_lft forever
20: vlan10 at port2: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc
noqueue state LOWERLAYERDOWN group default qlen 1000
link/ether 00:0c:29:3d:0e:3c brd ff:ff:ff:ff:ff:ff
inet 1.1.1.1/24 scope global vlan10
valid_lft forever preferred_lft forever
user:~# cat /proc/net/vlan/vlan10
vlan10 VID: 10 REORDER_HDR: 1 dev->priv_flags: 1021
total frames received 0
total bytes received 0
Broadcast/Multicast Rcvd 0
total frames transmitted 0
total bytes transmitted 0
Device: port2
INGRESS priority mappings: 0:0 1:0 2:0 3:0 4:0 5:0 6:0 7:0
EGRESS priority mappings:
root at nsg4-113-120:~#
I have tried the following json configs and all caused errors but none of
them works:
{
"command": "config-test",
"service": [
"dhcp4"
],
"arguments": {
"Dhcp4": {
"control-socket": {
"socket-name": "/run/kea/socket-v4",
"socket-type": "unix"
},
"interfaces-config": {
"interfaces": [
"port2.10"
]
},
"subnet4": [
{
"interface": "port2.10",
"id": 10,
"pools": [
{
"pool": "2.2.2.10-2.2.2.20"
}
],
"subnet": "2.2.2.0/24",
"reservations": [],
"valid-lifetime": 3600,
"option-data": [
{
"data": "192.168.92.11",
"code": 6,
"space": "dhcp4"
},
{
"data": "2.2.2.2",
"code": 3,
"space": "dhcp4"
}
]
}
],
"client-classes": [],
"option-data": []
}
}
}
Error: [ { "result": 1, "text": "Failed to select interface: interface
'port2.10' doesn't exist in the system (<wire>:0:609) (<wire>:0:608)"
} ]
{
"command": "config-test",
"service": [
"dhcp4"
],
"arguments": {
"Dhcp4": {
"control-socket": {
"socket-name": "/run/kea/socket-v4",
"socket-type": "unix"
},
"interfaces-config": {
"interfaces": [
"vlan01 at port2"
]
},
"subnet4": [
{
"interface": "vlan01 at port2",
"id": 10,
"pools": [
{
"pool": "2.2.2.10-2.2.2.20"
}
],
"subnet": "2.2.2.0/24",
"reservations": [],
"valid-lifetime": 3600,
"option-data": [
{
"data": "192.168.92.11",
"code": 6,
"space": "dhcp4"
},
{
"data": "2.2.2.2",
"code": 3,
"space": "dhcp4"
}
]
}
],
"client-classes": [],
"option-data": []
}
}
}
Error: [ { "result": 1, "text": "Failed to select interface: interface
'vlan01 at port2' doesn't exist in the system (<wire>:0:609)
(<wire>:0:608)" } ]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.isc.org/pipermail/kea-users/attachments/20230128/d8b992cd/attachment.htm>
More information about the Kea-users
mailing list