agent
def main():
cfg.CONF.register_opts(ip_lib.OPTS)
common_config.init(sys.argv[1:])
common_config.setup_logging(cfg.CONF)
logging_config.setup_logging(cfg.CONF)
q_utils.log_opt_values(LOG)
try:
agent_config = create_agent_config_map(cfg.CONF)
except ValueError as e:
LOG.error(_('%s Agent terminated!'), e)
sys.exit(1)
is_xen_compute_host = 'rootwrap-xen-dom0' in agent_config['root_helper']
if is_xen_compute_host:
# Force ip_lib to always use the root helper to ensure that ip
# commands target xen dom0 rather than domU.
cfg.CONF.set_default('ip_lib_force_root', True)
agent = OVSNeutronAgent(**agent_config)
signal.signal(signal.SIGTERM, handle_sigterm)
# Start everything.
LOG.info(_("Agent initialized successfully, now running... "))
agent.daemon_loop()
sys.exit(0)setup_rpc()

setup_integration_br()
setup_physical_bridges()
Last updated