DHCPv4 server and relay at the same time

Dave Taht dave.taht at gmail.com
Wed Mar 21 15:03:21 UTC 2012


On Wed, Mar 21, 2012 at 4:01 AM, Francis Dupont <fdupont at isc.org> wrote:
> We have some issues with the CPE setup for the next Sunday demo:
> the same box runs at the same time but on different interfaces
> a relay (it is a CRA but for this issue there is unfortunately no
> differences) and a server, the kernel is a Linux 3.3, and the server
> dnsmasq which provides both a DNS proxy and a DHCPv4 server.
>
> The issue is both try to bind a socket to *:67. It is possible
> to force a SO_REUSEADDR (-z or --bind-interfaces, also in the conf file)
> for dnsmasq but if the second socket can bind without the
> "Address already in use" error this is far to mean packets will be
> delivered to both sockets.
>
> I added for the dhccra an option to bind to local_address but t
> address to use is the address the system tries to acquire so it is
> both hairy and not great. BTW dhcrelay doesn't provide the same
> option for IPv4 so the generic issue is not solved on the relay side.
>
> Of course the obvious solution is to use our DHCPv4 server in place
> of dnsmasq but we don't know if it will be acceptable on not
> technical point of view...

Your dhcp server won't have the same trouble binding that dnsmasq has,
when the relay is also binding the interface(s)?

My understanding is that the relay wants to send it's own ip database
out from a global set, which have to be real on one interface and
natted on the rest.

As we now have 6MB worth of isc binaries on a system with room for 4,
when I thought we only needed 1.5, I'll have to remove some core
functionality from the cpe, probably the vpn code.


>
> Regards
>
> Francis Dupont <fdupont at isc.org>
>
> PS: for the sdcpe list:
>  - there is no way to force dnsmasq to use an address (vs. the wilcard)
>  for its DHCPv4 service socket (UDP port 67).

Well, it might be hackable.

>  - with -z or --bind-interfaces or bind-interfaces in the conf file
>  dnsmasq sets the SO_REUSEADDR flag before calling bind()
>  - the simplest way to disable the DHCPv4 server function is to not
>  define a dhcp-range
>  - the current work around is to run a CRA servicing the whole link
>  on the laptop based SD-B4. So we'll have to configure a DHCP4 DHCPv4
>  server on ida and save the conf at the usual place for the demo.
>  I'll do it (not a problem, because of the CRA the whole DHCP4 is
>  already available on ida)
> io = test SD-AFTR, ida = test SD-B4, cruithne = test client
> (which seems to be currently off but it worked well yesterday
> so I'll need only someone to check it before Saturday).

Cruithne is my personal laptop and went home with me last night.

It would be helpful to leave a client (someone elses laptop) in place 24/7.

>
> _______________________________________________
> sdcpe-devel mailing list
> sdcpe-devel at lists.isc.org
> https://lists.isc.org/mailman/listinfo/sdcpe-devel



-- 
Dave Täht
SKYPE: davetaht
US Tel: 1-239-829-5608
http://www.bufferbloat.net


More information about the sdcpe-devel mailing list