Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 15 Jun 2020 14:17:46 +0200
From:      Goran =?utf-8?B?TWVracSH?= <meka@tilda.center>
To:        Andriy Gapon <avg@FreeBSD.org>
Cc:        Ryan Steinmetz <zi@FreeBSD.org>, jaap@NLnetLabs.nl, net@FreeBSD.org
Subject:   Re: unbound and (isc) dhcpd startup order
Message-ID:  <20200615121746.z5yimfnhfm2xafzm@tilda.center>
In-Reply-To: <3ace8441-a59b-8667-ed32-324853360281@FreeBSD.org>
References:  <3ace8441-a59b-8667-ed32-324853360281@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--vh7iy2uhf6z5lrdc
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline

On Mon, Jun 15, 2020 at 09:10:18AM +0300, Andriy Gapon wrote:
>
> I am configuring a small LAN -- mostly a gateway / router for it -- and I am
> using unbound for a local DNS and isc-dhcp44-server for DHCP.
> I have a few hosts with static IP addresses (for various reasons).
> So, in unbound.conf I have an entry like
>   local-data: "hipster.home.arpa. IN A 192.168.0.222"
> and in dhcpd.conf  have:
>   host hipster {
>
>
>     hardware ethernet 40:74:e0:xx:xx:xx;
>
>
>     fixed-address hipster.home.arpa;
>
>
>  }
>
> I am using a DNS name to avoid hardcoding the same IP address twice.
> But obviously this depends on the local DNS server starting before the HDCP
> server if they are on the same host / router.
> It seems that at the moment there is nothing to ensure that order.
>
> For the moment I modified rc.d/unbound to add this line:
>   # BEFORE: dhcpd
> I am not sure if this is the best solution and it's something that can be
> included into the port.
>
> On a related note, unbound rc script provides "unbound" service.
> I think that maybe it should provide something more generic such as "nameserver"
> or "dns-server" (not sure if there is an established name for that).
> The reason I am saying this is that, IMO, if unbound is replaced with some other
> name server implementation the rc dependency chains should stay the same.
>
> Thanks!
> --
> Andriy Gapon

It might not be the exact answer you're looking for, but you might get
some idea. I run isc-dhcpd inside CBSD jail and CBSD is started after
local_unbound. For most of my needs, CBSD's b_order (short for boot
order) works nicely, so if jail is an option for you, you might consider
having services in jails and then use your jail manager (does jail.conf
boots jails in order they appear in .conf file or is otherwise able to
sort jail startups?) to force jail startup order.

Regards,
meka

--vh7iy2uhf6z5lrdc
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEE1WIFkXy2ZeMKjjKEWj1TknovrLYFAl7nZucACgkQWj1Tknov
rLYcDA/7B8lqAD1J0wGY9UWmdExzQEPjYeajFd0keFEIauEcNJViUa+tJBlm4UOd
jxxw672x9MsmBSmiRfwxLAzBqxAQ5DLgNXJ0FCm0V4MkhoNd+4deLE7CC3XluGtM
/qtm2gtBKlYw0BXIfVhePhUR9LhpdGVa3btkfu1lVGk3ExMo7BoEmn+wh14np1e5
76NckukAer+2gVsClWSDPds/DIXAtBExTdLvrFocD6ZHzlrcKxpH9QLXfDXGojma
u8H1QWnKMWP2OfRTBi/yXxEvP5fjFpEjii6mUgEx0rsK+EmzOGM4cyh7bKY0pXTb
oQ9HubSuxkkWYHu1FhHPSyJhT8+7vpzhA968zye6qGtWiYnHThrHy/n2xTHk9o5l
dp+QOkoICKFlpfansOmQY2SvqqGUPTa82D8JIvGrfWOtMeBOY8sQlkugsZgPmUs9
o9BB3o504O/lnZWnjQfv5RnACw1tMkWnRuFDCfhzJnPbf3XaBqoV5zeaNSqkBZSM
ntOoFanNzc+RK27PtA2rTbBetfe4chr3onI5gpWYmnwIVm5o1+r2/zUbXg8NfUtE
eEafpRNmh4zvzhd1Z1Xz/ZXxiPKPSC3t+O3rzuN02+t//It8h+hGG6vQCxujXAMU
e26JcxkCN7crBljE4rVd9dFRu7x9izLTMphuXOxcRPDfMQwoqvg=
=A5WP
-----END PGP SIGNATURE-----

--vh7iy2uhf6z5lrdc--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20200615121746.z5yimfnhfm2xafzm>