Limiting Linux DNS server with Multiple ethernet cards?

Limiting Linux DNS server with Multiple ethernet cards?

Post by Dan Lange.uni.ed » Sun, 06 Dec 1998 04:00:00



I have a linux box running here, and it has 3 ethernet cards installed.

   +-----------------+
    |                                         | --   eth0  ->  Internet
    |         linux box                 | --    eth1  ->  Private
network (Win95 boxes)
    |                                         | --    eth2  ->  Private
network (Sun4c boxes)
   +-----------------+

I only need to provide DNS service to the Win95 boxes, as the Sun4s
function as xterms and boot off the server.   However, I do need to
request my DNS information through eth0, but I don't want to be
providing DNS service out through eth0.

I have configured it according to
http://metalab.unc.edu/pub/Linux/docs/HOWTO/DNS-HOWTO  and it functions
well, but the networking policy here states that I can't be serving
DNS back out over the Internet.

The networking officials said that I must use these certain DNS servers,
as opposed to querying the root DNS servers... Also, the university has
more DNS servers that they said I couldn't use, but I found more than
twice as many here using nslookup.

A look at a couple files....

/etc/resolv.conf
nameserver 127.0.0.1
domain resnet.uni.edu
search uni.edu cns.uni.edu cs.uni.edu resnet.uni.edu

/etc/named.conf
// Config file for caching only name server

options {
          directory "/var/named";

        // Uncommenting this might help if you have to go through a
        // firewall and things are not working out:

        // query-source port 53;

Quote:};

zone "." {
        type hint;
        notify no;
        file "root.hints";

Quote:};

zone "0.0.127.in-addr.arpa" {
        type master;
        notify no;
        file "pz/127.0.0";

Quote:};

/var/named/root.cache
 .       518400  NS      DNS.UNI.EDU.
 .       518400  NS      ISCSSUN.UNI.EDU.
 .       518400  NS      COBRA.UNI.EDU.
 .       518400  NS      DNS3.UIOWA.EDU.
 .       518400  NS      NS-1.IASTATE.EDU.
;
DNS.UNI.EDU.     3600000 A       134.161.1.32
ISCSSUN.UNI.EDU.     3600000 A       134.161.14.20
COBRA.UNI.EDU.     3600000 A       134.161.1.11
DNS3.UIOWA.EDU.     3600000 A       128.255.1.8
NS-1.IASTATE.EDU.     3600000 A       129.186.1.200

/var/named/root.hints

.                     6D IN NS        G.ROOT-SERVERS.NET.
.                     6D IN NS        J.ROOT-SERVERS.NET.
.                     6D IN NS        K.ROOT-SERVERS.NET.
.                     6D IN NS        L.ROOT-SERVERS.NET.
.                     6D IN NS        M.ROOT-SERVERS.NET.
.                     6D IN NS        A.ROOT-SERVERS.NET.
.                     6D IN NS        H.ROOT-SERVERS.NET.
.                     6D IN NS        B.ROOT-SERVERS.NET.
.                     6D IN NS        C.ROOT-SERVERS.NET.
.                     6D IN NS        D.ROOT-SERVERS.NET.
.                     6D IN NS        E.ROOT-SERVERS.NET.
.                     6D IN NS        I.ROOT-SERVERS.NET.
.                     6D IN NS        F.ROOT-SERVERS.NET.

G.ROOT-SERVERS.NET.     5w6d16h IN A    192.112.36.4
J.ROOT-SERVERS.NET.     5w6d16h IN A    198.41.0.10
K.ROOT-SERVERS.NET.     5w6d16h IN A    193.0.14.129
L.ROOT-SERVERS.NET.     5w6d16h IN A    198.32.64.12
M.ROOT-SERVERS.NET.     5w6d16h IN A    202.12.27.33
A.ROOT-SERVERS.NET.     5w6d16h IN A    198.41.0.4
H.ROOT-SERVERS.NET.     5w6d16h IN A    128.63.2.53
B.ROOT-SERVERS.NET.     5w6d16h IN A    128.9.0.107
C.ROOT-SERVERS.NET.     5w6d16h IN A    192.33.4.12
D.ROOT-SERVERS.NET.     5w6d16h IN A    128.8.10.90
E.ROOT-SERVERS.NET.     5w6d16h IN A    192.203.230.10
I.ROOT-SERVERS.NET.     5w6d16h IN A    192.36.148.17
F.ROOT-SERVERS.NET.     5w6d16h IN A    192.5.5.241


root.bogus.resnet.uni.edu (
                                1       ; Serial
                                8H      ; Refresh
                                2H      ; Retry
                                1W      ; Expire
                                1D)     ; Minimum TTL
                        NS      ns.bogus.resnet.uni.edu.
1                       PTR     localhost.

Here's what the /var/log/messages says...

Dec  5 12:38:35 2087 named[147]: starting.  named 8.1.2 Sat May 23

Dec  5 12:38:36 2087 named[147]: cache zone "" (IN) loaded (serial 0)
Dec  5 12:38:36 2087 named[147]: master zone "0.0.127.in-addr.arpa" (IN)
loaded (serial 1)
Dec  5 12:38:36 2087 named[147]: listening on [127.0.0.1].53 (lo)
Dec  5 12:38:36 2087 named[147]: listening on [134.161.145.95].53 (eth0)

Dec  5 12:38:36 2087 named[147]: listening on [192.168.2.1].53 (eth1)
Dec  5 12:38:36 2087 named[147]: listening on [192.168.3.1].53 (eth2)
Dec  5 12:38:36 2087 named[147]: Forwarding source address is
[127.0.0.1].1390
Dec  5 12:38:36 2087 named[148]: Ready to answer queries.

Is there any way that I can limit named so it only listens on eth1?  I
only need to serve up DNS to 192.168.2.x networks.   I'm currently
running bind-8 on top of Slackware Linux 2.0.30.

Any suggestions would be appreciated. Please reply by email as well.
Thank you.

Dan

 
 
 

1. How can ethernet card get multiple IP from DHCP server ?

I've got linux 2.6 router with 2 ethernet cards. eth0 is connected to
internet provider that assigns IP numer from  DHCP server, eth1 is
connected to LAN.

provider gives me unlimited number of external IPs, when I'm
connecting devices.

I would like my linux server to get couple external IPs. So Eth0 shoud
have multiple MAC addresses. How can it be done ?

Seems like solvation is described here http://en.wikipedia.org/wiki/Proxy_ARP
(Taking multiple addresses from a LAN), but can anyone give me live
example ?

thanx in advance !

2. What's the kernel nfs* for?

3. Multiple ethernet cards to increase server speed?

4. Linux vs SBS question

5. Multiple Ethernet cards (for proxy server setup)

6. Strange connection problem

7. Machine with multiple ethernet cards to Ethernet Switch (SS20/2.5)

8. Batch files

9. NT dns server request to my LINUX dns server time out

10. Linux-Multiple ip address bound to one ethernet card?

11. Multiple ethernet cards in Linux 2.0.30

12. multiple ethernet card on Sparc with Linux