Description | The article details a simple setup example for using FortiGate as a secondary DNS Server when Bind9 is the primary. |
Scope | FortiOS. |
Solution |
FortiOS allows for the FortiGate to be configured as a secondary DNS server. This is useful in such setups where there is a hidden primary server that manages the zone files that isn't listed. DNS can be manged from a hidden server which is then replicated to secondary servers which can provide address resolution. An advantage of using the FortiGate as a secondary server is locally being able to cache and resolve DNS requests for a particular zone while being managed by existing infrastructure.
In this example, the primary DNS server is utilizing Bind9 for the management of zone 'forti.test'. Existing Bind9 configuration is assumed.
FortiGate configuration:
config system dns-database edit "Forti Test Zone" end
config system dns-server edit "LAN" end
In this example FortiGate will respond to DNS requests on the LAN interface at address 10.1.6.1.
Bind9 Configuration: named.conf // Do any local configuration here zone "forti.test" { type master;
forti.test (example zone file) $TTL 3600 ns1 IN A 10.1.6.1
After the FortiGate IP is added to 'allow-transfer' and 'allow-notifiy', refresh the Bind9 DNS configuration.
$ rndc reload
Afterwards when Bind9 comes back, the following similar messaging should be seen in the logs:
general: notice: all zones loaded
In FortiGate DNS debug, the zone is loaded into the local FortiGate Database:
FortiGate # diagnose test application dnsproxy 8
Dig Test Confirmation:
$ dig @10.1.6.1 fortiswitch.forti.test ; <<>> DiG 9.16.44-Debian <<>> @10.1.6.1 fortiswitch.forti.test ;; QUESTION SECTION: ;; ANSWER SECTION: ;; AUTHORITY SECTION: ;; ADDITIONAL SECTION: ;; Query time: 0 msec
|
The Fortinet Security Fabric brings together the concepts of convergence and consolidation to provide comprehensive cybersecurity protection for all users, devices, and applications and across all network edges.
Copyright 2024 Fortinet, Inc. All Rights Reserved.