启动Mininet时报ovsdb-server没有启动的错误
来源:互联网 发布:org域名申请 编辑:程序博客网 时间:2024/05/18 18:02
前言
今天重启了虚拟机 B 192.168.1.198 一波,可是发现在使用mn命令时报了以下错误:
错误提示:
*** Creating network*** Adding controller*** Adding hosts:h1 h2 *** Adding switches:ovs-vsctl: unix:/usr/local/var/run/openvswitch/db.sock: database connection failed (No such file or directory)ovs-vsctl exited with code 1*** Error connecting to ovs-db with ovs-vsctlMake sure that Open vSwitch is installed, that ovsdb-server is running, and that"ovs-vsctl show" works correctly.You may wish to try "service openvswitch-switch start"
解决过程
- 一开始看到 You may wish to try “service openvswitch-switch start”
以为真的是没有安装openvswitch,于是重新安装了一波openvswitch,在安装的过程中要注意openvswitch与内核版本之间的支持关系。以下是他们版本之间的对应表:
其实,报错信息中,只是数据库服务器没有启动而矣,
2. 安装后启动ovsdb-server
#:ovsdb-server --remote=punix:/usr/local/var/run/openvswitch/db.sock --remote=db:Open_vSwitch,Open_vSwitch,manager_options --pidfile --detach#:ovs-vsctl --no-wait init#:ovs-vswitchd --pidfile --detach --log-file
如果有:
2017-04-24T00:12:11Z|00005|reconnect|INFO|unix:/usr/local/var/run/openvswitch/db.sock: connected
显示就说明启动交换机数据库成功
看来 系统重启后,这个交换机数据库没有自动重新启动,可以写一个自启的简单脚本。
3. 编写 数据库自启脚本:
#!/bin/bashovsdb-server --remote=punix:/usr/local/var/run/openvswitch/db.sock --remote=db:Open_vSwitch,Open_vSwitch,manager_options --pidfile --detachovs-vsctl --no-wait initovs-vswitchd --pidfile --detach --log-file
修改权限位:chmod 777 autorun.sh
设置开机自启:
# 把刚刚的文件链接到/etc/init.d/下面ln autorun.sh /etc/init.d/autorun.sh#设置开机自启cd /etc/init.d/update-rc.d autorun defaults 90
重启
重启后 再启动 mininet
mn –controller=remote,ip=192.168.1.197,port=6653
反馈信息:
*** Creating network*** Adding controller*** Adding hosts:h1 h2 *** Adding switches:s1 *** Adding links:(h1, s1) (h2, s1) *** Configuring hostsh1 h2 *** Starting controllerc0 *** Starting 1 switchess1 ...*** Starting CLI:
ok,已经连接成功,而且也说明开机自启了.
0 0
- 启动Mininet时报ovsdb-server没有启动的错误
- 解决mysql启动时报The server quit without updating PID file 的错误
- 解决mysql启动时报The server quit without updating PID file 的错误
- tomcat启动时报如下错误
- Openfire启动时报数据库连接错误
- Eclipse 启动时报如下错误
- mysql启动时报1067错误
- 启动项目时报refresh错误
- 安装数据库MySQL/MongoDB,启动时报错‘发生系统错误2’或者服务没有响应控制功能的解决办法
- sybase服务器启动时报错:无法启动服务器,错误1053:服务没有及时相应启动或控制请求
- 数据库2005安装后,服务启动时报异常!再安装没有Sql Server management Studio ?
- IIS启动时报0x8ffe2740错误的处理办法
- gwt 用HOSTMODE启动时报的一个错误
- 启动eclipse时报Failed to load JNI的错误
- 在myeclipse中启动tomcat7.0.19时报的错误
- java web程序启动服务器时报的错误
- springmvc+mybatis+c3p0 tomcat启动时报的错误,求解决方案
- Spring Tool Suite 启动时报告的错误
- 滚动条插件使用 --笔记
- 程序的安装方法
- 秒杀系统架构分析与实战
- 代理模式(Proxy Pattern、Surrogate Pattern 对象结构型模式)
- 健康不胖
- 启动Mininet时报ovsdb-server没有启动的错误
- Convert a Number to Hexadecimal
- ZZULIOJ 1851: KILL By Assassin
- 在myeclipse中连接到mysql中的数据库
- Redis与Memcached的区别
- MySQL学习笔记 2:约束、修改数据表和操作数据表中的记录
- BZOJ 1095 [ZJOI2007]Hide 捉迷藏
- Linux软连接和硬链接
- “GIS讲堂”第六课内容的公布