From d255ee13f57a73d2374dbcd63b1a377d88672557 Mon Sep 17 00:00:00 2001 From: Dave Wallace Date: Wed, 3 Feb 2016 22:34:04 -0500 Subject: Change non-default route ethernet interfaces state to down so VPP will use them. Change-Id: Icdb1a8d35a97e01d5e1be13fdc89ce3f9ec62e1a Signed-off-by: Dave Wallace --- build-root/vagrant/bootstrap.ubuntu1404.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'build-root/vagrant') 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 -- cgit 1.2.3-korg