On 6/29/2018 9:23 AM, Justin Pettit wrote:
On Jun 26, 2018, at 10:19 AM, Greg Rose <[email protected]> wrote:
When upgrading from older versions of OVS that used the built-in geneve
kernel module on RHEL 7 systems to newer versions that use the 'compat'
vport_geneve and vport_vxlan drivers we need to clean up some cruft
that might have been left over after the upgrade.
Remove any genev_sys_6081 and vxlan_sys_4789 interfaces and then if
the RHEL 7 geneve or vxlan built-in drivers are loaded remove them
before loading the new drivers.
Removing the geneve and vxlan built-in drivers will prevent occurrences
of the "unassociated datapath" errors that can sometimes occur in some
environments.
Signed-off-by: Greg Rose <[email protected]>
---
V2 - Move the changes to the ovs-kmod-ctl command as per Aaron
Conole's suggestion.
---
utilities/ovs-kmod-ctl.in | 19 +++++++++++++++++++
utilities/ovs-lib.in | 2 +-
2 files changed, 20 insertions(+), 1 deletion(-)
diff --git a/utilities/ovs-kmod-ctl.in b/utilities/ovs-kmod-ctl.in
index 7c50d64..9b09e22 100644
--- a/utilities/ovs-kmod-ctl.in
+++ b/utilities/ovs-kmod-ctl.in
@@ -72,6 +72,25 @@ remove_kmods() {
if test -e /sys/module/openvswitch; then
action "Removing openvswitch module" rmmod openvswitch
fi
+
+ # Older releases may be using the rtnetlink interface while a
+ # newer release will want to use the internal compat interface
+ # for geneve and vxlan.
+ if test -e /sys/class/net/genev_sys_6081; then
+ action "ip link del link genev_sys_6081 dev genev_sys_6081" \
+ ip link del link genev_sys_6081 dev genev_sys_6081
+ fi
+ if test -e /sys/class/net/vxlan_sys_4789; then
+ action "ip link del link vxlan_sys_4789 dev vxlan_sys_4789" \
+ ip link del link vxlan_sys_4789 dev vxlan_sys_4789
+ fi
+
+ if test -e /sys/module/geneve; then
+ action "rmmod geneve" rmmod geneve
+ fi
+ if test -e /sys/module/vxlan; then
+ action "rmmod vxlan" rmmod vxlan
+ fi
}
usage () {
diff --git a/utilities/ovs-lib.in b/utilities/ovs-lib.in
index 6a958cb..765cd06 100644
--- a/utilities/ovs-lib.in
+++ b/utilities/ovs-lib.in
@@ -605,6 +605,7 @@ force_reload_kmod () {
stop_ovsdb
start_ovsdb || return 1
+ action "ovs-appctl dpctl/flush-conntrack" ovs-appctl dpctl/flush-conntrack
stop_forwarding
if action "Saving interface configuration" save_interfaces; then
@@ -620,7 +621,6 @@ force_reload_kmod () {
for dp in `ovs-dpctl dump-dps`; do
action "Removing datapath: $dp" ovs-dpctl del-dp "$dp"
done
- action "ovs-appctl dpctl/flush-conntrack"
This looks like a separate bug fix that seems like it would be worth its own
patch.
I think the point of string is to be human-readable. What about strings like "Flush conntrack
entries" and "Delete geneve device", for example?
Ha ha - yes, well the bug was that I originally did not understand how
the "action" procedure worked.
After the string you have to actually specify the command!
So yes, logically it is a separate bug fix and I agree the string
comment could be better. I'll respin and send
a V2.
I assume these patches should be backported, correct?
No - this will be specific to the new release with ERSPAN support. No
backports required.
Thanks!
- Greg
Aaron, since you commented on the previous version and have more expertise in
this area, can you take a look at this (or the respin if Greg agrees with my
comments)?
Thanks,
--Justin
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev