Bug 2131293

Summary: Support looking up named route table in routing rule
Product: Red Hat Enterprise Linux 9 Reporter: Wen Liang <wenliang>
Component: rhel-system-rolesAssignee: Rich Megginson <rmeggins>
Status: CLOSED ERRATA QA Contact: Jon Trossbach <jtrossba>
Severity: unspecified Docs Contact: Jaroslav Klech <jklech>
Priority: unspecified    
Version: 9.2CC: jklech, jtrossba, pasik, rhel-cs-system-management-subsystem-qe, rmeggins, spetrosi
Target Milestone: rcKeywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: role:network
Fixed In Version: rhel-system-roles-1.21.0-0.2.network.el9 Doc Type: Enhancement
Doc Text:
.Routing rule is able to look up a route table by its name With this update, the `rhel-system-roles.network` RHEL System Role supports looking up a route table by its name when you define a routing rule. This feature provides quick navigation for complex network configurations where you need to have different routing rules for different network segments.
Story Points: ---
Clone Of: 2129620 Environment:
Last Closed: 2023-05-09 07:37:56 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: 2129620    
Bug Blocks:    

Description Wen Liang 2022-09-30 15:08:07 UTC
+++ This bug was initially created as a clone of Bug #2129620 +++

Description of problem:


Per discussion in this issue, https://github.com/linux-system-roles/network/issues/506.Currently, the network role only supports adding the 
static routes to the named route table but not supporting looking up the named
route table in routing rule.


Expected results:

The user can define the named route table in the routing rule.

Comment 5 Wen Liang 2022-12-13 19:57:01 UTC
The file need to be tested with is `tests/tests_routing_rules_nm.yml`.

Comment 6 Jon Trossbach 2022-12-19 06:23:47 UTC
Unfortunately, I'm getting a pass result on a test I know should fail for RHEL 9. When I test against a RHEL 6 VM:

[root@netqe41 Upstream-testsuite]# uname -r
5.14.0-205.el9.x86_64
[root@netqe41 Upstream-testsuite]# rpm -q rhel-system-roles
rhel-system-roles-1.21.0-0.13.el9.noarch

::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
::   Test
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::

