I am attempting to set up an internal DNS server that is authoritative for internal resources, but also will respond for external resources on the
same domain that it does not have records for.
For example, I have a domain sub.example.com , and I want to have internal entries in the BIND zone file for host1.sub.example.com and host2.sub.example.com. That part is working fine. However, there is a publicly available DNS entry for sub.example.com that I want my internal clients to be able to resolve, but I donrCOt want to have the IP in the BIND zone file, because the IP is dynamic.
There are also some hosts (host3.sub.example.com ) and (host4.sub.example.com) that are externally resolvable that I donrCOt want
to put in my internal BIND file because they are not controlled by me. (Think CNAME to a SaaS application)
IrCOve attempted to do this as follows, and it seems to make sense that it
would work, but it does not.
named.conf:
zone rCLsub.example.com" IN {
type master;
file "/etc/bind/sub.example.com.zone";
forward first;
forwarders { 1.1.1.1; 1.0.0.1; };
};
What actually happens, is if I query for sub.example.com I get the following from nslookup:
*** Can't find sub.example.com: No answer
And if I query for host3.example.com , I get the following from nslookup:
** server can't find host3.sub.example.com: NXDOMAIN
| Sysop: | Amessyroom |
|---|---|
| Location: | Fayetteville, NC |
| Users: | 65 |
| Nodes: | 6 (0 / 6) |
| Uptime: | 03:55:22 |
| Calls: | 862 |
| Files: | 1,311 |
| D/L today: |
788 files (9,083M bytes) |
| Messages: | 264,528 |