CLOUDSTACK-1670: Fix multiple nic routing issue when dhcp_release available

dnsmasq.conf need to contain /etc/dhcpopts.txt from the beginning, otherwise
SIGHUP won't make dnsmasq reload the dhcpopts.txt, thus result in multiple nics
user VM get router information from all DHCP offers.
This commit is contained in:
Sheng Yang 2013-08-22 19:17:54 -07:00
parent e515acd7be
commit 8daf3e3c23
2 changed files with 5 additions and 0 deletions

View File

@ -632,3 +632,5 @@ log-facility=/var/log/dnsmasq.log
# Include a another lot of configuration options.
#conf-file=/etc/dnsmasq.more.conf
conf-dir=/etc/dnsmasq.d
dhcp-optsfile=/etc/dhcpopts.txt

View File

@ -634,6 +634,9 @@ setup_common() {
setup_dnsmasq() {
log_it "Setting up dnsmasq"
touch /etc/dhcpopts.txt
[ -z $DHCP_RANGE ] && [ $ETH0_IP ] && DHCP_RANGE=$ETH0_IP
[ $ETH0_IP6 ] && DHCP_RANGE_IP6=$ETH0_IP6
[ -z $DOMAIN ] && DOMAIN="cloudnine.internal"