mirror of
https://github.com/openwrt/packages.git
synced 2026-01-10 11:44:48 +00:00
openvswitch: initial feed at OpenVSwitch version 2.3
Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
This commit is contained in:
37
net/openvswitch/files/etc/init.d/openvswitch.init
Normal file
37
net/openvswitch/files/etc/init.d/openvswitch.init
Normal file
@@ -0,0 +1,37 @@
|
||||
#!/bin/sh /etc/rc.common
|
||||
# Copyright (C) 2013 Julius Schulz-Zander <julius@net.t-labs.tu-berlin.de>
|
||||
# Copyright (C) 2014 OpenWrt.org
|
||||
|
||||
START=15
|
||||
USE_PROCD=1
|
||||
|
||||
start_service() {
|
||||
[ -x /var/run/openvswitch ] || mkdir -p /var/run/openvswitch
|
||||
[ -e /etc/openvswitch/conf.db ] || {
|
||||
/usr/bin/ovsdb-tool create /etc/openvswitch/conf.db /usr/share/openvswitch/vswitch.ovsschema
|
||||
}
|
||||
|
||||
# ovsdb-server
|
||||
procd_open_instance
|
||||
procd_set_param command /usr/sbin/ovsdb-server
|
||||
procd_append_param command --remote=punix:/var/run/db.sock
|
||||
procd_append_param command --remote=db:Open_vSwitch,Open_vSwitch,manager_options
|
||||
procd_append_param command --pidfile=/var/run/ovsdb-server.pid
|
||||
procd_set_param respawn
|
||||
procd_append_param respawn 3600
|
||||
procd_append_param respawn 5
|
||||
procd_append_param respawn -1
|
||||
procd_close_instance
|
||||
|
||||
# ovs-vswitchd
|
||||
procd_open_instance
|
||||
procd_set_param command /usr/sbin/ovs-vswitchd
|
||||
procd_append_param command --pidfile=/var/run/ovs-vswitchd.pid
|
||||
procd_set_param respawn
|
||||
procd_append_param respawn 3600
|
||||
procd_append_param respawn 5
|
||||
procd_append_param respawn -1
|
||||
procd_close_instance
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user