[Dnsmasq-discuss] dhcp for Adtran phones

Simon Kelley simon at thekelleys.org.uk
Fri Feb 8 14:51:17 GMT 2013


On 07/02/13 17:14, Josh Lawrence wrote:
> Hello all,
> 
> I'm trying to replace the dhcp server on our NetVanta 7100 phone
> system, which provides phone services to our Adtran phones.  In
> looking at the config and at Adtran's documentation
> (https://supportforums.adtran.com/docs/DOC-5494, applies to Windows
> systems), I need to be able to send a long string as dhcp option 157:
> 
> TftpServers=0.0.0.0,FtpServers=X.X.X.X:/ADTRAN,FtpLogin=polycomftp,FtpPassword=password,Layer2Tagging=True,VlanID=Y
> 
> I've been reading and Googling like crazy, and all I can seem to come
> up with is creating a vendor class, something like this (taken loosely
> from the mailing list):
> 
> dhcp-vendorclass=adtran,???
> 
> dhcp-option=adtran,vendor:???,157,"myreallylongstring"
> 
> Problems:
> 
> 1.  I used dhcpdump to look at the requests, and I cannot find that
> our phones actually send the identifying vendor information, so I
> can't figure out how to tell dnsmasq to look for and hand out my
> custom 157.  The current system just gives it to anyone making a dhcp
> request, so I *think* it would be ok to hand that string out to any
> device making a request.
> 
> 2.  Obviously that syntax in my examples above is damn-near made
> up...can someone suggest how my config lines should actually look?
> 
> 3.  Somewhat unrelated, but these phones also need time-offset; I've
> tried various forms of dhcp-option commands to get this to work
> (-21600, 0xFFFABA0, -6), but they all fail.  What's the appropriate
> way to express time-offset?
> 
> I'm very new to dhcp in general and I'm doing my RTFM, but I'm stumped
> and would be very appreciative of any help!
> 
> Many thanks for dnsmasq,
> 
> Josh
> 
> PS:  This is what I'm using as my primary reference, although I admit
> that I understand very little of it:
> 
> http://www.iana.org/assignments/bootp-dhcp-parameters/bootp-dhcp-parameters.xml
> 


First tip: setting log-dhcp in the dnsmasq configuration will cause it
to dump all sorts of useful information.

The option 157 should be quite simple:

dhcp-option=157,"TftpServers=0.0.0.0,FtpServers=X.X.X.X:/ADTRAN,FtpLogin=polycomftp,FtpPassword=password,Layer2Tagging=True,VlanID=Y"

There are a couple of wrinkles which might bite you. If the phone don't
explicitly ask for option 157, it won't be sent. You can check this with
log-dhcp: one of the things logged are the requested options. If you hit
this problem, you can use

dhcp-option-force=157,"TftpServers=0.0.0.0,FtpServers=X.X.X.X..

to make dnsmasq send the option anyway. If you do that and there is
anything else using dnsmasq for DHCP, you should probably take steps to
stop it sending the data to non-phones, come back here for more
information on doing that.

The time offset field is in seconds, I think, multiply the offset in
hours by 3600, so for -5 hours

dhcp-option=2,-18000

the NTP server is simple

dhcp-option=42,1.2.3.4

Finally, the boot server address: for slighly obscure reasons, you might
be best to send this using dhcp-option-force,

so

dhcp-option-force=66,"ftp://polycomftp:password@X.X.X.X/polycom"


Try that lot and see how you get on.


Cheers,

Simon.








More information about the Dnsmasq-discuss mailing list