Page MenuHomeVyOS Platform

DHCP Lease not displayed with a static map
Open, Requires assessmentPublicBUG

Description

When we use static mapping for DHCP-server, it not display the lease.
Server side:

set service dhcp-server shared-network-name LAN subnet 10.0.0.0/24 default-router '10.0.0.1'
set service dhcp-server shared-network-name LAN subnet 10.0.0.0/24 dns-server '10.0.0.1'
set service dhcp-server shared-network-name LAN subnet 10.0.0.0/24 lease '86400'
set service dhcp-server shared-network-name LAN subnet 10.0.0.0/24 range 0 start '10.0.0.100'
set service dhcp-server shared-network-name LAN subnet 10.0.0.0/24 range 0 stop '10.0.0.199'
set service dhcp-server shared-network-name LAN subnet 10.0.0.0/24 static-mapping myPC ip-address '10.0.0.130'
set service dhcp-server shared-network-name LAN subnet 10.0.0.0/24 static-mapping myPC mac-address '52:54:00:a9:98:2c'

Show leases:

vyos@r1-roll:~$ show dhcp server leases 
IP address    Hardware address    State    Lease start    Lease expiration    Remaining    Pool    Hostname
------------  ------------------  -------  -------------  ------------------  -----------  ------  ----------
vyos@r1-roll:~$

R2 client side

vyos@r2-roll# run show int | match eth1
eth1             10.0.0.130/24                     u/u

Delete static mapping:

vyos@r1-roll# delete service dhcp-server shared-network-name LAN subnet 10.0.0.0/24 static-mapping myPC 
[edit]
vyos@r1-roll# commit

Reassign ip on the client-side:

delete interfaces ethernet eth1 address dhcp 
commit

set interfaces ethernet eth1 address dhcp
commit

vyos@r2-roll# run show int | match eth1
eth1             10.0.0.130/24                     u/u 
[edit]
vyos@r2-roll#

Chek leases on the server side:

vyos@r1-roll# run show dhcp server leases 
IP address    Hardware address    State    Lease start          Lease expiration     Remaining    Pool    Hostname
------------  ------------------  -------  -------------------  -------------------  -----------  ------  ----------
10.0.0.130    52:54:00:a9:98:2c   active   2020/07/27 15:42:17  2020/07/28 15:42:17  23:58:56     LAN     r2-roll

Details

Difficulty level
Unknown (require assessment)
Version
VyOS 1.3-rolling-202007270117
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)

Event Timeline