Commit 5f1d7b49 authored by David Johnson's avatar David Johnson

Make 7d835f94 for the multi-cluster compute node case.

parent 7d835f94
......@@ -4157,11 +4157,6 @@ if [ -n "$DESIGNATE_PASS" -a "${USE_DESIGNATE_AS_RESOLVER}" = "1" ]; then
echo "reverting back to non-Designate phys host configuration!"
cp -p /etc/resolv.conf.orig /etc/resolv.conf
else
# tmcc finds the bossip via first server in
# /etc/resolv.conf, ugh. So force it to find the bossip
# via this file instead.
echo $mynameserver > /etc/emulab/bossnode
mkdir -p $OURDIR/pssh.setup-designate.stdout
mkdir -p $OURDIR/pssh.setup-designate.stderr
......@@ -4177,11 +4172,6 @@ if [ -n "$DESIGNATE_PASS" -a "${USE_DESIGNATE_AS_RESOLVER}" = "1" ]; then
-o $OURDIR/pssh.setup-designate.stdout \
-e $OURDIR/pssh.setup-designate.stderr \
/etc/resolv.conf /etc/resolv.conf
echo "*** Copying /etc/emulab/bossnode to all hosts..."
$PSCP -h /tmp/pssh.hosts \
-o $OURDIR/pssh.setup-designate.stdout \
-e $OURDIR/pssh.setup-designate.stderr \
/etc/emulab/bossnode /etc/emulab/bossnode
fi
else
echo "WARNING: could not redirect phys host DNS to Designate;"
......
......@@ -1353,6 +1353,26 @@ if [ ! -f $OURDIR/neutron.vars ]; then
fi
#
# Emulab tmcc finds the bossip via first server in /etc/resolv.conf,
# ugh, and we might change /etc/resolv.conf if we are installing
# Designate on >= Ocata. So force it to find the bossip via this file
# instead. Previously, we had done this near the bottom of
# setup-controller.sh, but this change has to be made in a
# multi-cluster-compatible manner; the bossip could be different for
# phys node at different clusters.
#
if [ ! -f /etc/emulab/bossnode -a $OSVERSION -ge $OSNEWTON -a "${USE_DESIGNATE_AS_RESOLVER}" = "1"]; then
mydomain=`hostname | sed -n -e 's/[^\.]*\.\(.*\)$/\1/p'`
mynameserver=`sed -n -e 's/^nameserver \([0-9]*\.[0-9]*\.[0-9]*\.[0-9]*\).*$/\1/p' < /etc/resolv.conf | head -1`
if [ -z "$mynameserver" ]; then
mynameserver=`dig +short boss.$mydomain A`
fi
if [ -n "$mynameserver" ]; then
echo $mynameserver > /etc/emulab/bossnode
fi
fi
##
## Finally, if we had been UPDATING, remove the lockfile!
##
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment