Questions tagged [dnsmasq]

dnsmasq is a lightweight DHCP, DNS and TFTP server application for *nix platforms intended for use on small and home networks.

407 questions
32
votes
2 answers

Using dnsmasq to resolve all hosts to the same address

I'm running Ubuntu server on a computer used as a wireless AP, but this AP should resolve all DNS requests to an internal IP address rather than actually performing the lookup. I want to do the same thing that paid public WiFi hotspots do - you can…
Matt
  • 625
  • 1
  • 7
  • 14
29
votes
3 answers

How do you get dnsmasq to specify alternate DNS servers?

I'm working on a network with ~10 kubuntu desktops (and numerous servers and IP phones) and am trying to get dnsmasq to specify another dns server as a failover. I tried using server=192.168.0.90 but that just added the single dhcp/dns server to…
pfyon
  • 943
  • 1
  • 7
  • 10
24
votes
1 answer

How to enforce dnsmasq to use an upstream dns server only for some specified domain names?

Right now I've got the following line in dnsmasq.conf, which handles well all requests (/#/ matches any domain; this is required): address=/#/127.0.0.1 Yet, there are some domains which require to be resolved to IP addresses other than…
nrph
  • 355
  • 1
  • 2
  • 6
22
votes
2 answers

Setting up dnsmasq for a local network

I and a small group of developers have just moved to a new office, and I'd like to set up dnsmasq on our development server, so when we deploy web apps there, we don't have to edit our own hosts files. We have a router at 192.168.3.1 which we don't…
K. Norbert
  • 437
  • 1
  • 3
  • 10
17
votes
3 answers

Find out which DNS server answered your query

I have a seemingly simple question but couldn't find the answer to precisely that question after some search: I know that, if I want to look up the IP address of some domain name, I type, for example: nslookup google.de and get Server: …
Staki42
  • 273
  • 1
  • 2
  • 5
17
votes
4 answers

Disable dhcp service in dnsmasq

I would like to use only dnsmasq to forward all dns requests to google's dns server and disable dhcp... How can I achieve this result?
Pitto
  • 2,009
  • 10
  • 33
  • 49
16
votes
2 answers

Resolve a domain name to CNAME alias locally using dnsmasq

I'd like to resolve a domain name somedomain.com to a CNAME (AWS load balancer, e.g. some-balancer-1213231237.ap-southeast-2.elb.amazonaws.com), but only locally. What I mean to achieve is that whenever I try to visit somedomain.com, I want to be…
luqo33
  • 317
  • 1
  • 3
  • 8
16
votes
2 answers

Per-client DNS servers with DNSMasq

I am running TomatoUSB with DNSMasq to provide DHCP and DNS services for my local network. What I would like to achieve is to provide alternative DNS servers for one or two specific clients on the network based on their IP or MAC (These clients do…
Mike Hughes
  • 161
  • 1
  • 1
  • 3
15
votes
2 answers

How to configure a static wildcard subdomain with dnsmasq

I have a network behind a NAT with a few machines. The machines are: router - NAT, dnsmasq, forwarding - directly connected to the inet server - which runs ssh, www and some other stuff clients - which do stuff on server I also have…
Prody
  • 603
  • 3
  • 7
  • 16
14
votes
3 answers

Restricting dnsmasq's DHCP server to one interface

How do I configure dnsmasq to only assign addresses on eth0, not wlan0?
Delan Azabani
  • 528
  • 1
  • 4
  • 10
12
votes
4 answers

Don't automatically include all subdomains in DNSMasq address

It is possible to configure DNSMasq such that it returns a fixed IP address only for a request for that exact domain, and not for its subdomains? That is, I want it to return a fixed IP when resolving example.com, but not a.example.com,…
Michael Mrozek
  • 269
  • 3
  • 15
11
votes
2 answers

How long does dnsmasq cache dns?

I looked up the man page and couldn't find how long dnsmasq cache a dns. what's the rule for caching and expiration? I am having a problem that request send to an external service sometimes takes over 5 or 10 seconds for namelookup. I could save…
perlwle
  • 141
  • 1
  • 2
  • 8
11
votes
2 answers

dnsmasq - Multiple forwarding servers for domain entries?

I was wondering if it was possible to configure dnsmasq to send "server=" entries to multiple upstream servers? so like this: server=/facebook.com/1.2.3.4 server=/facebook.com/2.3.4.5 and have it pick which one based on it being available or not,…
T. B.
  • 313
  • 1
  • 2
  • 8
11
votes
2 answers

Dnsmasq resolves local hostname to 127.0.0.1 all over the net

My dnsmasq is configured: On host 'rtfm.lan' Domain 'lan' There are some DHCP presets that include hostnames All '*.lan' hosts registered via DHCP do resolve fine: dnsmasq known which IPs are assigned to which hostnames. However, 'rtfm.lan' is…
kolypto
  • 10,738
  • 12
  • 51
  • 66
10
votes
1 answer

dnsmasq doesn't automatically reload when entry is added to /etc/hosts

I am struggling for a few days to configure dnsmasq to automatically reload or take into knowledge the new hosts added to /etc/hosts or to another configured file /etc/hosts.dnsmasq. Is this even possible?
roshkattu
  • 111
  • 1
  • 1
  • 3
1
2 3
27 28