Upgrading from dns/bind910
to dns/bind911
Upgrading from dns/bind910
to dns/bind911
isn’t particularly difficult. Hopefully, these notes will prepare you for your own endeavour.
As of r455039, these are the runtime dependencies of dns/bind911
:
# make -C /usr/ports/dns/bind911 run-depends-list /usr/ports/databases/lmdb /usr/ports/devel/json-c /usr/ports/devel/libedit /usr/ports/devel/py-ply /usr/ports/dns/idnkit /usr/ports/lang/python27 /usr/ports/security/openssl /usr/ports/textproc/libxml2
If you don’t have DEFAULT_VERSIONS+=ssl=openssl
in /etc/make.conf
, you won’t see security/openssl
among the runtime dependencies.
dns/bind911
has a couple of new dependencies missing on my system:
# make -C /usr/ports/dns/bind911 missing devel/py-ply databases/lmdb
Make sure any missing dependencies are dealt with using, in my case, portupgrade
(8) from ports-mgmt/portupgrade
:
# portupgrade -Nfpv `make -C /usr/ports/dns/bind911 missing`
Edit /usr/local/etc/pkgtools.conf
so that named
(8) is restarted whenever dns/bind911
is installed or updated by portupgrade
(8):
AFTERINSTALL = { 'www/apache24' => localbase() + '/etc/rc.d/apache24 restart', 'dns/bind910' => localbase() + '/etc/rc.d/named restart', 'dns/bind911' => localbase() + '/etc/rc.d/named restart', 'databases/postgresql96-server' => localbase() + '/etc/rc.d/postgresql restart', 'mail/spamassassin' => localbase() + '/etc/rc.d/sa-spamd restart', }
If you use chroot
for dns/bind910
, and subsequently for dns/bind911
:
named_enable="YES" named_chrootdir="/var/Named"
Then you should edit /etc/rc.conf
, adding named
to altlog_proglist
:
altlog_proglist="named"
This tells syslogd
(8) to create a logging socket named /var/Named/var/run/log
. The /var/Named
component is taken from named_chrootdir
in /etc/rc.conf
.
Restart syslogd
(8):
# service syslogd restart
Now, we should be ready to replace dns/bind910
with dns/bind911
:
# portupgrade -fpvo dns/bind911 dns/bind910
Verify with rndc
(8) that named
(8) is indeed up & running, and running as version 9.11.x:
# rndc status version: BIND 9.11.2 <id:0a2b929> running on FQDN: FreeBSD amd64 11.1-STABLE FreeBSD 11.1-STABLE #0 r325889: Thu Nov 16 13:30:54 CET 2017 root@FQDN:/usr/obj/usr/src/sys/GENERIC boot time: Mon, 27 Nov 2017 15:59:31 GMT last configured: Mon, 27 Nov 2017 15:59:31 GMT configuration file: /usr/local/etc/namedb/named.conf (/var/Named/usr/local/etc/namedb/named.conf) CPUs found: 2 worker threads: 2 UDP listeners per interface: 1 number of zones: 163 (1 automatic) debug level: 0 xfers running: 0 xfers deferred: 0 soa queries in progress: 0 query logging is OFF recursive clients: 0/900/1000 tcp clients: 0/150 server is up and running
Finally, you may want to merge any functional differences from the sample configuration file /var/Named/usr/local/etc/namedb/named.conf.sample
into your own configuration file /var/Named/usr/local/etc/namedb/named.conf
. Be sure to reload named
(8) using rndc
(8) after editing the configuration file.
The only functional change I’ve noticed is the removal of BCP 32 domain names:
// Domain Names for Documentation and Testing (BCP 32) zone "test" { type master; file "/usr/local/etc/namedb/master/empty.db"; }; zone "example" { type master; file "/usr/local/etc/namedb/master/empty.db"; }; zone "invalid" { type master; file "/usr/local/etc/namedb/master/empty.db"; }; zone "example.com" { type master; file "/usr/local/etc/namedb/master/empty.db"; }; zone "example.net" { type master; file "/usr/local/etc/namedb/master/empty.db"; }; zone "example.org" { type master; file "/usr/local/etc/namedb/master/empty.db"; };
Krzysztof
I think it is good idea to build your own pkg (poudriere) repository. Then all needed libraries will be added automatically.
I’ve move from portupgrade to my own repo. Also if you use poudriere with “-z” option you can build the same bind911 (as an example) with different options for each server. You can check my own pkg repo: http://pdr.wtp3.org/
I hope I can help a little
Trond Endrestøl
I’m planning to use an idle server as a builder for FreeBSD base. Poudriere, local metaports, and a local repo are something I aim to utilise in time. Thank you for your comments.