ns_haproxy ns_vrouter ocf have incorrect grep command
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Fuel for OpenStack |
Fix Released
|
Medium
|
Oleksiy Molchanov |
Bug Description
The bug as customer reports it:
"Incorrect interface name variable in grep command
The grep commands in ocf ns_haproxy and ns_vrouter result in blank interface search because the variable in grep command in suffixed with ':'
But hapr-host and vr-host-base interface names are suffixed with @if<N> followed by colon.
Hence ':' should be removed to correct the same."
1. Steps to reproduce:
The script in, belonging to package fuel-ha-utils, /usr/lib/
2. Expected Result:
root@cic-
ocf-ns_vrouter: DEBUG: Vrouter was stopped, namespaces still exist
ocf-ns_vrouter: DEBUG: default: check_ns(): recieved netns list: vrouter
ocf-ns_vrouter: INFO: net.ipv4.ip_forward = 1
root@cic-
ocf-ns_haproxy: DEBUG: default: check_ns(): recieved netns list: haproxy
ocf-ns_haproxy: DEBUG: default: get_variables(): set up variables and PIDFILE name
ocf-ns_haproxy: DEBUG: default: check_ns(): recieved netns list: haproxy
ocf-ns_haproxy: DEBUG: default: get_variables(): set up variables and PIDFILE name
ocf-ns_haproxy: DEBUG: Pids for /usr/sbin/haproxy: 21587
ocf-ns_haproxy: INFO: haproxy daemon is running
ocf-ns_haproxy: INFO: default: proc_stop(): Stopping /usr/sbin/haproxy by PID 21587
ocf-ns_haproxy: DEBUG: default: proc_kill(): Stopping /usr/sbin/haproxy with SIGTERM...
ocf-ns_haproxy: DEBUG: default: proc_kill(): Stopped /usr/sbin/haproxy with SIGTERM
ocf-ns_haproxy: INFO: default: proc_stop(): Stopped /usr/sbin/haproxy
ocf-ns_haproxy: DEBUG: default: check_ns(): recieved netns list: haproxy
ocf-ns_haproxy: DEBUG: default: get_variables(): set up variables and PIDFILE name
ocf-ns_haproxy: DEBUG: default: check_ns(): recieved netns list: haproxy
ocf-ns_haproxy: DEBUG: default: get_variables(): set up variables and PIDFILE name
ocf-ns_haproxy: DEBUG: Pids for /usr/sbin/haproxy:
ocf-ns_haproxy: INFO: haproxy daemon is not running but pid file exists
ocf-ns_haproxy: DEBUG: Bringing up host interface: hapr-host
ocf-ns_haproxy: DEBUG: Bringing up the namespace interface: hapr-ns
ocf-ns_haproxy: INFO: net.ipv4.
ocf-ns_haproxy: INFO: net.ipv4.
ocf-ns_haproxy: INFO: Started haproxy daemon.
3. Actual Result:
root@cic-
ocf-ns_vrouter: DEBUG: Vrouter was stopped, namespaces still exist
ocf-ns_vrouter: DEBUG: default: check_ns(): recieved netns list: vrouter
ocf-ns_vrouter: INFO: net.ipv4.ip_forward = 1
ocf-ns_vrouter: DEBUG: Creating host interface: vr-host-base and namespace interface: vr-host-ns
ocf-ns_vrouter: ERROR: RTNETLINK answers: File exists
ocf-ns_vrouter: DEBUG: Bringing up host interface: vr-host-base
ocf-ns_vrouter: DEBUG: Bringing up the namespace interface: vr-host-ns
ocf-ns_vrouter: INFO: net.ipv4.
ocf-ns_vrouter: INFO: net.ipv4.
root@cic-
ocf-ns_haproxy: DEBUG: default: check_ns(): recieved netns list: haproxy
ocf-ns_haproxy: DEBUG: default: get_variables(): set up variables and PIDFILE name
ocf-ns_haproxy: DEBUG: default: check_ns(): recieved netns list: haproxy
ocf-ns_haproxy: DEBUG: default: get_variables(): set up variables and PIDFILE name
ocf-ns_haproxy: DEBUG: Pids for /usr/sbin/haproxy: 12907
ocf-ns_haproxy: INFO: haproxy daemon is running
ocf-ns_haproxy: INFO: default: proc_stop(): Stopping /usr/sbin/haproxy by PID 12907
ocf-ns_haproxy: DEBUG: default: proc_kill(): Stopping /usr/sbin/haproxy with SIGTERM...
ocf-ns_haproxy: DEBUG: default: proc_kill(): Stopped /usr/sbin/haproxy with SIGTERM
ocf-ns_haproxy: INFO: default: proc_stop(): Stopped /usr/sbin/haproxy
ocf-ns_haproxy: DEBUG: default: check_ns(): recieved netns list: haproxy
ocf-ns_haproxy: DEBUG: default: get_variables(): set up variables and PIDFILE name
ocf-ns_haproxy: DEBUG: default: check_ns(): recieved netns list: haproxy
ocf-ns_haproxy: DEBUG: default: get_variables(): set up variables and PIDFILE name
ocf-ns_haproxy: DEBUG: Pids for /usr/sbin/haproxy:
ocf-ns_haproxy: INFO: haproxy daemon is not running but pid file exists
ocf-ns_haproxy: DEBUG: Creating host interface: hapr-host and namespace interface: hapr-ns
ocf-ns_haproxy: ERROR: RTNETLINK answers: File exists
ocf-ns_haproxy: DEBUG: Bringing up host interface: hapr-host
ocf-ns_haproxy: DEBUG: Bringing up the namespace interface: hapr-ns
ocf-ns_haproxy: INFO: net.ipv4.
ocf-ns_haproxy: INFO: net.ipv4.
ocf-ns_haproxy: INFO: Started haproxy daemon.
ocf-ns_vrouter: ERROR: RTNETLINK answers: File exists
The above error is triggered because of the incorrect grep command which results in blank interface search though the interfaces are actually created.Hence it tries to
create the interfaces again which results in the error.
The above issue is raised for most of the actions that can be performed as part of the scripts like {start|
Changed in mos: | |
status: | Incomplete → New |
no longer affects: | mos |
Changed in fuel: | |
milestone: | none → 9.2 |
assignee: | nobody → Fuel Sustaining (fuel-sustaining-team) |
importance: | Undecided → High |
Changed in fuel: | |
importance: | High → Medium |
milestone: | 9.2 → 9.3 |
Changed in fuel: | |
assignee: | Fuel Sustaining (fuel-sustaining-team) → Oleksiy Molchanov (omolchanov) |
Changed in fuel: | |
milestone: | 9.x-updates → 9.2-mu-1 |
Changed in fuel: | |
status: | In Progress → Fix Committed |
tags: | added: on-verification |
Incomplete - no MOS version affected, not steps to reproduce, no expected/actual result.
Anton - please provide the information.