Bug 2089872

Summary: network: the controller device is not completely cleaned up in the bond tests.
Product: Red Hat Enterprise Linux 9 Reporter: Noriko Hosoi <nhosoi>
Component: rhel-system-rolesAssignee: Rich Megginson <rmeggins>
Status: CLOSED ERRATA QA Contact: Jon Trossbach <jtrossba>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 9.1CC: jharuda, jtrossba, nhosoi, rhel-cs-system-management-subsystem-qe, spetrosi, wenliang, zhguan
Target Milestone: rcKeywords: Triaged
Target Release: 9.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: role:network
Fixed In Version: rhel-system-roles-1.19.1-1.el9 Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: 2089868 Environment:
Last Closed: 2022-11-15 10:23:47 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 2089868    
Bug Blocks:    

Description Noriko Hosoi 2022-05-24 15:44:13 UTC
+++ This bug was initially created as a clone of Bug #2089868 +++

Description of problem:
If the network test playbooks are executed in the serialized fashion sharing the same VM, tests_bond_removal_initscripts.yml and tests_bond_removal_nm.yml fail with:
Error: Connection activation failed:
No suitable device found for this connection

Complete failed output from tests_bond_removal_initscripts.yml:

TASK [rhel-system-roles.network : Configure networking connection profiles] ****
task path: /usr/share/ansible/roles/rhel-system-roles.network/tasks/main.yml:75
Wednesday 11 May 2022  11:50:36 -0400 (0:00:00.520)       0:00:16.656 *********
"'
[WARNING]: [012] <error> #0, state:up persistent_state:present, 'bond0': call 'ifup bond0' failed with exit status 1
fatal: [/tmp/tmp.Qg8GGc0RZE/image.qcow2.snap]: FAILED! => {
    "_invocation": {
        "module_args": {
            "__debug_flags": "",
            "__header": "#
            # Ansible managed
            #",
            "connections": [
                {
                    "bond": {
                        "miimon": 110,
                        "mode": "active-backup"
                    },
                    "interface_name": "nm-bond",
                    "name": "bond0",
                    "state": "up",
                    "type": "bond"
                },
                {
                    "controller": "bond0",
                    "interface_name": "test1",
                    "name": "bond0.0",
                    "state": "up",
                    "type": "ethernet"
                },
                {
                    "controller": "bond0",
                    "interface_name": "test2",
                    "name": "bond0.1",
                    "state": "up",
                    "type": "ethernet"
                }
            ],
            "force_state_change": false,
            "ignore_errors": false,
            "provider": "initscripts"
        }
    },
    "changed": true
}

STDERR:
[007] <info>  #0, state:up persistent_state:present, 'bond0': add ifcfg-rh profile 'bond0'
[008] <info>  #1, state:up persistent_state:present, 'bond0.0': add ifcfg-rh profile 'bond0.0'
[009] <info>  #2, state:up persistent_state:present, 'bond0.1': add ifcfg-rh profile 'bond0.1'
[010] <info>  #0, state:up persistent_state:present, 'bond0': up connection bond0 (not-active)
[011] <info>  #0, state:up persistent_state:present, 'bond0': call 'ifup bond0': rc=1, out='b'WARN      : [/etc/sysconfig/network-scripts/ifup-eth] Unable to start slave device ifcfg-ib0 for master nm-bond.

Determining IP information for nm-bond... failed.
'', err='b"WARN      : [ifup] You are using 'ifup' script provided by 'network-scripts', which are now deprecated.
WARN      : [ifup] 'network-scripts' will be removed in one of the next major releases of RHEL.
WARN      : [ifup] It is advised to switch to 'NetworkManager' instead - it provides 'ifup/ifdown' scripts as well.
WARN      : [ifup] You are using 'ifup' script provided by 'network-scripts', which are now deprecated.
WARN      : [ifup] 'network-scripts' will be removed in one of the next major releases of RHEL.
WARN      : [ifup] It is advised to switch to 'NetworkManager' instead - it provides 'ifup/ifdown' scripts as well.
WARN      : [ifup] You are using 'ifup' script provided by 'network-scripts', which are now deprecated.
WARN      : [ifup] 'network-scripts' will be removed in one of the next major releases of RHEL.
WARN      : [ifup] It is advised to switch to 'NetworkManager' instead - it provides 'ifup/ifdown' scripts as well.
WARN      : [ifup] You are using 'ifup' script provided by 'network-scripts', which are now deprecated.
WARN      : [ifup] 'network-scripts' will be removed in one of the next major releases of RHEL.
WARN      : [ifup] It is advised to switch to 'NetworkManager' instead - it provides 'ifup/ifdown' scripts as well.
Error: Connection activation failed: No suitable device found for this connection (device eth0 not available because profile is not compatible with device (mismatching interface name)).
dhclient(23010) is already running - exiting. 

