Skip to content

Instantly share code, notes, and snippets.

@kommen
Forked from MSch/dnsmasq.conf
Created May 19, 2012 10:13

Revisions

  1. kommen revised this gist May 19, 2012. 1 changed file with 10 additions and 4 deletions.
    14 changes: 10 additions & 4 deletions dnsmasq.conf
    Original file line number Diff line number Diff line change
    @@ -24,21 +24,27 @@ no-resolv
    # files for changes and re-read them then uncomment this.
    no-poll

    server=8.8.8.8
    server=8.8.4.4
    server=213.129.232.1
    server=208.67.222.222

    server=/pandora.com/199.167.30.144
    server=/pandora.com/149.154.158.186
    server=/netflix.com/199.167.30.144
    server=/netflix.com/149.154.158.186
    server=/hulu.com/199.167.30.144
    server=/hulu.com/149.154.158.186
    server=/huluim.com/199.167.30.144
    server=/huluim.com/149.154.158.186

    # If you want dnsmasq to listen for DHCP and DNS requests only on
    # specified interfaces (and the loopback) give the name of the
    # interface (eg eth0) here.
    # Repeat the line for more than one interface.
    interface=lo0
    #interface=lo0

    # Or which to listen on by address (remember to include 127.0.0.1 if
    # you use this.)
    listen-address=127.0.0.1
    #listen-address=127.0.0.1

    # On systems which support it, dnsmasq binds the wildcard address,
    # even when it is listening on only some interfaces. It then discards
  2. @MSch MSch created this gist May 10, 2012.
    60 changes: 60 additions & 0 deletions dnsmasq.conf
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,60 @@
    # Configuration file for dnsmasq.
    #
    # Format is one option per line, legal options are the same
    # as the long options legal on the command line. See
    # "/usr/sbin/dnsmasq --help" or "man 8 dnsmasq" for details.

    # The following two options make you a better netizen, since they
    # tell dnsmasq to filter out queries which the public DNS cannot
    # answer, and which load the servers (especially the root servers)
    # unnecessarily. If you have a dial-on-demand link they also stop
    # these requests from bringing up the link unnecessarily.

    # Never forward plain names (without a dot or domain part)
    domain-needed
    # Never forward addresses in the non-routed address spaces.
    bogus-priv

    # If you don't want dnsmasq to read /etc/resolv.conf or any other
    # file, getting its servers from this file instead (see below), then
    # uncomment this.
    no-resolv

    # If you don't want dnsmasq to poll /etc/resolv.conf or other resolv
    # files for changes and re-read them then uncomment this.
    no-poll

    server=8.8.8.8
    server=8.8.4.4

    server=/pandora.com/199.167.30.144
    server=/pandora.com/149.154.158.186

    # If you want dnsmasq to listen for DHCP and DNS requests only on
    # specified interfaces (and the loopback) give the name of the
    # interface (eg eth0) here.
    # Repeat the line for more than one interface.
    interface=lo0

    # Or which to listen on by address (remember to include 127.0.0.1 if
    # you use this.)
    listen-address=127.0.0.1

    # On systems which support it, dnsmasq binds the wildcard address,
    # even when it is listening on only some interfaces. It then discards
    # requests that it shouldn't reply to. This has the advantage of
    # working even when interfaces come and go and change address. If you
    # want dnsmasq to really bind only the interfaces it is listening on,
    # uncomment this option. About the only time you may need this is when
    # running another nameserver on the same machine.
    bind-interfaces

    # Set the cachesize here.
    #cache-size=150

    # If you want to disable negative caching, uncomment this.
    no-negcache

    # For debugging purposes, log each DNS query as it passes through
    # dnsmasq.
    #log-queries