[ovs-dev] [kernel-reload 8/8] xenserver: Introduce "force-reload-kmod" to reload kernel module.

Ben Pfaff blp at nicira.com
Tue Feb 8 23:34:03 UTC 2011

On Tue, Feb 08, 2011 at 03:24:32PM -0800, Ethan Jackson wrote:
> On Tue, Feb 8, 2011 at 3:18 PM, Ben Pfaff <blp at nicira.com> wrote:
> > On Tue, Feb 08, 2011 at 03:14:39PM -0800, Ethan Jackson wrote:
> >> > +if test "$#" = 0; then
> >> > + ? ?echo "# $0: no parameters given (use \"$0 --help\" for help)"
> >> > +fi
> >> Perhaps this should cause it to exit unsuccessfully.
> >
> > I did it this way in case the init script doesn't find any interfaces to
> > save. ?I guess it could avoid invoking it at all in that case.
> Yeah I was wondering about this.  A possible approach (which I
> considered mentioning but decided against it) would be to change the
> force_reload_kmod init script to give up when ovs-save fails (for
> example on my system it fails because I don't have iptables-save).  

We can probably skip iptables entirely, without an error, if
iptables-save is not present: Red Hat and Debian both put iptables and
iptables-save in the same package, so if iptables-save is not present
then it is unlikely that any iptables rules are configured.

> As part of this change, we could change ovs-save to be more exacting
> and die with an exit code when things aren't as it expects.  This has
> the benefit of preventing bugs in ovs-save or configuration errors
> from hosing the system.

I thought about that.  I'll take another look at doing it that way.

More information about the dev mailing list