andrewclark
Posts: 3
Joined: Thu Apr 14, 2016 2:41 pm

Getting RPi 3 to work as DHCP Server

Thu Apr 14, 2016 2:59 pm

I'd like to get the Pi (RPi 3) to allocate IP addresses to an Ethernet network I am building for use in a 3rd-world country. It currently only works in its default setting if there is already a DHCP Server on the network (there isn't).

I thought there was a GUI configuration tool somewhere for the network but it does not seem to be present in this implementation (RACHEL Debian Linux). I am not a competent Linux hacker but I could follow command-line instructions if they were provided to do this.

It seems to have a tool installed called BusyBox which says it provides DHCP services, but I can't even see how that is configured.

Can anyone help with this? I can't see a relevant topic on the Forum.

TIA
Andrew

Aydan
Posts: 692
Joined: Fri Apr 13, 2012 11:48 am
Location: Germany, near Lake Constance

Re: Getting RPi 3 to work as DHCP Server

Thu Apr 14, 2016 3:06 pm

busybox provides udhcpd, which is a minimal dhcp deamon. It will not allow you to connect to other computers on the network by name. If you don't need this then you're set with busybox.
You just have to set up the IP address range to use and enable the serivce to start at boot.

If you plan to have internet access, then you should use dnsmasq, which provides dns and routing functionality in addition to dhcp.

Regards
Aydan

andrewclark
Posts: 3
Joined: Thu Apr 14, 2016 2:41 pm

Re: Getting RPi 3 to work as DHCP Server

Thu Apr 14, 2016 4:05 pm

Thanks very much for coming back to me.

>You just have to set up the IP address range to use and enable the service to start at boot.

OK. How do I do that?

We are not likely to have internet access (it will be based in rural Africa) but if we did in future how would we configure your suggested alternative.

Apologies for the simple questions but I am just starting with Pi-ware after a life in Windows IT!

Regards
Andrew

Aydan
Posts: 692
Joined: Fri Apr 13, 2012 11:48 am
Location: Germany, near Lake Constance

Re: Getting RPi 3 to work as DHCP Server

Thu Apr 14, 2016 5:33 pm

I'd suggest you fisrt try on your own how far you get, with google's help.
udhcpd:
https://casper.berkeley.edu/svn/trunk/r ... dhcpd.conf

dnsmasq
https://wiki.debian.org/HowTo/dnsmasq

Regards
Aydan

andrewclark
Posts: 3
Joined: Thu Apr 14, 2016 2:41 pm

Re: Getting RPi 3 to work as DHCP Server

Thu Apr 14, 2016 9:24 pm

Thanks. There seems to be a lot there.

I'll give it a go.

Regards
Andrew

User avatar
Doctorwho8
Posts: 56
Joined: Mon Dec 31, 2012 11:00 pm
Location: Astoria NY
Contact: Website

Re: Getting RPi 3 to work as DHCP Server

Wed Aug 23, 2017 12:47 am

Aydan wrote:
Thu Apr 14, 2016 5:33 pm
I'd suggest you fisrt try on your own how far you get, with google's help.
udhcpd:
https://casper.berkeley.edu/svn/trunk/r ... dhcpd.conf

dnsmasq
https://wiki.debian.org/HowTo/dnsmasq

Regards
Aydan
Hello!
I have an interesting problem. And it concerns both of those examples. I'd gone as far as customizing one or the other to provide an IP address to something connected to my RPi3 device. But nothing seems to want to work.

One question does come to mind, "Do I need to set a static IP address on the Ethernet connection first?"

The thing in question is a Linksys RT31P2 customized for Vonage. I am presently evaluating a project where the device sends its requests to the RPi3 and eventually it forwards them out to the Internet. There will be one other Raspberry Pi connected to the Linksys RT31P2 device.
-------------------
Gregg
Doctor Who8

Return to “Troubleshooting”