[Dnsmasq-discuss] DHCP Relay, assign address from other vlan, with no dhcp listening on it

Simon Kelley simon at thekelleys.org.uk
Mon Sep 12 13:09:50 BST 2011


SpiderX wrote:

>> I think what's happening is that the relay adds its 172.... address to
>> the relayed DHCP packet
> Thanks for reply, Simon.
> Are you talking about giaddr field? 

That's the one.

>If no, then there is no any other
> 172... in the packet:
>     IP: 172.16.33.50 (1c:bd:b9:9b:68:5c) > 172.16.33.252 (0:1e:67:2:ad:6a)
>     OP: 1 (BOOTPREQUEST)
>  HTYPE: 1 (Ethernet)
>   HLEN: 6
>   HOPS: 1
>    XID: 830b9708
>   SECS: 0
>  FLAGS: 0
> CIADDR: 0.0.0.0
> YIADDR: 0.0.0.0
> SIADDR: 0.0.0.0
> GIADDR: 172.16.33.50
> CHADDR: 48:5b:39:36:a2:73:00:00:00:00:00:00:00:00:00:00
>  SNAME: .
>  FNAME: .
> OPTION:  53 (  1) DHCP message type         1 (DHCPDISCOVER)
> OPTION:  50 (  4) Request IP address        172.16.33.121
> OPTION:  12 (  6) Host name                 laptop
> OPTION:  55 ( 13) Parameter Request List      1 (Subnet mask)
> 					     28 (Broadcast address)
> 					      2 (Time offset)
> 					      3 (Routers)
> 					     15 (Domainname)
> 					      6 (DNS server)
> 					    119 (Domain Search)
> 					     12 (Host name)
> 					     44 (NetBIOS name server)
> 					     47 (NetBIOS scope)
> 					     26 (Interface MTU)
> 					    121 (Classless Static Route)
> 					     42 (NTP servers)
> 					
> OPTION:  82 ( 18) Relay Agent Information
>                   Circuit-ID    00:04:00:02:00:10
>                   Remote-ID     00:06:1c:bd:b9:9b:68:5c
> ---------------------------------------------------------------------------

So, you need persuade your relay to add a sub-option 5 (subnet select)
to the relay agent information, along with the circuit-id and remote-id.
The subnet-select option holds the 10....... network address and tells
dnsmasq it should allocate addresses there, even thought the giaddr is
on 172....


HTH

Simon.



More information about the Dnsmasq-discuss mailing list