What is Open vSwitch?
Open VSwitch is a production quality, multilayer Virtual Switch licensed under the Open Source Apache 2.0 license. It is designed to enable massive network automation through programmatic extension, while still supporting standard manage ment interfaces and protocols (e.g. NetFlow, SFlow, IPFIX, RSPAN, CLI, LACP, 802.1ag). In addition, it's designed to support distribution across multiple physical servers similar to VMware ' s vnetwork distribu Ted Vswitch or Cisco ' s Nexus 1000V. See full Feature List here
1. Install the dependent packages and create the OvS for the normal user.
Yum-y install wget gcc make python-devel openssl-devel kernel-devel graphviz kernel-debug-devel autoconf automake Rpm-bui LD Redhat-rpm-config Libtool
AddUser OvS
Su-ovs
2. Download the source package and create the RPM package.
Mkdir-p ~/rpmbuild/sources
wget http://openvswitch.org/releases/openvswitch-2.3.2.tar.gz
CP openvswitch-2.3.2.tar.gz ~/rpmbuild/sources/
Tar Xfz openvswitch-2.3.2.tar.gz
Sed ' s/openvswitch-kmod,//g ' Openvswitch-2.3.2/rhel/openvswitch.spec > Openvswitch-2.3.2/rhel/openvswitch_no_ Kmod.spec
RPMBUILD-BB--nocheck Openvswitch-2.3.2/rhel/openvswitch_no_kmod.spec
Exit
3. Create the OvS configuration directory and install the built-in RPM package.
Mkdir/etc/openvswitch
Yum localinstall/home/ovs/rpmbuild/rpms/x86_64/openvswitch-2.3.2-1.x86_64.rpm
4. If SELinux is turned on, do the following, skip this step if it is not turned on.
Yum Install Policycoreutils-python
Semanage fcontext-a-T openvswitch_rw_t "/etc/openvswitch (/.*)?"
Restorecon-rv/etc/openvswitch
5. Start the service and view the OvS version information.
Chkconfig Openvswitch on
Ovs-vsctl-v
Reference Documentation:
Blog: https://n40lab.wordpress.com/2015/06/28/centos-7-installing-openvswitch-2-3-2-lts/
Official Document: http://openvswitch.org/
Centos7 Installing the openvswitch Virtual Switch