Actually neutron-ovs-cleanup should be started after the startup of the OVS service:
neutron-ovs-cleanup.conf
##############################################################################
start on started openvswitch-switch
stop on runlevel [!2345]
I don't know why the neutron-l3-agent and the neutron-dhcp-agent upstart scripts use a different pattern and why they get started even when neutron-ovs-cleanup has failed.
neutron-l3-agent.conf:
##############################################################################
start on runlevel [2345]
stop on runlevel [!2345]
respawn
chdir /var/run
pre-start script
mkdir -p /var/run/neutron
chown neutron:root /var/run/neutron
# Check to see if openvswitch plugin in use by checking
# status of cleanup upstart configuration
if status neutron-ovs-cleanup; then
start wait-for-state WAIT_FOR=neutron-ovs-cleanup WAIT_STATE=running WAITER=neutron-l3-agent
fi
end script
pre-start script
mkdir -p /var/run/neutron
chown neutron:root /var/run/neutron
# Check to see if openvswitch plugin in use by checking
# status of cleanup upstart configuration
if status neutron-ovs-cleanup; then
start wait-for-state WAIT_FOR=neutron-ovs-cleanup WAIT_STATE=running WAITER=neutron-dhcp-agent
fi
end script
Actually neutron-ovs-cleanup should be started after the startup of the OVS service:
neutron- ovs-cleanup. conf ####### ####### ####### ####### ####### ####### ####### ####### ####### ####### #
#######
start on started openvswitch-switch
stop on runlevel [!2345]
pre-start script neutron- ovs-cleanup ] && exit 0 neutron- ovs-cleanup -- \ neutron/ ovs-cleanup. log \ neutron. conf --verbose
# sleep 5
[ ! -x /usr/bin/
start-stop-daemon --start --chuid neutron --exec /usr/bin/
--log-file /var/log/
--config-file /etc/neutron/
end script
I don't know why the neutron-l3-agent and the neutron-dhcp-agent upstart scripts use a different pattern and why they get started even when neutron-ovs-cleanup has failed.
neutron- l3-agent. conf: ####### ####### ####### ####### ####### ####### ####### ####### ####### ####### #
#######
start on runlevel [2345]
stop on runlevel [!2345]
respawn
chdir /var/run
pre-start script ovs-cleanup; then neutron- ovs-cleanup WAIT_STATE=running WAITER= neutron- l3-agent
mkdir -p /var/run/neutron
chown neutron:root /var/run/neutron
# Check to see if openvswitch plugin in use by checking
# status of cleanup upstart configuration
if status neutron-
start wait-for-state WAIT_FOR=
fi
end script
exec start-stop-daemon --start --chuid neutron --exec /usr/bin/ neutron- l3-agent -- \ file=/etc/ neutron/ neutron. conf --config- file=/etc/ neutron/ l3_agent. ini \ file=/etc/ neutron/ fwaas_driver. ini --log-file= /var/log/ neutron/ l3-agent. log
--config-
--config-
neutron- dhcp-agent. conf: ####### ####### ####### ####### ####### ####### ####### ####### ####### ####### #
#######
description "Neutron DHCP Agent"
author "Chuck Short <email address hidden>"
start on runlevel [2345]
stop on runlevel [!2345]
respawn
chdir /var/run
pre-start script ovs-cleanup; then neutron- ovs-cleanup WAIT_STATE=running WAITER= neutron- dhcp-agent
mkdir -p /var/run/neutron
chown neutron:root /var/run/neutron
# Check to see if openvswitch plugin in use by checking
# status of cleanup upstart configuration
if status neutron-
start wait-for-state WAIT_FOR=
fi
end script
exec start-stop-daemon --start --chuid neutron --exec /usr/bin/ neutron- dhcp-agent -- --config- file=/etc/ neutron/ neutron. conf --config- file=/etc/ neutron/ dhcp_agent. ini --log-file= /var/log/ neutron/ dhcp-agent. log