[Dnsmasq-discuss] Looking up local names doesn't work

richardvoigt at gmail.com richardvoigt at gmail.com
Mon May 28 04:50:01 BST 2012


On Sun, May 27, 2012 at 10:15 PM, ian <ian_malcolm at sjtu.edu.cn> wrote:

> Hello
>
> I'm currently working a DNS server in a local area network. DHCP service
> is given by another server which is not under my control. Names on the
> internet are working fine, but looking up local names doesn't seem to work.
>


Does the DHCP server serve those names somehow (via DNS, or stored in a
database) that you can reach?  dnsmasq can't magically find out the name
that a client sent to some other DHCP server.



>
>   IP note hostname  192.168.100.229 DNS LOEA-T7500.ic.sjtu.edu.cn
> 192.168.100.75 a host LOEA-VM004.ic.sjtu.edu.cn  192.168.100.31 a host
> LOEA-VM002.ic.sjtu.edu.cn  192.168.100.201 DHCP  202.120.2.101 upstream
> DNS  202.112.26.34 upstream DNS
>
> I use "dig" on LOEA-VM004 to see if I can get LOEA-VM002 resolved via dns,
> but there is no answer:
>
> [ian at LOEA-VM004 ~]$ dig LOEA-VM002
> ; <<>> DiG 9.3.6-P1-RedHat-9.3.6-4.P1.el5 <<>> LOEA-VM002
> ;; global options:  printcmd
> ;; Got answer:
> ;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 38313
> ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0
>
> ;; QUESTION SECTION:
> ;LOEA-VM002.INA
>
> ;; AUTHORITY SECTION:
> .10402INSOAa.root-servers.net. nstld.verisign-grs.com. 2012052601 1800
> 900 604800 86400
>
> ;; Query time: 2 msec
> ;; SERVER: 192.168.100.229#53(192.168.100.229)
> ;; WHEN: Mon May 28 10:08:31 2012
> ;; MSG SIZE  rcvd: 103
>
> At the same time, I use tcpdump to listen on DNS server
>
> [root at LOEA-T7500 ian]# tcpdump \(host 192.168.100.229 and port and port
> 53\) or \(host 192.168.100.201\) -nnvv
> tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 96
> bytes
> 10:07:23.390606 IP (tos 0x0, ttl  64, id 31380, offset 0, flags [none],
> proto: UDP (17), length: 56) 192.168.100.75.36380 > 192.168.100.229.53:
> [udp sum ok]  38313+ A? LOEA-VM002. (28)
> 10:07:23.390765 IP (tos 0x0, ttl  64, id 0, offset 0, flags [DF], proto:
> UDP (17), length: 56) 192.168.100.229.34909 > 192.168.100.201.53: [bad udp
> cksum 14c2!]  51850+ A? LOEA-VM002. (28)
> 10:07:23.390771 IP (tos 0x0, ttl  64, id 0, offset 0, flags [DF], proto:
> UDP (17), length: 56) 192.168.100.229.34909 > 202.112.26.34.53: [bad udp
> cksum d343!]  51850+ A? LOEA-VM002. (28)
> 10:07:23.390774 IP (tos 0x0, ttl  64, id 0, offset 0, flags [DF], proto:
> UDP (17), length: 56) 192.168.100.229.34909 > 202.120.2.101.53: [bad udp
> cksum 3d73!]  51850+ A? LOEA-VM002. (28)
> 10:07:23.390962 IP (tos 0x0, ttl  64, id 22929, offset 0, flags [none],
> proto: ICMP (1), length: 84) 192.168.100.201 > 192.168.100.229: ICMP
> 192.168.100.201 udp port 53 unreachable, length 64
>  IP (tos 0x0, ttl  64, id 0, offset 0, flags [DF], proto: UDP (17),
> length: 56) 192.168.100.229.34909 > 192.168.100.201.53:  51850+[|domain]
> 10:07:23.391730 IP (tos 0x0, ttl  59, id 6539, offset 0, flags [none],
> proto: UDP (17), length: 131) 202.112.26.34.53 > 192.168.100.229.34909:
>  51850 NXDomain q: A? LOEA-VM002. 0/1/0 ns: . SOA[|domain]
> 10:07:23.391772 IP (tos 0x0, ttl  64, id 0, offset 0, flags [DF], proto:
> UDP (17), length: 131) 192.168.100.229.53 > 192.168.100.75.36380:  38313
> NXDomain q: A? LOEA-VM002. 0/1/0 ns: . SOA[|domain]
> 10:07:23.391967 IP (tos 0x0, ttl  59, id 32177, offset 0, flags [none],
> proto: UDP (17), length: 131) 202.120.2.101.53 > 192.168.100.229.34909:
>  51850 NXDomain q: A? LOEA-VM002. 0/1/0 ns: . SOA[|domain]
>
> Here is /etc/hosts /etc/dnsmasq.conf /etc/resolv.dnsmasq.conf
> and /etc/resolv.conf on LOEA-T7500
>
> # Do not remove the following line, or various programs
> # that require network functionality will fail.
> 127.0.0.1 localhost
> #127.0.0.1 LOEA-T7500.ic.sjtu.edu.cn LOEA-T7500
> ::1 localhost6.localdomain6 localhost6
> 127.0.0.1 LOEA-T7500 # added by Apache Friends XAMPP
>
> resolv-file=/etc/resolv.dnsmasq.conf
> expand-hosts
> domain=ic.sjtu.edu.cn
> conf-dir=/etc/dnsmasq.d
>
> search ic.sjtu.edu.cn
> domain ic.sjtu.edu.cn
> nameserver 192.168.100.201
> nameserver 202.112.26.34
> nameserver 202.120.2.101
>
> ; generated by /sbin/dhclient-script
> search ic.sjtu.edu.cn
> nameserver 127.0.0.1
> ;nameserver 192.168.100.201
> ;nameserver 202.112.26.34
> ;nameserver 202.120.2.101
>
> I ping LOEA-T7500 on LOEA-VM004, it is resolved as 127.0.0.1.
> And here is the ip-hostname list on DHCP, I mean those hosts do send their
> hostnames to DHCP when asking for a lease.
>
> 192.168.100.31  - 255.255.255.0  - ea-b3-8d-73-71-65   -2012/5/28 15:07:09
>     -D-  LOEA-VM002.ic.sjtu.edu.cn
> 192.168.100.75  - 255.255.255.0  - 06-96-c1-4f-04-43   -2012/5/28 16:05:50
>     -D-  LOEA-VM004.ic.sjtu.edu.cn
>
> How can I solve this problem? Thank you.
>
> --
> Huangtian
> Shanghai Jiao Tong University
>
>
> _______________________________________________
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss at lists.thekelleys.org.uk
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.thekelleys.org.uk/pipermail/dnsmasq-discuss/attachments/20120527/3921ad61/attachment-0001.html>


More information about the Dnsmasq-discuss mailing list