What is the purpose of reserved_dhcp_port?

asked 2020-02-24 03:11:12 -0600

panticz gravatar image

updated 2020-02-24 03:11:39 -0600

I see in some subnets device-id with the name reserved_dhcp_port

openstack port list -c device_id -c id --device-id reserved_dhcp_port

Manual reset of the DHCP namespaces dont removed those:

openstack subnet set --no-dhcp ${SUBNET_ID}
openstack subnet set --dhcp ${SUBNET_ID}

What are they needed for and can they be removed safely with openstack port delete?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2020-02-24 03:26:52 -0600

There is an undocumented process to reserve IP addresses for use by DHCP servers. It works by creating port with the desired IP and a device owner of reserved_dhcp_port."

openstack port create dhcp-port1 --network <network UUID> --fixed-ip subnet=<subnet UUID>,ip-address=192.0.2.2 --device reserved_dhcp_port

You can either create the port prior to enabling DHCP on the subnet or delete an existing DHCP port after creating the reserved port. In either case, Neutron should utilize the reserved port on subsequent DHCP agent creation.

For understanding from the code have a look at https://github.com/openstack/neutron/...

This will give you a more concrete answer.

I hope that helps !!

edit flag offensive delete link more

Get to know Ask OpenStack

Resources for moderators

Question Tools

Stats

Asked: 2020-02-24 03:11:12 -0600

Seen: 104 times

Last updated: Feb 24