From: Dave Wallace Date: Thu, 4 Feb 2016 03:34:04 +0000 (-0500) Subject: Change non-default route ethernet interfaces state to down so VPP will use them. X-Git-Url: https://gerrit.fd.io/r/gitweb?a=commitdiff_plain;h=d255ee13f57a73d2374dbcd63b1a377d88672557;p=odp4vpp.git Change non-default route ethernet interfaces state to down so VPP will use them. Change-Id: Icdb1a8d35a97e01d5e1be13fdc89ce3f9ec62e1a Signed-off-by: Dave Wallace --- diff --git a/build-root/vagrant/bootstrap.ubuntu1404.sh b/build-root/vagrant/bootstrap.ubuntu1404.sh index a8381bb4..fc1a3b8d 100644 --- a/build-root/vagrant/bootstrap.ubuntu1404.sh +++ b/build-root/vagrant/bootstrap.ubuntu1404.sh @@ -52,6 +52,18 @@ cd ~vagrant/ sudo -u vagrant mkdir -p git/vpp cp /vagrant/README.moved git/vpp/ +# Disable all ethernet interfaces other than the default route +# interface so VPP will use those interfaces. The VPP auto-blacklist +# algorithm prevents the use of any physical interface contained in the +# routing table (i.e. "route --inet --inet6") preventing the theft of +# the management ethernet interface by VPP from the kernel. +for intf in $(ls /sys/class/net) ; do + if [ -d /sys/class/net/$intf/device ] && + [ "$(route --inet --inet6 | grep default | grep $intf)" == "" ] ; then + ifconfig $intf down + fi +done + cd /vpp/ # Initial vpp build