[Dnsmasq-discuss] IP address based on switch port number (option 82)

Simon Kelley simon at thekelleys.org.uk
Mon Feb 15 21:19:21 GMT 2010


Ignacio.Bravo at belden.com wrote:
> Hello Simon,
>  >>Yes, you can do that: The AND function is in dhcp-range: set tags for
>  >>each switch and port and use a switch tag and a port tag in dhcp-range
> 
>  >>dhcp-range=net:switch-1,net:port-1,192.168.7.1,192.168.7.4,255.255.255.0
> 
> I have problems with the AND function. If I set:
> dhcp-range=net:port-1,10.10.35.60,10.10.35.65,255.255.255.0
> dhcp-circuitid=port-1,b9:06:00:00:01:01:01:03
> Port-1 tag is set and offer is sent
> 
> If I set:
> dhcp-range=net:switch-1,10.10.35.60,10.10.35.65,255.255.255.0
> dhcp-remoteid=switch-1,00:06:00:80:63:60:e1:64
> switch-1 tag is set and offer is sent
> 
> But in this case:
> dhcp-range=net:port-1,net:switch-1,10.10.35.60,10.10.35.65,255.255.255.0
> dhcp-circuitid=port-1,b9:06:00:00:01:01:01:03
> dhcp-remoteid=switch-1,00:06:00:80:63:60:e1:64
> NO OFFER IS SEND NOT TAG SET
> 
> I must be doing something wrong. Please let me know

Maybe not. Please could you split the test up: use a dhcp-range without
tags, so that an address is always allocated, set log-dhcp, and check
which tags are set. (Look in syslog, the set of tags is printed there.)
That will help to isolate the problem.

Cheers,

Simon.



More information about the Dnsmasq-discuss mailing list