<div dir="ltr">Because of your configuration, none of those packets are going to dnsmasq at all.  The problem is this line.<br><br>listen-address=127.0.0.1<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, May 30, 2015 at 5:21 PM, Joyabrata Ghosh <span dir="ltr"><<a href="mailto:joy.career@gmail.com" target="_blank">joy.career@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Dear Dnsmasq Experts,</div><div><br></div><div>Myself new to Dnsmasq and facing issues in personally evaluating Auto Caching feature of very popular Dnsmasq product.</div><div><br></div><div>Followed the recommended links inline, however unable to resolve the caching issue, kindly share some expertise advice/pointer to resolve the caching problem, setup details inline:</div><div><br></div><div><br></div><div>Thanks & Regards,</div><div>JGhosh</div><div>Networking developer, Bangalore, India</div><div><br></div><div>==</div><div>==</div><div><br></div><div><div>references official: </div><div><a href="http://www.thekelleys.org.uk/dnsmasq/doc.html" target="_blank">http://www.thekelleys.org.uk/dnsmasq/doc.html</a></div><div><a href="http://www.thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html" target="_blank">http://www.thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html</a></div><div><br></div><div>references other:</div><div><a href="https://help.ubuntu.com/community/Dnsmasq" target="_blank">https://help.ubuntu.com/community/Dnsmasq</a></div><div><a href="http://www.cyberciti.biz/faq/caching-dns-server/" target="_blank">http://www.cyberciti.biz/faq/caching-dns-server/</a></div><div><a href="http://www.georgestarcher.com/splunk-dns-lookup-performance-and-caching-with-dnsmasq/" target="_blank">http://www.georgestarcher.com/splunk-dns-lookup-performance-and-caching-with-dnsmasq/</a></div><div><a href="http://unix.stackexchange.com/questions/162973/how-to-measure-dns-cache-efficiency-cached-items/206403#206403" target="_blank">http://unix.stackexchange.com/questions/162973/how-to-measure-dns-cache-efficiency-cached-items/206403#206403</a></div><div><a href="http://serverfault.com/questions/695441/dnsmasqs-dns-response-auto-caching-feature-not-working" target="_blank">http://serverfault.com/questions/695441/dnsmasqs-dns-response-auto-caching-feature-not-working</a></div><div><a href="http://www.devshed.com/c/a/braindump/managing-a-linux-wireless-access-point/" target="_blank">http://www.devshed.com/c/a/braindump/managing-a-linux-wireless-access-point/</a></div></div><div><br></div><div><b>Problem Description:</b></div><div><b><br></b></div><div>Dnsmasq Cache and Internal Log on USR1 signal dump (when running with or without --no-daemon and --log-queries for analysis) it always shows: 0/0 cache, meaning caching feature of Dnsmasq not working.</div><div><br></div><div>It is also observed that although repetitive DNS A?(host query) and A(response) records are populated successfully over the same listening interface continuously, but cache count still remains 0.</div><div><br></div><div>Any one having any idea how to solve/debug this Dnsmasq Cache Not Working problem ?</div><div><br></div><div>Alternatively, please suggest another Ubuntu linux supported DNS Caching tool which can be configured for targeted interface.</div><div><br></div><div>>  **dnsmasq: cache size 150, 0/0 cache insertions re-used unexpired cache entries**</div><div><br></div><div><br></div><div><br></div><div>    root@host1:~# sudo pkill -USR1 dnsmasq</div><div>    dnsmasq: query[AAAA] host1 from 127.0.0.1</div><div>    dnsmasq: query[AAAA] host1 from 127.0.0.1</div><div>    dnsmasq: query[A] host1 from 127.0.0.1</div><div>    dnsmasq: query[A] host1 from 127.0.0.1</div><div>    sudo: unable to resolve host host1</div><div>    dnsmasq: time 1432979095</div><div>    dnsmasq: cache size 150, 0/0 cache insertions re-used unexpired cache entries.</div><div>    dnsmasq: queries forwarded 0, queries answered locally 4</div><div>    dnsmasq: Host Address Flags Expires</div><div>    dnsmasq: ip6-loopback ::1 6F I H </div><div>    dnsmasq: pep 127.0.1.1 4FRI H </div><div>    dnsmasq: ip6-mcastprefix ff00:: 6FRI H </div><div>    dnsmasq: ip6-allrouters ff02::2 6FRI H </div><div>    dnsmasq: ip6-localhost ::1 6FRI H </div><div>    dnsmasq: localhost 127.0.0.1 4FRI H </div><div>    dnsmasq: ip6-allnodes ff02::1 6FRI H </div><div>    dnsmasq: ip6-localnet fe00:: 6FRI H </div><div>    [1]- User defined signal 1 /etc/init.d/dnsmasq restart</div><div>    root@host1:~#</div><div><br></div><div>    TCPDUMP ON DNSMASQ Interface:</div><div><br></div><div>    05:40:47.555213 IP 172.20.20.10.52592 > 172.20.20.2.53: 8856+ A? <a href="http://app.host2.com" target="_blank">app.host2.com</a>. (45)</div><div>    05:40:47.558364 IP 172.20.20.2.53 > 172.20.20.10.52592: 8856* 1/0/0 A 10.60.60.190 (61)</div><div>    05:41:52.875128 IP 172.20.20.10.60448 > 172.20.20.2.53: 11981+ A? <a href="http://app.host2.com" target="_blank">app.host2.com</a>. (45)</div><div>    05:41:52.878377 IP 172.20.20.2.53 > 172.20.20.10.60448: 11981* 1/0/0 A 10.60.60.190 (61)</div><div>    05:42:44.241724 IP 172.20.20.10.65300 > 172.20.20.2.53: 6667+ A? <a href="http://app.host2.com" target="_blank">app.host2.com</a>. (45)</div><div>    05:42:44.244808 IP 172.20.20.2.53 > 172.20.20.10.65300: 6667* 1/0/0 A 10.60.60.190 (61)</div><div><br></div><div>    Dnsmasq setting: /etc/dnsmasq.conf</div><div><br></div><div>    log-facility=/var/log/dnsmasq.log</div><div>    log-queries</div><div>    log-dhcp</div><div>    no-daemon</div><div>    listen-address=127.0.0.1</div><div>    port=53</div><div>    interface=eth0</div><div>    bind-interfaces</div><div>    cache-size=1000</div><div>    neg-ttl=3600</div><div><br></div><div>    Dnsmasq Running as inline from default:</div><div><br></div><div>    root@host1:~# /etc/init.d/dnsmasq restart</div><div>    * Restarting DNS forwarder and DHCP server dnsmasq                                                                                   </div><div>    dnsmasq: started, version 2.68 cachesize 1000</div><div>    dnsmasq: compile time options: IPv6 GNU-getopt DBus i18n IDN DHCP </div><div>    DHCPv6 no-Lua TFTP conntrack ipset auth</div><div>    dnsmasq: reading /etc/resolv.conf</div><div>    dnsmasq: using nameserver 11.45.45.9#53</div><div>    dnsmasq: read /etc/hosts - 7 addresses</div><div>    User defined signal 1</div><div>    root@host1:~# dnsmasq: time 1433019086</div><div>    dnsmasq: cache size 1000, 0/0 cache insertions re-used unexpired cache </div><div>    entries.</div><div>    dnsmasq: queries forwarded 0, queries answered locally 0</div><div>    dnsmasq: queries for authoritative zones 0</div><div>    dnsmasq: Host                                     Address                           </div><div>    Flags     Expires</div><div>    dnsmasq: ip6-allnodes                             ff02::1                        </div><div>    6FRI   H   </div><div>    dnsmasq: ip6-localnet                             fe00::                         </div><div>    6FRI   H   </div><div>    dnsmasq: ip6-localhost                            ::1                            </div><div>    6FRI   H   </div><div>    dnsmasq: pep                                      127.0.1.1                      </div><div>    4FRI   H   </div><div>    dnsmasq: ip6-mcastprefix                          ff00::                         </div><div>    6FRI   H   </div><div>    dnsmasq: localhost                                127.0.0.1                      </div><div>    4FRI   H   </div><div>    dnsmasq: ip6-loopback                             ::1                            </div><div>    6F I   H   </div><div>    dnsmasq: ip6-allrouters                           ff02::2                        </div><div>    6FRI   H   </div><div><br></div><div>    Dnsmasq process status:</div><div><br></div><div>    root@host1:~# ps aux | grep dnsmasq</div><div>    dnsmasq  23437  0.0  0.0  27636   936 ?        S    16:36   0:00  </div><div>    /usr/sbin/dnsmasq -x /var/run/dnsmasq/dnsmasq.pid -u dnsmasq </div><div>    -r /var/run/dnsmasq/resolv.conf -7 /etc/dnsmasq.d,.dpkg-dist,.dpkg-</div><div>    old,.dpkg-new</div><div><br></div><div>    Dnsmasq package status:<br></div><div><br></div><div><div>    root@host1:~# dpkg -l | grep dnsmasq</div><div>    ii  dnsmasq                                               2.68-1                                              all          Small caching DNS proxy and DHCP/TFTP server</div><div>    ii  dnsmasq-base                                          2.68-1                                          amd64        Small caching DNS proxy and DHCP/TFTP server</div><div>    ii  dnsmasq-utils                                         2.68-1                                             amd64        Utilities for manipulating DHCP leases</div></div><div><br></div><div>==</div><div>==</div></div>
<br>_______________________________________________<br>
Dnsmasq-discuss mailing list<br>
<a href="mailto:Dnsmasq-discuss@lists.thekelleys.org.uk">Dnsmasq-discuss@lists.thekelleys.org.uk</a><br>
<a href="http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss" target="_blank">http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss</a><br>
<br></blockquote></div><br></div>