LXC with Open vSwitch

两盒软妹~` 提交于 2019-12-04 07:28:06

It was my bad. I've just copied ifup/ifdown scripts from Wordpress blog. But there were typos:

ovs-vsctl –may-exist add-br $BRIDGE

but should be:

ovs-vsctl --may-exist add-br $BRIDGE

--, not just - before may. The same everywhere in ifup/ifdown scripts. So they should look as these:

# cat /etc/lxc/ifup
#!/bin/bash

BRIDGE=switch0
ovs-vsctl --may-exist add-br $BRIDGE
ovs-vsctl --if-exists del-port $BRIDGE $5
ovs-vsctl --may-exist add-port $BRIDGE $5

# cat /etc/lxc/ifdown
#!/bin/bash
ovsBr=switch0
ovs-vsctl --if-exists del-port ${ovsBr} $5
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!