Hi folks!
So I've got a machine (actually two machines in two different sites) that behaves awfully odd when it comes to DHCP.
When the machine is booting up, then it'll uses one MAC (fixed) address to requests an IP using DHCP and as soon as it got one, it'll change the MAC address to different one (also fixed) and it'll simply continue using the previously gained IP address. After the lease time has passed, it'll try to renew its IP with the newer MAC address - and it'll fail, of course. This results in receiving a second IP address for the second MAC address.
I know guys, this behaviour is awful, but I checked with the manufacturer and they confirmed this to be a known bug as the machine starts using DHCP before its MAC was correctly derived and set from the device's serial number. As I was mentioning before, I've got two of these machines and both behave exactly the same and they require DHCP as they do not support fixed IPs.
Okay, so I simply wanted to add two static leases to my DHCP server. One for each MAC and both pointing to the same IP address.Sadly this results in the error message seen above. I would understand receiving a warning, but completely rejecting it seems a bit too much.
The 2nd machine is at a different site where a pfSense is used as DHCP server, where I can simply add two static leases with same IP and different MACs, and the DHCP server will simply assign identical IPs to both DHCP requests from those two different MACs, at least when I turn off conflict detection. This works fine even before the first lease has fully expired.
So my question is pretty simple: How can I achieve the same behaviour with RouterOS, so my device doesn't wildly jump between two IP addresses?
It is always ensured, that only one of two MAC addresses is active as the device simply changes the MAC of its network adapter while booting up.
Any ideas?
So I've got a machine (actually two machines in two different sites) that behaves awfully odd when it comes to DHCP.
When the machine is booting up, then it'll uses one MAC (fixed) address to requests an IP using DHCP and as soon as it got one, it'll change the MAC address to different one (also fixed) and it'll simply continue using the previously gained IP address. After the lease time has passed, it'll try to renew its IP with the newer MAC address - and it'll fail, of course. This results in receiving a second IP address for the second MAC address.
I know guys, this behaviour is awful, but I checked with the manufacturer and they confirmed this to be a known bug as the machine starts using DHCP before its MAC was correctly derived and set from the device's serial number. As I was mentioning before, I've got two of these machines and both behave exactly the same and they require DHCP as they do not support fixed IPs.
Okay, so I simply wanted to add two static leases to my DHCP server. One for each MAC and both pointing to the same IP address.
Code:
/ip/dhcp-server/lease> add address=192.168.1.111 comment=mac1 mac-address=36:C9:E3:F1:B8:05 server=dhcp_vlan177/ip/dhcp-server/lease> add address=192.168.1.111 comment=mac2 mac-address=6E:3D:2F:58:6A:7E server=dhcp_vlan177failure: already have static lease with this IP address
The 2nd machine is at a different site where a pfSense is used as DHCP server, where I can simply add two static leases with same IP and different MACs, and the DHCP server will simply assign identical IPs to both DHCP requests from those two different MACs, at least when I turn off conflict detection. This works fine even before the first lease has fully expired.
So my question is pretty simple: How can I achieve the same behaviour with RouterOS, so my device doesn't wildly jump between two IP addresses?
It is always ensured, that only one of two MAC addresses is active as the device simply changes the MAC of its network adapter while booting up.
Any ideas?
Statistics: Posted by rbm78bln — Sun Feb 11, 2024 6:10 pm