DNS Server Configuration

See also

DNS Resolver

Primary Node

Configure the DNS server on R1 and bind to its LAN interface IP address:

r1 tnsr(config)# unbound server
r1 tnsr(config-unbound)# interface 10.28.0.2
r1 tnsr(config-unbound)# interface 127.0.0.1
r1 tnsr(config-unbound)# access-control 10.28.0.0/24 allow
r1 tnsr(config-unbound)# access-control 127.0.0.0/8 allow
r1 tnsr(config-unbound)# outgoing-interface 203.0.113.28
r1 tnsr(config-unbound)# exit
r1 tnsr(config)# unbound enable

Secondary Node

Configure the DNS server on R2 and bind to its LAN interface IP address:

r2 tnsr(config)# unbound server
r2 tnsr(config-unbound)# interface 10.28.0.3
r2 tnsr(config-unbound)# interface 127.0.0.1
r2 tnsr(config-unbound)# access-control 10.28.0.0/24 allow
r2 tnsr(config-unbound)# access-control 127.0.0.0/8 allow
r2 tnsr(config-unbound)# outgoing-interface 203.0.113.29
r2 tnsr(config-unbound)# exit
r2 tnsr(config)# unbound enable

Dataplane DNS Resolver

Optionally configure the TNSR dataplane to use this DNS server locally in its namespace:

tnsr(config)# system dns-resolver dataplane
tnsr(config-dns-resolver)# server localhost 127.0.0.1
tnsr(config-dns-resolver)# exit

Host DNS Resolver

Configure the host namespace to use external DNS servers as the service in the dataplane namespace cannot be reached directly by the host namespace.

tnsr(config)# system dns-resolver host
tnsr(config-dns-resolver)# server g1 8.8.8.8
tnsr(config-dns-resolver)# server g2 8.8.4.4
tnsr(config-dns-resolver)# exit

Next Steps

If using the NAT DNS redirect method, continue and follow the directions in DNS NAT Redirect (Optional).