LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   How can I get bind to resolve military host names? Like gw1.usace.army.mil (https://www.linuxquestions.org/questions/linux-server-73/how-can-i-get-bind-to-resolve-military-host-names-like-gw1-usace-army-mil-4175467317/)

abefroman 06-25-2013 08:23 AM

How can I get bind to resolve military host names? Like gw1.usace.army.mil
 
How can I get bind to resolve military host names? Like gw1.usace.army.mil

Here are the results with bind:
Code:

root@server [~]# host  gw1.usace.army.mil 69.xx.xx.xx
;; connection timed out; trying next origin
Using domain server:
Name: 69.xx.xx.xx
Address: 69.xx.xx.xx#53
Aliases:

And here is a comparison using Google's dns server:
Code:

Host gw1.usace.army.mil not found: 3(NXDOMAIN)
root@server [~]# host  gw1.usace.army.mil 8.8.8.8
Using domain server:
Name: 8.8.8.8
Address: 8.8.8.8#53
Aliases:

gw1.usace.army.mil has address 140.194.153.1

TIA!

tronayne 06-25-2013 09:02 AM

Stick an entry in /etc/hosts for it.

I pinged it, got the address, but it doesn't respond to ping (which I would expect -- it's military).

The form for an /etc/hosts entry would be
Code:

140.194.153.1          gw1.usace.army.mil
I would note that my DNS server (external) did find the address.

Quick and dirty but effective.

Hope this helps some.

abefroman 06-26-2013 08:44 AM

Any other methods? If they ever change the IP of their mail server. then mail will not go through.

Why would Google's dns be picking it up, but not a bind nameserver?

tronayne 06-26-2013 09:41 AM

I don't know enough about BIND to know what it uses for a data base -- I suspect that whatever that may be does not have an entry for it. whois 140.194.153.1 does return information about the network assignment, which you may be able to use but I just don't know enough to know that.

The /etc/hosts method is workable and may be the simplest way to accomplish what you want but, over time, addresses may change and require a change in the /etc/hosts file.

Hopefully somebody more knowledgeable may be able to jump in and give you an workable answer.

jpollard 06-26-2013 09:59 AM

Quote:

Originally Posted by abefroman (Post 4978993)
Any other methods? If they ever change the IP of their mail server. then mail will not go through.

Why would Google's dns be picking it up, but not a bind nameserver?

It implies that your name server is not configured properly. Names it does not know should be forwarded to other name servers until it gets to the root name servers (last I checked there were about 20 of them) which will know the .mil domain.

abefroman 06-26-2013 10:03 AM

Where would that configuration be set at?

jpollard 06-26-2013 02:37 PM

It should be in /var/named, though I have seen it in other directories too. It even may depend on the distribution you are using. The file is named /var/named/named.ca and contains the references to the A-M list (mine has x.ROOT-SERVERS.NET.) each server has multiple instances (.net, .mil, .com, ...). These will respond for both IPv4 and IPv6 addresses.

Now the file may exist - but the bind process must be looking in the right place.

One other possibility (if everything is right) is that your IPv6 is slow to respond, this can make things appear to not work. Usually this causes intermittent failures where a second try (immediately) works, but one that waits a couple of minutes has another timeout. Usual fix is to disable IPv6.


All times are GMT -5. The time now is 03:00 PM.