summaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
authorGurucharan Shetty <guru@ovn.org>2016-01-05 10:13:39 -0800
committerGurucharan Shetty <guru@ovn.org>2016-01-05 11:38:10 -0800
commit26c430615c692fa98260a3b116750fdc3471ce49 (patch)
tree7fa764aec0023517c1b43fd68c420b5b29ebcfda /debian
parent0dcc739e7a2854cfcaf490725856c593ac294bba (diff)
downloadopenvswitch-26c430615c692fa98260a3b116750fdc3471ce49.tar.gz
openvswitch-switch.init: Redirect error to /dev/null.
The latest Open vSwitch kernel module from Upstream linux does not list "version". During debian package installation, we would see a non-harmful error in the log. This patch suppresses it. Signed-off-by: Gurucharan Shetty <guru@ovn.org> Acked-by: Ben Pfaff <blp@ovn.org>
Diffstat (limited to 'debian')
-rwxr-xr-xdebian/openvswitch-switch.init12
1 files changed, 8 insertions, 4 deletions
diff --git a/debian/openvswitch-switch.init b/debian/openvswitch-switch.init
index aece7802c..a045f3b73 100755
--- a/debian/openvswitch-switch.init
+++ b/debian/openvswitch-switch.init
@@ -87,11 +87,15 @@ restart () {
depmod -a
if [ -e /sys/module/openvswitch ]; then
- LOADED_SRCVERSION=`cat /sys/module/openvswitch/srcversion`
- LOADED_VERSION=`cat /sys/module/openvswitch/version`
+ LOADED_SRCVERSION=`cat /sys/module/openvswitch/srcversion \
+ 2>/dev/null`
+ LOADED_VERSION=`cat /sys/module/openvswitch/version \
+ 2>/dev/null`
elif [ -e /sys/module/openvswitch_mod ]; then
- LOADED_SRCVERSION=`cat /sys/module/openvswitch_mod/srcversion`
- LOADED_VERSION=`cat /sys/module/openvswitch_mod/version`
+ LOADED_SRCVERSION=`cat /sys/module/openvswitch_mod/srcversion \
+ 2>/dev/null`
+ LOADED_VERSION=`cat /sys/module/openvswitch_mod/version \
+ 2>/dev/null`
fi
SRCVERSION=`modinfo -F srcversion openvswitch 2>/dev/null`
VERSION=`modinfo -F version openvswitch 2>/dev/null`