def del_bridge(bridge):
try:
subprocess.run(['ovs-vsctl', 'del-br', str(bridge)], stdout=subprocess.PIPE, stderr=subprocess.STDOUT, shell=False, check=True)
return [True, str(bridge)]
except subprocess.CalledProcessError as suberror:
return [False, "del bridge failed : %s" % suberror.stdout.decode('utf-8')]
评论列表
文章目录