This version of ISC DHCP is based on the release available
on ftp.isc.org. Features have been added and other changes
have been made to the base software release in order to make
it work better with this distribution.

Please report issues with this software via: 
https://bugzilla.redhat.com/

exiting.
"'
[012] <error> #0, state:up persistent_state:present, 'bond0': call 'ifup bond0' failed with exit status 1

MSG:
error: call 'ifup bond0' failed with exit status 1


How reproducible: always


How to Reproduce: Run the bond playbooks tests_bond_*.yml in the serialized manner.

Comment 3 Jon Trossbach 2022-06-09 19:53:23 UTC
Using http://brew-task-repos.usersys.redhat.com/repos/scratch/rmeggins/rhel-system-roles/1.19.0/1.el9/noarch/rhel-system-roles-1.19.0-1.el9.noarch.rpm

[root@netqe16 Upstream-testsuite]# uname -r
5.14.0-105.el9.x86_64
[root@netqe16 Upstream-testsuite]# rpm -q rhel-system-roles
rhel-system-roles-1.19.0-1.el8.noarch

:: [ 15:22:26 ] :: [   PASS   ] :: Test network (/tmp/tmp.g2I1xel3uA/roles/rhel-system-roles.network/tests/tests_bond_removal_initscripts.yml) with ANSIBLE-2.9 against RHEL_9_1_TESTING (Expected 0, got 0)
:: [ 15:26:07 ] :: [   PASS   ] :: Test network (/tmp/tmp.xgcllYNsnl/roles/rhel-system-roles.network/tests/tests_bond_removal_initscripts.yml) with ANSIBLE-2.9 against RHEL_9_0_TESTING (Expected 0, got 0)
:: [ 15:28:30 ] :: [   PASS   ] :: Test network (/tmp/tmp.niXckB11zj/roles/rhel-system-roles.network/tests/tests_bond_removal_initscripts.yml) with ANSIBLE-2.9 against RHEL_8_7_TESTING (Expected 0, got 0)
:: [ 15:37:49 ] :: [   PASS   ] :: Test network (/tmp/tmp.OevP94L5Nl/roles/rhel-system-roles.network/tests/tests_bond_removal_initscripts.yml) with ANSIBLE-2.9 against RHEL_8_6_TESTING (Expected 0, got 0)
:: [ 15:42:51 ] :: [   PASS   ] :: Test network (/tmp/tmp.0IG3gTh8h0/roles/rhel-system-roles.network/tests/tests_bond_removal_initscripts.yml) with ANSIBLE-2.9 against RHEL_8_5_0_GA (Expected 0, got 0)
:: [ 15:45:12 ] :: [   PASS   ] :: Test network (/tmp/tmp.kk1QAS8YSp/roles/rhel-system-roles.network/tests/tests_bond_removal_initscripts.yml) with ANSIBLE-2.9 against RHEL_7_9_GA (Expected 0, got 0)
:: [ 15:51:30 ] :: [   PASS   ] :: Test network (/tmp/tmp.ia4sqTUcA8/roles/rhel-system-roles.network/tests/tests_bond_removal_initscripts.yml) with ANSIBLE-2.9 against RHEL_6_10_GA (Expected 0, got 0)

Comment 4 Jon Trossbach 2022-06-09 20:39:10 UTC
Just noticed there was another test suite in question, too. Ran those quick to be sure and they seem good as well.

