Questions tagged [dnsmasq]

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

Filter by
Sorted by
Tagged with
33 votes
2 answers
45k views

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 ...
Matt's user avatar
  • 655
30 votes
3 answers
100k views

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 ...
pfyon's user avatar
  • 993
25 votes
1 answer
50k views

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 ...
nrph's user avatar
  • 365
25 votes
2 answers
70k views

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....
K. Norbert's user avatar
20 votes
4 answers
59k views

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: ...
Staki42's user avatar
  • 303
20 votes
2 answers
37k views

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 ...
luqo33's user avatar
  • 357
17 votes
3 answers
49k views

Restricting dnsmasq's DHCP server to one interface

How do I configure dnsmasq to only assign addresses on eth0, not wlan0?
Delan Azabani's user avatar
17 votes
4 answers
41k views

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's user avatar
  • 2,019
16 votes
2 answers
16k views

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 ...
Mike Hughes's user avatar
16 votes
2 answers
18k views

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 - ...
Prody's user avatar
  • 623
13 votes
2 answers
49k views

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 ...
T. B.'s user avatar
  • 333
13 votes
3 answers
40k views

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 ...
perlwle's user avatar
  • 181
12 votes
4 answers
7k views

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 ...
Michael Mrozek's user avatar
11 votes
2 answers
11k views

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 ...
kolypto's user avatar
  • 11.1k
11 votes
1 answer
26k views

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 ...
roshkattu's user avatar
  • 121
11 votes
1 answer
46k views

dnsmasq: failed to create listening socket: Address already in use

The OS is Scientific Linux 6.3 (which is similar to redhat, centos and fedora) and I have installed dnsmasq with the following configuration interface=eth1 domain=hpclab expand-hosts dhcp-range=10.0....
mahmood's user avatar
  • 1,032
10 votes
2 answers
5k views

Why nslookup doesn't use mdns while ping do?

In dnsmasq.conf: address=/local/127.0.0.1 In resolv.conf: # Generated by NetworkManager domain example.com search example.com nameserver 127.0.0.1 nameserver 10.66.127.17 nameserver 10.68.5.26 I ...
dspjm's user avatar
  • 215
9 votes
2 answers
21k views

How to serve custom dns to dhcp clients in openWrt? [closed]

I would like to serve custom DNS server to dhcp clients. How I can achieve that in openWrt?
pixel's user avatar
  • 193
9 votes
6 answers
32k views

dnsmasq reading /etc/hosts, but not using it

I've done a default install of dnsmasq. When I run dig, it seems to be using dnsmasq (127.0.0.1), but the results don't include the hostnames included in /etc/hosts. /etc/hosts: 192.168.1.13 sun in ...
Zach Dwiel's user avatar
9 votes
2 answers
48k views

dig & nslookup can't resolve local hosts unless I specify the (local) DNS server to use

I am setting up a small private network within my University network. I have a Centos 6 box (sun) sitting between my private network and the university WAN. eth0 on the sun is connected to the WAN and ...
Gavin Simpson's user avatar
9 votes
3 answers
11k views

DNSMASQ config for captive portal

I am trying to create a captive portal wifi hotspot. Aim of the setup: Users connecting to hotspot through wlan0 should never be allowed to access the internet through eth1. For the "Sign into ...
55597's user avatar
  • 141
8 votes
3 answers
35k views

Bind dnsmasq DNS to just localhost (127.0.0.1)

I would like to ask a question about configuring of dnsmasq DNS server. I know about such configuration option as "listen-address". But even if I set this option to "listen-address=127.0.0.1" dnsmasq ...
D.K.'s user avatar
  • 91
8 votes
1 answer
31k views

Forward dns request to another dns server

How can I forward configure my local dnsmasq so requests with hostnames ending with .docker are forwarded to another nameserver, while other requests are still handled locally ? I have looked for an /...
greg0ire's user avatar
  • 316
7 votes
5 answers
18k views

How do I MAC filter with DHCP server

I want to Only allow certain MAC addresses to get a IP from my DHCP server, currently I use dnsmasq and I rather not change dhcp server but I'm open to other software aswell. However, I need to be ...
Joelbitar's user avatar
  • 195
7 votes
4 answers
17k views

dnsmasq: how to increase TTL?

Is there a way to override & increase the received TTL from an upstream DNS server? Is there a configuration parameter in dnsmasq for this?
jldupont's user avatar
  • 1,849
7 votes
5 answers
16k views

How can I override TTL of an Internet Address?

I'm running a caching DNS server currently to improve latency in a network. The question is: can I override the TTL I get from a server using BIND9 or other software on Linux? short "dig www.google....
OmniWired's user avatar
  • 149
6 votes
1 answer
11k views

Is it possible to override a single domain name using dnsmasq?

I have a server application that I'm running two instances of, production and development, namely: prod.example.com (10.0.0.1) dev.example.com (10.0.0.2) A third-party has written a client ...
Matt's user avatar
  • 322
6 votes
3 answers
13k views

DNS lookup aliasing of hostnames (not IP aliases), probably via dnsmasq

I'd like to be able to set up a host, say "eg", to be an alias to some server on the internet, say "example.example.com". I just need this functionality to be available from my local machine. I'm ...
intuited's user avatar
  • 415
6 votes
2 answers
15k views

Access libvirt+KVM virtual machines with DNS

I have an Ubuntu Trusty machine running KVM + Libvirt to manage small virtual machines, and using the standard NetworkManager to connect to regular networks. I want to be able to access the virtual ...
Tim Jones's user avatar
5 votes
4 answers
20k views

How to resolve all .dev domains to localhost on Windows

We'd like to set things up on our developers' Windows boxes such that all .dev domains resolve to localhost. On Unix systems, firing up dnsmasq with a single additional line to hosts would do it, but ...
Benjamin Pollack's user avatar
5 votes
3 answers
37k views

dnsmasq: failed to create listening socket for port 53: Address already in use

I got this error when i done the setup dnsmasq. ashokkrishna@krishna:~$ sudo dnsmasq dnsmasq: failed to create listening socket for port 53: Address already in use ashokkrishna@krishna:~$ netstat -...
ashok's user avatar
  • 229
5 votes
1 answer
19k views

Using dnsmasq to service multiple subnets

I'm pretty new to using dnsmasq, and I would like to keep utilizing it in my lab environment. However, being new, I am unsure what commands/files to use. I've spent two days doing research and ...
John Quicksall's user avatar
5 votes
2 answers
7k views

dnsmasq & Tomato - Elminate the need for a trailing dot for name resolution

I realize that a trailing dot after a hostname is technically "correct", but it's a pain in the butt to type and is unintuitive for non-technical users. I had DDWRT on a Linksys router of mine many, ...
Eric's user avatar
  • 237
5 votes
2 answers
6k views

DNSMasq is slower than my ISP at returning cached DNS entries.

I have DNSMasq set up on a relatively idle Pentium D 3.4Ghz Debian Linux machine. When I run dig queries locally, the second result is always 0 ms. When I run dig queries on any other machine on my ...
sludge's user avatar
  • 332
5 votes
1 answer
1k views

Slow boot and dns doesn't work

I don't understand what happened because i didn't change anything in system for quite a long time. Now system boots too slow and when it's booted - dns requests don't work. I can ping remote hosts by ...
Dmitrii Mikhailov's user avatar
5 votes
2 answers
5k views

OpenVPN: Not all DNS entries get pushed to clients from server. (dnsmasq)

I have been trying to find a solution to this problem, but have found no answer so far, so I hope you guys can help me out. I have a server running Ubuntu 10.04, which has a static IP address and an ...
Michael's user avatar
  • 51
5 votes
1 answer
1k views

Large AXFR through dnsmasq causes dig to hang with partial results

I'm attempting to set up dnsmasq as a local cache for consul. While this seems to work fine for normal digs, dnsmasq seems to only allow partial zone transfers. My resolv.conf: search x.domain.com y....
Connor Bell's user avatar
4 votes
2 answers
3k views

How to I make a domain resolve to different IP's when resolved from internal network and external network?

So I looked through BIND and Dnsmasq and unable to figure this out. I have a few of servers on DigitalOcean, and they are on the same datacenter. I want to be able to use internal IPs to get better ...
Arnav Gupta's user avatar
4 votes
1 answer
8k views

Separate Servers for TFTP and DHCP for PXE Boot

This seems like it should be simple, but I can't find any actual information: Is it possible to have two separate servers, one running dnsmasq doing DHCP while the TFTP (or HTTP) server is running on ...
Dessa Simpson's user avatar
4 votes
2 answers
14k views

NetworkManager & dnsmasq - ignore auto DNS settings

I'm running Arch Linux with NetworkManager and dnsmasq set up. It all seems to work fine, except that I try to use the new CloudFlare 1.1.1.1 DNS, but the resolver keeps using the DNS that is ...
Taco de Wolff's user avatar
4 votes
2 answers
11k views

Redirect all DNS-Requests with dnsmasq

I have following scenario: I have set up an ad-hoc network with wicd on my server, and use dnsmasq as an dhcp- and dns-server. The network works very well, I can connect, get an ip address, and on all ...
Moe's user avatar
  • 143
4 votes
2 answers
21k views

Set gateway per interface in DNSMasq

I have dhcp set up using DNSMasq, which looks like this: dhcp-range=interface:eth0,10.1.0.50,10.1.0.250,255.255.255.0 dhcp-range=interface:eth1,10.1.20.50,10.1.20.250,255.255.255.0 What I need to be ...
Jerbot's user avatar
  • 394
4 votes
1 answer
22k views

Is it possible to add a wildcard CNAME into dnsmasq?

I would like to let the DNS works in round robin way. So I have to put an entry into /etc/hosts. However, this does not allow wildcard domains. Is there any way that I can do this in dnsmasq? So I ...
Wang's user avatar
  • 318
4 votes
2 answers
2k views

possible to make samba4's internal dns server listen on non-standard port?

Is it possible to make samba4's internal dns server listen on a port other than 53? I need to run two dns server's on this host -- my desire was to use dnsmasq on the standard port for client's and ...
Ben's user avatar
  • 391
4 votes
2 answers
3k views

make dnsmasq ignore specific entries in /etc/hosts

I've set up a machine running dnsmasq, essentially serving its /etc/hosts file. However, there are specific entries which I want in that machine's /etc/hosts, but I don't want served. How can I make ...
einpoklum's user avatar
  • 1,682
4 votes
1 answer
2k views

how to setup dnsmasq for DNS for private and public hostnames via different DNS servers [duplicate]

lets say i have this private hostname dev.private.example.com that is only accessible in a private network over VPN connection and i have prod.example.com that is accessible to the internet. I have ...
uberrebu's user avatar
  • 503
4 votes
1 answer
6k views

Configure LXC to use specific DNS server instead of DNSMASQ

Out of the box, my LXC containers connect to a running instance of dnsmasq, which is started with the lxc-net service. In my case, I am running a local unbound DNS server that connects to a thing ...
jcarpenter2's user avatar
4 votes
1 answer
3k views

Does a Windows host correctly interpret dnsmasq parameters?

I have a network of Windows 10 machines served (DNS and DHCP) by a dnsmasq instance on a Ubuntu server (Ubuntu 15.10, dnsmasq 2.75). The setup basically works (dnsmasq provides addresses and manages ...
WoJ's user avatar
  • 3,617
4 votes
2 answers
4k views

Forwarding Active Directory Queries through DNSMASQ

I've set up an AD domain controller through Samba 4. I'm using Samba 4's internal DNS Server for handling the SRV queries. However, due to project requirements, my clients need to have a DNSMASQ as ...
Fang's user avatar
  • 189
4 votes
1 answer
7k views

Remove libvirt's dhcp lease entry using virsh

Using: $ virsh version Compiled against library: libvirt 1.3.1 Using library: libvirt 1.3.1 Using API: QEMU 1.3.1 Running hypervisor: QEMU 2.5.0 $ $ $ lsb_release -a No LSB modules are available....
Amir Keibi's user avatar

1
2 3 4 5
9