[ovs-dev] [suse 7/7] xenserver: Remove Linux bridge on startup if no bridges exist.

Patrick Mullaney pm.mullaney at gmail.com
Thu Dec 30 22:06:23 UTC 2010


On Tue, 2010-12-28 at 11:38 -0800, Justin Pettit wrote:
> I guess this change does require bridge compatibility.  I'm a bit worried about doing this kind of switch-a-roo behind users' backs.  Obviously, making it easier for users to get up and running on OVS is great.  However, I'm worried that bridge compatibility isn't as rigorously tested as it once was, and in general will provide a subpar experience.  As we've discussed, we should work on breaking the common functions out into some sort of "scripts" directory rather than having most distros working out of "xenserver".  This may encourage distros to start natively supporting the OVS commands, as well, if the integration were a little cleaner.
> 
Yea, I was hesitant on that change until I did the installs a couple
times and it bit me(not doing the rmmod). Not doing it and having
the script stop and error is fine by me as well. We may want to
say you need to reboot on install for the ordering issue in
my earlier response.
> Patrick, thank you very much for doing this integration work!  It's great to see OVS deployed in more systems.
You're very welcome! Thanks for the review!

> 
> --Justin
> 
> 
> On Dec 15, 2010, at 11:19 AM, Ben Pfaff wrote:
> 
> > From: Patrick Mullaney <pm.mullaney at gmail.com>
> > 
> > Otherwise, if the bridge module is loaded but no bridges exist, on all
> > but the most recent Linux kernels this prevents the Open vSwitch kernel
> > module from loading.
> > 
> > Signed-off-by: Ben Pfaff <blp at nicira.com>
> > ---
> > Patrick--this patch is missing your Signed-off-by, could you send it?
> > Thanks.
> > 
> > diff --git a/xenserver/etc_init.d_openvswitch b/xenserver/etc_init.d_openvswitch
> > index 74ada6f..5072775 100755
> > --- a/xenserver/etc_init.d_openvswitch
> > +++ b/xenserver/etc_init.d_openvswitch
> > @@ -181,6 +181,14 @@ function remove_all_dp {
> > }
> > 
> > function insert_modules_if_required {
> > +    if test -e /sys/module/bridge; then
> > +	bridges=`echo /sys/class/net/*/bridge | sed 's,/sys/class/net/,,g;s,/bridge,,g'`
> > +	if test "$bridges" != "*"; then
> > +            log_warning_msg "not removing bridge module because bridges exist ($bridges)"
> > +        else
> > +            action "removing bridge module" rmmod bridge
> > +        fi
> > +    fi
> >     if ! lsmod | grep -q "openvswitch_mod"; then
> >         action "Inserting llc module" modprobe llc
> >         action "Inserting openvswitch module" modprobe openvswitch_mod
> > -- 
> > 1.7.1
> > 
> > 
> > _______________________________________________
> > dev mailing list
> > dev at openvswitch.org
> > http://openvswitch.org/mailman/listinfo/dev_openvswitch.org
> 






More information about the dev mailing list