0

I'm trying to resolve my problem with the private DNS server.

I'm in a state where I can successfully resolve public DNS and my local DNS setup in bind9 for my domain for example mydomain.com, but I can't resolve public record for mydomain.com.

I'm not sure how to solve this problem.

Thanks for any help.

Edit: for better understand what exactly doesnt work.

setup on my private NS1: priv1.mydomain.com - 192.168.0.10 priv2.mydomain.com - 192.168.0.10

setup on provider: pub1.mydomain.com

client PC - dig test.mydomain.com @private.NS1 -> 192.168.0.10 -> thats okey

client PC - dig google.com @private.NS1 -> 172.217.23.238 -> thats okey

client PC - dig pub1.mydomain.com @private.NS1 -> no answer

My issue is access both private and public records.

1
  • 1
    You need to give slightly more information than that such as what you have set up, what exactly isn't working including error messages, and the contents of log files. Commented Oct 27, 2021 at 22:34

2 Answers 2

0

You're running authoritative DNS internally and externally. That's fine - it means external lookups get external addresses and internal lookups get internal addresses.

However, because your internal DNS is necessarily authoritative it knows it has all the information for your domain. So if you want pub1.mydomain.com to resolve for internal requests you need to add it to your internal DNS. It doesn't matter that it's already in the external DNS; you still need to add it to your internal one too

2
  • okey then its not possible to automaticaly passthrow dns I need to setup DNS two times
    – gertz
    Commented Oct 28, 2021 at 17:57
  • If you want different DNS results you need either two separate DNS servers or you need to use bind's concept of views, where different results are returned for different IP address ranges. Almost certainly too much work for your situation though, and I don't really recommend it Commented Oct 28, 2021 at 22:22
0
  1. register your domain on registra service, change their default NS server to yours BIND instance.
  2. setup your bind server, (root hint etc.)
  3. your SOA and NS setup correctly on bind.

Basically, dig NS yourdomain.com should point to your BIND server, that is first step, you need to make sure.

1
  • my server will be used only for DNS for local network, but I need acces public record for same domain if this specified recond isnt on private server
    – gertz
    Commented Oct 28, 2021 at 17:18

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .