Dnsmasq 安裝與設定

Install & Config

Install dnsmasq (assume you r root)

apt-get update
apt-get install dnsmasq

StartUP service

/etc/init.d/dnsmasq start

Check service listening on port 53

netstat -antulp


Tell dnsmasq resolve public netowork from which main DNS nameserver

vi /etc/dnsmasq.resolv.conf

Setup dnsmasq

vi /etc/dnsmasq.conf

resolv-file=/etc/dnsmasq.resolv.conf #specify a resolve file for dnsmasq
interface=eth0 #specify which NIC to use dnsmasq
dhcp-range=,,8h #specify IP range and lease period

DHCP additional options

dhcp-option=1, #specify Subnet mask
dhcp-option=3, #specify Gateway
dhcp-option=6, #specify DNS
dhcp-option=44, #specify WINS


While we have a internal network , and we want to resolve all computes those in a internal network.
we don't need to ask master DNS admin to set forward for us.
Just to rewrite our /etc/resolv.conf
nameserver dnsmasq-ip-address
Run up when boot
rc-update add dnsmasq default
Manpage http://hugokuo-hugo.blogspot.com/2011/03/dnsmasq-manpage.html


Popular posts from this blog

The method of Web Service HA+LB in OPENSTACK NOVA for private cloud only

OpenStack Swift - Container Sync (New & Old ways)