Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: dhcpcd ignores netmask from server, installs /8 or /24 instead



On Sat, 13 Dec 2014, Roy Marples wrote:

> On Friday 12 Dec 2014 17:40:06 John D. Baker wrote:
> > Clever as 'dhcpcd' may be, I gave it a shot but it's just not the right
> > tool for this situation--netmask issues aside.
> 
> netmask issues aside, why is dhcpcd not the right tool so they can be 
> addressed please?
> dhclient has long be slated for removal from base.

I require an equivalent to 'dhclient's ability to install an alias
address.  While the dynamic address should be primary, I need an alias
so I can access the configuration/troubleshooting interface in my ADSL
bridge.  (I have a suitable NAT rule in the firewall configuration.)

If 'dhcpcd' already posesses this ability, it is not clear how it is
configured.

In my early experiments, if the lease expired without renewal (upstream
router falls over for 3-8 hours), when a new lease was acquired my
manually-installed alias was promoted to the primary address and the
new dynamic address was installed as an alias--this broke my NAT/filter
as my rules (in 'pf') insist on the primary ("if_foo:0") address for
general NAT and filtering.

While the "noalias" directive fixed that, it also removed my alias
address, requiring manual intervention to reinstall it before I could
access the ADSL bridge's configuration/troubleshooting interface.


I'd like something akin to 'dhclient's "prepend" and "supersede" directives
for various DHCP options.  In particular, to enforce the use of my own
NTP servers and prefer the use of my own DNS servers.  I've worked around
it by using the "no-hook" directive with the relevant hook scripts and
maintaining a static "/etc/resolv.conf" and "/etc/ntp.conf".

I tried using the "static foo-option args..." directive in "dhcpcd.conf",
but they were ignored, or added AFTER the data from the DHCP server.

Perhaps in conjuction with the "no-option" directive to suppress
undesired options?

-- 
|/"\ John D. Baker, KN5UKS               NetBSD     Darwin/MacOS X
|\ / jdbaker[snail]mylinuxisp[flyspeck]com    OpenBSD            FreeBSD
| X  No HTML/proprietary data in email.   BSD just sits there and works!
|/ \ GPGkeyID:  D703 4A7E 479F 63F8 D3F4  BD99 9572 8F23 E4AD 1645



Home | Main Index | Thread Index | Old Index