:: [ 16:27:21 ] :: [   PASS   ] :: Test network (/tmp/tmp.ArimC1Mand/roles/rhel-system-roles.network/tests/tests_bond_removal_nm.yml) with ANSIBLE- against RHEL_6_10_GA (Expected 0, got 0)
:: [ 16:38:34 ] :: [   PASS   ] :: Test network (/tmp/tmp.X0d9CZB5Ma/roles/rhel-system-roles.network/tests/tests_bond_removal_nm.yml) with ANSIBLE- against RHEL_7_9_GA (Expected 0, got 0)
:: [ 16:36:23 ] :: [   PASS   ] :: Test network (/tmp/tmp.F1mFX4AIaL/roles/rhel-system-roles.network/tests/tests_bond_removal_nm.yml) with ANSIBLE- against RHEL_8_5_0_GA (Expected 0, got 0)
:: [ 16:25:07 ] :: [   PASS   ] :: Test network (/tmp/tmp.EYDYiVjeGX/roles/rhel-system-roles.network/tests/tests_bond_removal_nm.yml) with ANSIBLE- against RHEL_8_6_TESTING (Expected 0, got 0)
:: [ 16:34:04 ] :: [   PASS   ] :: Test network (/tmp/tmp.x9AHOC9mex/roles/rhel-system-roles.network/tests/tests_bond_removal_nm.yml) with ANSIBLE- against RHEL_8_7_TESTING (Expected 0, got 0)
:: [ 16:31:50 ] :: [   PASS   ] :: Test network (/tmp/tmp.BZoYBG1Pux/roles/rhel-system-roles.network/tests/tests_bond_removal_nm.yml) with ANSIBLE- against RHEL_9_0_TESTING (Expected 0, got 0)
:: [ 16:29:35 ] :: [   PASS   ] :: Test network (/tmp/tmp.oiOs03BDCG/roles/rhel-system-roles.network/tests/tests_bond_removal_nm.yml) with ANSIBLE- against RHEL_9_1_TESTING (Expected 0, got 0)

Comment 8 Jon Trossbach 2022-06-23 21:35:56 UTC
It appears this is good to go.

Used dnf install http://brew-task-repos.usersys.redhat.com/repos/scratch/rmeggins/rhel-system-roles/1.19.3/0.1.el9/noarch/rhel-system-roles-1.19.3-0.1.el9.noarch.rpm

[root@cloud-qe-10 Upstream-testsuite]# uname -r
5.14.0-115.el9.x86_64
[root@cloud-qe-10 Upstream-testsuite]# rpm -q rhel-system-roles
rhel-system-roles-1.19.3-0.1.el9.noarch

export ANSIBLE_VER=2.12

export SYSTEM_ROLES_ONLY_TESTS=network/tests_bond_removal_initscripts.yml
:: [ 16:16:18 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_6_10_GA (Expected 0, got 0)
:: [ 16:30:31 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_7_9_GA (Expected 0, got 0)
:: [ 16:37:17 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_8_5_0_GA (Expected 0, got 0)
:: [ 16:40:20 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_8_6_TESTING (Expected 0, got 0)
:: [ 16:43:08 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_8_7_TESTING (Expected 0, got 0)
:: [ 16:54:50 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_9_0_TESTING (Expected 0, got 0)
:: [ 16:57:10 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_9_1_TESTING (Expected 0, got 0)


export SYSTEM_ROLES_ONLY_TESTS=network/tests_bond_removal_nm.yml
:: [ 17:05:35 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_6_10_GA (Expected 0, got 0)
:: [ 17:09:53 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_7_9_GA (Expected 0, got 0)
:: [ 17:20:33 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_8_5_0_GA (Expected 0, got 0)
:: [ 17:25:55 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_8_6_TESTING (Expected 0, got 0)
:: [ 17:28:22 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_8_7_TESTING (Expected 0, got 0)
:: [ 17:30:40 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_9_0_TESTING (Expected 0, got 0)
:: [ 17:32:51 ] :: [   PASS   ] :: Test network with ANSIBLE-2.12 against RHEL_9_1_TESTING (Expected 0, got 0)

Comment 9 Zhiqian Guan 2022-07-04 03:15:18 UTC
clear need info

Comment 11 errata-xmlrpc 2022-11-15 10:23:47 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (rhel-system-roles bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2022:8117