LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   which is my nameserver. (https://www.linuxquestions.org/questions/linux-networking-3/which-is-my-nameserver-343428/)

bruse 07-15-2005 08:28 AM

which is my nameserver.
 
mandrake 10.0

i am using squid proxy server for internet in my university.

i have a DNS problem.
which is my nameserver for /etc/resolv.conf file.
i know the proxy server IP address.
which address should use for nameserver.

where the squid proxy server look for name resolution or IP translation.

evilchild 07-15-2005 08:46 AM

Your proxy server or your router, depending on your networks setup, may act as your name server, also try a 'nslookup' and the check the servers ip address it uses during it's queries.

demian 07-15-2005 08:48 AM

The nslookup only works if you already have a nameserver. You should have gotten that information from your network people. If you don't have a nameserver you can find the one for your domain by doing a query starting with the root servers. For example to find the nameserver for the domain uni-bremen.de do:

Code:

demian@dirac ~$ dig uni-bremen.de ns @192.5.5.241
[a bunch of output snipped]
;; ADDITIONAL SECTION:
A.NIC.de.              172800  IN      A      193.0.7.3
[more output here]

demian@dirac ~$ dig uni-bremen.de ns @193.0.7.3
[a bunch of output snipped]
;; QUESTION SECTION:
;uni-bremen.de.                IN      NS

;; AUTHORITY SECTION:
uni-bremen.de.          86400  IN      NS      ines.zfn.uni-bremen.de.
uni-bremen.de.          86400  IN      NS      alf.zfn.uni-bremen.de.
uni-bremen.de.          86400  IN      NS      ns.informatik.uni-bremen.de.
uni-bremen.de.          86400  IN      NS      ws-kar1.win-ip.dfn.de.

;; ADDITIONAL SECTION:
ines.zfn.uni-bremen.de. 86400  IN      A      134.102.20.20
alf.zfn.uni-bremen.de.  86400  IN      A      134.102.20.22
ns.informatik.uni-bremen.de. 86400 IN  A      134.102.200.14
ws-kar1.win-ip.dfn.de.  86400  IN      A      193.174.75.154
[more output here]

Now you have them: The DNS servers for uni-bremen.de are 134.102.20.20, 134.102.20.22, 134.102.200.14 and 193.174.75.154

The server with ip 192.5.5.241 is one of the root servers (f.root-servers.net). So the first command asks the root server for the name server of the domain uni-bremen.de. The root server answers with the servers that are authorative for the top level domain .de. The next query again asks for the dns server of uni-bremen.de but this time it asks the de server a.nic.de (193.0.7.3). This server knows the answer.

If the domain name were longer you just keep going, eg if you want the dns server of physik.uni-bremen.de you ask either of the four servers that were found to be dns servers for uni-bremen.de (ie dig physik.uni-bremen.de ns @134.102.20.20).

bruse 07-16-2005 01:45 AM

I HAVE THIS OUTPUT.

[root@localhost student]# dig physik.uni-bremen.de ns @134.102.20.20

; <<>> DiG 9.2.3 <<>> physik.uni-bremen.de ns @134.102.20.20
;; global options: printcmd
;; connection timed out; no servers could be reached
[root@localhost student]#


All times are GMT -5. The time now is 10:11 AM.