bug 10824: clearing up older entries in resolv.conf and dnsmasq-resolv.conf before adding so that duplicate entries do not end up in these files.

status 10842: resolved fixed
This commit is contained in:
Abhinandan Prateek 2011-09-07 05:10:12 +05:30 committed by root
parent 6dfd2f280b
commit 5a19056aa2
1 changed files with 2 additions and 0 deletions

View File

@ -225,6 +225,8 @@ setup_common() {
hostname $NAME
#Nameserver
sed -i -e "/^nameserver.*$/d" /etc/resolv.conf # remove previous entries
sed -i -e "/^nameserver.*$/d" /etc/dnsmasq-resolv.conf # remove previous entries
if [ -n "$internalNS1" ]
then
echo "nameserver $internalNS1" > /etc/dnsmasq-resolv.conf