27
25
from nova import log as logging
30
28
from nova.virt.xenapi import network_utils
32
31
LOG = logging.getLogger("nova.xenapi_net")
37
37
def ensure_vlan_bridge(vlan_num, bridge, net_attrs=None):
38
38
"""Create a vlan and bridge unless they already exist."""
41
41
url = FLAGS.xenapi_connection_url
42
42
username = FLAGS.xenapi_connection_username
43
43
password = FLAGS.xenapi_connection_password
45
45
# Check whether bridge already exists
46
46
# Retrieve network whose name_label is "bridge"
47
47
network_ref = network_utils.NetworkHelper.find_network_with_name_label(