使用源码安装ovs

来源:互联网 发布:程序员工作简历 编辑:程序博客网 时间:2024/06/07 18:53
声明:
本博客欢迎转载,但请保留原作者信息!
作者:柯晓东
团队:华为杭州OpenStack团队

为了使用openvswitch的新功能只好抛弃好用的apt-get,改用从源码安装openvswitch。
git clone http://github.com/openvswitch/ovs.gitcd ovs./boot.sh./configure --with-linux=/lib/modules/`uname -r`/buildmakemake installmake INSTALL_MOD_DIR=kernel/net/openvswitch modules_installmodprobe -r vport_genevemodprobe -r openvswitchmodprobe openvswitchmodprobe vport-geneve

重启机器后,需要执行以下命令才能继续使用ovs。当出现说...db.sock不存在的错误时,可以试试手动重拉db-server是否能够解决问题。

重拉的方法如下:

#创建conf.dbovsdb-tool create conf.db /usr/local/share/openvswitch/vswitch.ovsschema#启动db服务ovsdb-server --remote=punix:/usr/local/var/run/openvswitch/db.sock --remote=db:Open_vSwitch,Open_vSwitch,manager_options --pidfile=/usr/local/var/run/openvswitch/ovsdb-server.pid --detach -vconsole:off --log-file --remote=ptcp:6640:127.0.0.1 /opt/stack/data/ovs/conf.db#查看db.sock是否存在ls /usr/local/var/run/openvswitch/db.sockovs-vsctl --no-wait init

更详细的帮助请看
http://git.openvswitch.org/cgi-bin/gitweb.cgi?p=openvswitch;a=blob_plain;f=INSTALL;hb=HEAD

0 0
原创粉丝点击