Skip to content

Commit

Permalink
utilities/ovs-ctl: Force removal of ip_gre/gre
Browse files Browse the repository at this point in the history
On Linux kernels older than 4.16 the user cannot take advantage of
OVS ERSPAN features if the older ip_gre and gre kernel modules are
loaded.  In addition, the openvswitch kernel module will fail to
load because it cannot grab the IPPROTO_GRE inet protocol handler
since the gre kernel module has already taken it.

Update the force_reload_kmod() script function to force removal
of the ip_gre and gre built-in kernel modules so that the openvswitch
kernel module can load and provide support for ERSPAN.

Signed-off-by: Greg Rose <gvrose8192@gmail.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
  • Loading branch information
gvrose8192 authored and blp committed Jun 1, 2018
1 parent 8929c55 commit 2bdd1f3
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions utilities/ovs-lib.in
Expand Up @@ -622,6 +622,14 @@ force_reload_kmod () {
action "Removing $vport module" rmmod $vport
done

if test -e /sys/module/ip_gre; then
action "Forcing removal of ip_gre module" rmmod ip_gre
fi

if test -e /sys/module/gre; then
action "Forcing removal of gre module" rmmod gre
fi

if test -e /sys/module/openvswitch; then
action "Removing openvswitch module" rmmod openvswitch
fi
Expand Down

0 comments on commit 2bdd1f3

Please sign in to comment.