diff --git a/stack.sh b/stack.sh index 0d90baea31..1e93883db9 100755 --- a/stack.sh +++ b/stack.sh @@ -253,7 +253,7 @@ SCHEDULER=${SCHEDULER:-nova.scheduler.filter_scheduler.FilterScheduler} HOST_IP_IFACE=${HOST_IP_IFACE:-eth0} # Use the eth0 IP unless an explicit is set by ``HOST_IP`` environment variable if [ -z "$HOST_IP" -o "$HOST_IP" == "dhcp" ]; then - HOST_IP=`LC_ALL=C /sbin/ifconfig ${HOST_IP_IFACE} | grep -m 1 'inet addr:'| cut -d: -f2 | awk '{print $1}'` + HOST_IP=`LC_ALL=C /sbin/ifconfig ${HOST_IP_IFACE} | grep -m 1 'inet'| cut -d: -f2 | awk '{print $2}'` if [ "$HOST_IP" = "" ]; then echo "Could not determine host ip address." echo "Either localrc specified dhcp on ${HOST_IP_IFACE} or defaulted to eth0"