DHCP Option 43 Config - Unifi Controller

Please follow the below template, it will help us to help you!

Expected Behaviour:

IP of Unifi controller is set using DHCP option 43

Actual Behaviour:

No parameter set using option 43.
Created 43-unifi.conf in /etc/dnsmasq.d/ and have tried multiple variants of syntax for setting this option to point Ubiquiti devices to my Unifi controller hosted at Digital Ocean. Currently trying to simply use: dhcp-option=43,162.243.XXX.YYY (of course X and Y are replaced with the real values to reach the controller). Have attempted to use Wireshark and see no response from Pi-hole for this particular DHCP option. The devices are getting the standard set of DHCP info from Pi-hole, and were previously getting option 43 set correctly from the Meraki DHCP server that was taken out of service when Pi-hole was dropped in.

Debug Token:

https://tricorder.pi-hole.net/x8ttr4itml

Is this a Pi-hole issue? It sounds like you are simply having an issue configuring dnsmasq.

Isc dhcp server works better for that, i use it :+1:

Am not sure if thats proper way to use option 43 "Vendor Specific Information":

pi@noads:~ $ echo 'dhcp-option=43,162.243.0.99' | sudo tee /etc/dnsmasq.d/43-unifi.conf
dhcp-option=43,162.243.0.99

pi@noads:~ $ sudo service pihole-FTL reload
pi@noads:~ $

dehakkelaar@laptop:~$ sudo nmap -sU -p67 --script dhcp-discover 10.0.0.2

Starting Nmap 7.40 ( https://nmap.org ) at 2019-07-02 17:08 CEST
Nmap scan report for noads.dehakkelaar.nl (10.0.0.2)
Host is up (0.0012s latency).
PORT   STATE SERVICE
67/udp open  dhcps
| dhcp-discover:
|   DHCP Message Type: DHCPACK
|   Server Identifier: 10.0.0.2
|   IP Address Lease Time: 23h56m16s
|   Subnet Mask: 255.255.255.0
|   Broadcast Address: 10.0.0.255
|   Domain Name Server: 10.0.0.2
|   Domain Name: dehakkelaar.nl
|   Vendor Specific Information: \xA2\xF3\x00c
|_  Router: 10.0.0.1
MAC Address: B8:27:EB:68:xx:xx (Raspberry Pi Foundation)

Nmap done: 1 IP address (1 host up) scanned in 1.00 seconds

You can see the option 43 here

1 Like

@deHakkelaar Thanks so much. That seemed to correct the problem.

@Mcat12 I was using what I thought were standard dnsmasq config options with no luck so I thought perhaps there was something related to the FTL-embedded implementation that was causing a variance from the manner in which "standalone" dnsmasq works with those config options.

All seems to be well now. Thanks all.

1 Like

Glad it works.
I dont know enough about that option 43.
I was suprised configuring:
"dhcp-option=43,162.243.0.99"

resulted in:
"Vendor Specific Information: \xA2\xF3\x00c"

when doing a DHCP discovery with nmap.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.