Merge pull request #18 from yj2317916/master
Fix the port of amqp check
This commit is contained in:
commit
a8e7cde843
@ -38,6 +38,7 @@ OCF_RESKEY_plugin_config_default="/etc/neutron/l3_agent.ini"
|
||||
OCF_RESKEY_user_default="neutron"
|
||||
OCF_RESKEY_pid_default="$HA_RSCTMP/$OCF_RESOURCE_INSTANCE.pid"
|
||||
OCF_RESKEY_neutron_server_port_default="9696"
|
||||
OCF_RESKEY_amqp_server_port_default="5672"
|
||||
|
||||
: ${OCF_RESKEY_binary=${OCF_RESKEY_binary_default}}
|
||||
: ${OCF_RESKEY_config=${OCF_RESKEY_config_default}}
|
||||
@ -45,6 +46,7 @@ OCF_RESKEY_neutron_server_port_default="9696"
|
||||
: ${OCF_RESKEY_user=${OCF_RESKEY_user_default}}
|
||||
: ${OCF_RESKEY_pid=${OCF_RESKEY_pid_default}}
|
||||
: ${OCF_RESKEY_neutron_server_port=${OCF_RESKEY_neutron_server_port_default}}
|
||||
: ${OCF_RESKEY_amqp_server_port=${OCF_RESKEY_amqp_server_port_default}}
|
||||
|
||||
#######################################################################
|
||||
|
||||
@ -217,7 +219,7 @@ neutron_l3_agent_monitor() {
|
||||
# We are sure to hit the scheduler process and not other Neutron process with the same connection behavior (for example neutron-server)
|
||||
pid=`cat $OCF_RESKEY_pid`
|
||||
# check the connections according to the PID
|
||||
network_amqp_check=`netstat -punt | grep -s "$OCF_RESKEY_neutron_server_port" | grep -s "$pid" | grep -qs "ESTABLISHED"`
|
||||
network_amqp_check=`netstat -punt | grep -s "$OCF_RESKEY_amqp_server_port" | grep -s "$pid" | grep -qs "ESTABLISHED"`
|
||||
rc=$?
|
||||
if [ $rc -ne 0 ]; then
|
||||
ocf_log err "Neutron L3 Server is not connected to the Neutron server: $rc"
|
||||
|
Loading…
x
Reference in New Issue
Block a user