-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DIG from external network not working the same as dig from LAN #1451
Comments
The external network needs to be explicitly configured to forward requests for the The typical approach is to use Consul for DNS-based service discovery inside your network and expose services via a load balancer (hardware or software) behind a publicly resolvable hostname. So, you would point |
I have consul running as my DNS server on 53 I would think if i am requesting DNS records from consul it would already know how to resolve the .consul addresses |
What error do you get when you run from the external network? |
I don't see an error i just get a different DNS response ; <<>> DiG 9.8.3-P1 <<>> @[myhost].com zookeeper.service.consul. A ;; QUESTION SECTION: ;; AUTHORITY SECTION: ;; Query time: 2 msec I have recurse also configured in my consul cluster so if it cant resolve something it would it will allow another Public DNS server to do so |
From what i can see consul does not know how to resolve so it passes it to another DNS server which eventually resolve to a root authoritative one |
I have also tried my service configured to both an internal/public IP and the same behavior was observed |
Please paste the dig command you're running externally and its results. |
dig @treverpietsch.com zookeeper.service.consul SRV ; <<>> DiG 9.8.3-P1 <<>> @treverpietsch.com zookeeper.service.consul SRV ;; QUESTION SECTION: ;; AUTHORITY SECTION: ;; Query time: 5 msec same command internal/external has different answers my initial post has the response form a local network |
also THANKS for the speedy response :) |
OK, and you are certain that port 53 on Can you paste the config from your Consul server? Also, I noticed that in your example output from dig on an external network, the response is for an |
{
"server":true, "enable_truncate" : true |
{"service": { |
i agree with you statement that is why i am confused. im literally running dig using the same dns host from different machines |
the dig does return an SRV record in the initial post |
;; ANSWER SECTION: |
Right, I was referring to this follow-up:
|
maybe because there are no answers A records are like a fall back? I would need to do some research on that not super familiar with anything above the basic DNS stuff. the dig versions are different on the machines? When i was on my LAN i was able to use consul as my DNS server tho so i doubt that is the issue. |
dig @[myhost].com zookeeper.service.consul SRV
on the local network consul is running on returns an answer
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 28494
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1
;; QUESTION SECTION:
;zookeeper.service.consul. IN SRV
;; ANSWER SECTION:
zookeeper.service.consul. 0 IN SRV 1 1 2181 ubuntu.node.dc1.consul.
;; ADDITIONAL SECTION:
ubuntu.node.dc1.consul. 0 IN A [external public ip]
;; Query time: 5 msec
;; SERVER: [hostip]#53([hostip])
;; WHEN: Fri Nov 27 10:04:08 PST 2015
;; MSG SIZE rcvd: 146
but running the same command returns no answers when run on an external network.
The text was updated successfully, but these errors were encountered: