Split Horizon DNS #912
-
Hello, I'm attempting to implement Split Horizon DNS. I have the split horizon installed already. My LAN is 10.7.0.0/16, the Technitium DNS server's IP is I have domain.xyz. Once Technituim DNS is setup I'll tell the registrar to use my public IP address as a NS. Externally Technitium will also give out my public IP address (or something else if needed) when replying to domain.xyz and *.domain.xyz; internally, Technitium will resolve to the various IP addresses I have for different services (Metal-LB). I'll have some API integration (since my public IP can change from time to time), but I'll figure that out later. For now, I'm testing with my-domain.com to see if I can get basic horizon splitting working. For context, my network is setup as such:
So, queries from the internet & ext-lan should be considered as "outside", since there's a NAT sitting between them and Technitium. So far, in the Split Horizon app, I have:
I'm not sure what, or if I even need I created a new zone called
Zone details:
But when I try to nslookup from my LAN, I get no results:
I did find a few other discussions, mainly: #815 but unsure what I'm doing wrong. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Thanks for asking.
I have not understood this fully. But if you need to have zone such that it resolves records that you add in it but if there are no records for a query, it should get forwarded to some upstream then you need to use Conditional Forwarder Zone. You can create a forwarder zone for any domain name (you own it or not) and add records to it as required. Anything else gets forwarded to the forwarder specified in FWD records.
If you want to self host your public domain name and also want it to resolve to your internal IP address then you need to use the Split Horizon app. The app has address translation feature which is of no use for your scenario so you should remove any config from the app's main config section. You need to use the APP record in your public zone. The APP record when queried returns answer based on the client's IP address. So, your APP record config should look something like this:
So the above config for APP record will resolve your public IP when request is received from public IP i.e. Internet but will resolve to the private IP when it comes from "lan" (defined in the app's config under the "networks" node). |
Beta Was this translation helpful? Give feedback.
The problem is that the APP record uses
lan
as the custom network but it is not defined in the app's main config. So, either you use10.7.0.0/16
as the key instead or define the custom network in the main config.So, either you use the APP config shown below:
OR, you define the custom network in the Split Horizon app's main config as below: