I'm trying to do something with BIND and DNS that I'm not sure is possible.
I run the DNS for a domain. Currently, the DNS is run on a box somewhere in the states and serves as the authoritative nameserver. However, some of the hosts in the domain are at my home, behind a NAT. I wish to use the same domain to address those hosts at home.
The problem comes, because if I just have the authoritative external nameserver, I can't put my RFC1918 addressed internal hosts in the zone file - anyone requesting an internal name would get a 192.168.0.0/24 address. Therefore, if I want to keep the same domain for internal hosts, I need to run another nameserver on my internal network for the same domain. This lists both the internal and external hosts for that domain.
So, currently, if a random host on the internet looks up x.growse.com, they ask the external nameserver. If a host on my network looks up x.growse.com, they ask my internal nameserver, which claims to be authoritative for growse.com.
It's a bit of an issue trying to keep the external hosts list consistent between the internal and the external ns - if I make a change on the external one, I need to make the same change on the internal ns so that internal hosts can see it. What I'm really after is probably one of two things:
1) Make my internal NS a slave of the external master, but then extend that domain somehow to include private hosts that only should be resolved inside the network (don't know if BIND can do this?)
2) Make my internal NS a hidden primary for the domain, and get the external NS to be a slave to it. No-one else on the internet uses my internal NS as a resolver (it's hidden). Using BIND's views, I think I still need two separate zone files though, which is what I'm trying to avoid.
So, how do I do this?
I run the DNS for a domain. Currently, the DNS is run on a box somewhere in the states and serves as the authoritative nameserver. However, some of the hosts in the domain are at my home, behind a NAT. I wish to use the same domain to address those hosts at home.
The problem comes, because if I just have the authoritative external nameserver, I can't put my RFC1918 addressed internal hosts in the zone file - anyone requesting an internal name would get a 192.168.0.0/24 address. Therefore, if I want to keep the same domain for internal hosts, I need to run another nameserver on my internal network for the same domain. This lists both the internal and external hosts for that domain.
So, currently, if a random host on the internet looks up x.growse.com, they ask the external nameserver. If a host on my network looks up x.growse.com, they ask my internal nameserver, which claims to be authoritative for growse.com.
It's a bit of an issue trying to keep the external hosts list consistent between the internal and the external ns - if I make a change on the external one, I need to make the same change on the internal ns so that internal hosts can see it. What I'm really after is probably one of two things:
1) Make my internal NS a slave of the external master, but then extend that domain somehow to include private hosts that only should be resolved inside the network (don't know if BIND can do this?)
2) Make my internal NS a hidden primary for the domain, and get the external NS to be a slave to it. No-one else on the internet uses my internal NS as a resolver (it's hidden). Using BIND's views, I think I still need two separate zone files though, which is what I'm trying to avoid.
So, how do I do this?