:: [ 01:17:20 ] :: [   PASS   ] :: Using image URL http://download.devel.redhat.com/released/rhel-6-7-8/rhel-6/RHEL-6/6.10/Server/x86_64/images/rhel-guest-image-6.10-390.x86_64.qcow2 
:: [ 01:17:25 ] :: [   PASS   ] :: Downloading image RHEL_6_10_GA 
:: [ 01:17:25 ] :: [   PASS   ] :: Command 'sed "s#<setup>#echo -e '[rhel]\\nname=rhel\\nbaseurl=http://download.devel.redhat.com/released/rhel-6-7-8/rhel-6/RHEL-6/6.10/Server/x86_64/os/\\nenabled=1\\ngpgcheck=0\\n[rhel-opt]\\nname=rhel-opt\\nbaseurl=http://download.devel.redhat.com/released/rhel-6-7-8/rhel-6/RHEL-6/6.10/Server/optional/x86_64/os/\\nenabled=1\\ngpgcheck=0\\n' | sudo tee /etc/yum.repos.d/rhel.repo#" setup.yml > _setup.yml' (Expected 0, got 0)
:: [ 01:17:25 ] :: [   LOG    ] :: Running against image: RHEL_6_10_GA
:: [ 01:17:25 ] :: [   LOG    ] :: Using Ansible-
:: [ 01:17:25 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:25 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.crypto_policies' supports rhel version: 6
:: [ 01:17:25 ] :: [   LOG    ] ::   supported rhel versions: [8, 9]
:: [ 01:17:25 ] :: [   INFO   ] :: Skipping crypto_policies - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:25 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:25 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.certificate' supports rhel version: 6
:: [ 01:17:25 ] :: [   LOG    ] ::   supported rhel versions: [7, 8, 9]
:: [ 01:17:25 ] :: [   INFO   ] :: Skipping certificate - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:25 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:25 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.ad_integration' supports rhel version: 6
:: [ 01:17:25 ] :: [   LOG    ] ::   supported rhel versions: [7, 8, 9]
:: [ 01:17:25 ] :: [   INFO   ] :: Skipping ad_integration - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:25 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:25 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.vpn' supports rhel version: 6
:: [ 01:17:25 ] :: [   LOG    ] ::   supported rhel versions: [7, 8, 9]
:: [ 01:17:25 ] :: [   INFO   ] :: Skipping vpn - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:25 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:25 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.tlog' supports rhel version: 6
:: [ 01:17:25 ] :: [   LOG    ] ::   supported rhel versions: [8, 9]
:: [ 01:17:25 ] :: [   INFO   ] :: Skipping tlog - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:25 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:25 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.postfix' supports rhel version: 6
:: [ 01:17:25 ] :: [   LOG    ] ::   supported rhel versions: ['6', '7', '8', '9']
:: [ 01:17:25 ] :: [   LOG    ] :: Using additional SSH args for standard-test-inventory: -o PubkeyAcceptedKeyTypes=+ssh-rsa
:: [ 01:17:25 ] :: [   LOG    ] :: Test playbook roles/rhel-system-roles.postfix/tests/usr does not exist, probably postfix has no tests
:: [ 01:17:25 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:25 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.selinux' supports rhel version: 6
:: [ 01:17:25 ] :: [   LOG    ] ::   supported rhel versions: [6, 7, 8, 9]
:: [ 01:17:26 ] :: [   LOG    ] :: Using additional SSH args for standard-test-inventory: -o PubkeyAcceptedKeyTypes=+ssh-rsa
:: [ 01:17:26 ] :: [   LOG    ] :: Test playbook roles/rhel-system-roles.selinux/tests/usr does not exist, probably selinux has no tests
:: [ 01:17:26 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:26 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.metrics' supports rhel version: 6
:: [ 01:17:26 ] :: [   LOG    ] ::   supported rhel versions: [6, 7, 8, 9]
:: [ 01:17:26 ] :: [   LOG    ] :: Using additional SSH args for standard-test-inventory: -o PubkeyAcceptedKeyTypes=+ssh-rsa
:: [ 01:17:26 ] :: [   LOG    ] :: Test playbook roles/rhel-system-roles.metrics/tests/usr does not exist, probably metrics has no tests
:: [ 01:17:26 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:26 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.timesync' supports rhel version: 6
:: [ 01:17:26 ] :: [   LOG    ] ::   supported rhel versions: [6, 7, 8, 9]
:: [ 01:17:26 ] :: [   LOG    ] :: Using additional SSH args for standard-test-inventory: -o PubkeyAcceptedKeyTypes=+ssh-rsa
:: [ 01:17:26 ] :: [   LOG    ] :: Test playbook roles/rhel-system-roles.timesync/tests/usr does not exist, probably timesync has no tests
:: [ 01:17:26 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:26 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.nbde_server' supports rhel version: 6
:: [ 01:17:26 ] :: [   LOG    ] ::   supported rhel versions: ['7', '8', '9']
:: [ 01:17:26 ] :: [   INFO   ] :: Skipping nbde_server - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:26 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:26 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.kdump' supports rhel version: 6
:: [ 01:17:26 ] :: [   LOG    ] ::   supported rhel versions: [6, 7, 8, 9]
:: [ 01:17:26 ] :: [   LOG    ] :: Using additional SSH args for standard-test-inventory: -o PubkeyAcceptedKeyTypes=+ssh-rsa
:: [ 01:17:26 ] :: [   LOG    ] :: Test playbook roles/rhel-system-roles.kdump/tests/usr does not exist, probably kdump has no tests
:: [ 01:17:26 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:26 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.kernel_settings' supports rhel version: 6
:: [ 01:17:27 ] :: [   LOG    ] ::   supported rhel versions: [7, 8, 9]
:: [ 01:17:27 ] :: [   INFO   ] :: Skipping kernel_settings - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:27 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:27 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.network' supports rhel version: 6
:: [ 01:17:27 ] :: [   LOG    ] ::   supported rhel versions: ['6', '7', '8', '9']
:: [ 01:17:27 ] :: [   LOG    ] :: Using additional SSH args for standard-test-inventory: -o PubkeyAcceptedKeyTypes=+ssh-rsa
:: [ 01:17:27 ] :: [   LOG    ] :: Test playbook roles/rhel-system-roles.network/tests/usr does not exist, probably network has no tests
:: [ 01:17:27 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:27 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.logging' supports rhel version: 6
:: [ 01:17:27 ] :: [   LOG    ] ::   supported rhel versions: ['7', '8', '9']
:: [ 01:17:27 ] :: [   INFO   ] :: Skipping logging - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:27 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:27 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.firewall' supports rhel version: 6
:: [ 01:17:27 ] :: [   LOG    ] ::   supported rhel versions: [7, 8, 9]
:: [ 01:17:27 ] :: [   INFO   ] :: Skipping firewall - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:27 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:27 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.ssh' supports rhel version: 6
:: [ 01:17:27 ] :: [   LOG    ] ::   supported rhel versions: [6, 7, 8, 9]
:: [ 01:17:27 ] :: [   LOG    ] :: Using additional SSH args for standard-test-inventory: -o PubkeyAcceptedKeyTypes=+ssh-rsa
:: [ 01:17:27 ] :: [   LOG    ] :: Test playbook roles/rhel-system-roles.ssh/tests/usr does not exist, probably ssh has no tests
:: [ 01:17:27 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:27 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.podman' supports rhel version: 6
:: [ 01:17:27 ] :: [   LOG    ] ::   supported rhel versions: ['8', '9']
:: [ 01:17:27 ] :: [   INFO   ] :: Skipping podman - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:27 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:27 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.nbde_client' supports rhel version: 6
:: [ 01:17:27 ] :: [   LOG    ] ::   supported rhel versions: [7, 8, 9]
:: [ 01:17:27 ] :: [   INFO   ] :: Skipping nbde_client - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:27 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:27 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.sshd' supports rhel version: 6
:: [ 01:17:27 ] :: [   LOG    ] ::   supported rhel versions: ['6', '7', '8', '9']
:: [ 01:17:28 ] :: [   LOG    ] :: Using additional SSH args for standard-test-inventory: -o PubkeyAcceptedKeyTypes=+ssh-rsa
:: [ 01:17:28 ] :: [   LOG    ] :: Test playbook roles/rhel-system-roles.sshd/tests/usr does not exist, probably sshd has no tests
:: [ 01:17:28 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:28 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.ha_cluster' supports rhel version: 6
:: [ 01:17:28 ] :: [   LOG    ] ::   supported rhel versions: [8, 9]
:: [ 01:17:28 ] :: [   INFO   ] :: Skipping ha_cluster - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:28 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:28 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.cockpit' supports rhel version: 6
:: [ 01:17:28 ] :: [   LOG    ] ::   supported rhel versions: ['7', '8', '9']
:: [ 01:17:28 ] :: [   INFO   ] :: Skipping cockpit - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:28 ] :: [   LOG    ] ::   guessed distribution version: 6
:: [ 01:17:28 ] :: [   LOG    ] :: Checking if 'roles/rhel-system-roles.storage' supports rhel version: 6
:: [ 01:17:28 ] :: [   LOG    ] ::   supported rhel versions: [7, 8, 9]
:: [ 01:17:28 ] :: [   INFO   ] :: Skipping storage - not supported for RHEL version 6 (image: RHEL_6_10_GA)
:: [ 01:17:28 ] :: [   PASS   ] :: Command 'rm -f image.qcow2 _setup.yml' (Expected 0, got 0)
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
::   Duration: 9s
::   Assertions: 4 good, 0 bad
::   RESULT: PASS (Test)

Comment 7 Jon Trossbach 2023-01-13 17:27:00 UTC
As expected only fails on RHEL 6.10

[root@netqe4 Upstream-testsuite]# uname -r
5.14.0-230.el9.x86_64
[root@netqe4 Upstream-testsuite]# rpm -q rhel-system-roles
rhel-system-roles-1.21.0-0.13.el9.noarch


:: [ 12:03:10 ] :: [   FAIL   ] :: Test network with ANSIBLE-2 against RHEL_6_10_GA (Expected 0, got 1)
:: [ 12:03:09 ] :: [   FAIL   ] :: Test tests_routing_rules_nm.yml (Assert: expected 0, got 2)
:: [ 12:04:22 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_7_9_GA (Expected 0, got 0)
:: [ 12:04:21 ] :: [   PASS   ] :: Test tests_routing_rules_nm.yml (Assert: expected 0, got 0)
:: [ 12:06:20 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_8_7_0_GA (Expected 0, got 0)
:: [ 12:06:19 ] :: [   PASS   ] :: Test tests_routing_rules_nm.yml (Assert: expected 0, got 0)
:: [ 12:07:58 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_8_8_TESTING (Expected 0, got 0)
:: [ 12:07:57 ] :: [   PASS   ] :: Test tests_routing_rules_nm.yml (Assert: expected 0, got 0)
:: [ 12:09:19 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_9_1_0_GA (Expected 0, got 0)
:: [ 12:09:18 ] :: [   PASS   ] :: Test tests_routing_rules_nm.yml (Assert: expected 0, got 0)
:: [ 12:10:41 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_9_2_TESTING (Expected 0, got 0)
:: [ 12:10:40 ] :: [   PASS   ] :: Test tests_routing_rules_nm.yml (Assert: expected 0, got 0)

Comment 19 errata-xmlrpc 2023-05-09 07:37:56 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-2023:2246