Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 2133856

Summary: [RFE] Support the DNS priority
Product: Red Hat Enterprise Linux 8 Reporter: Wen Liang <wenliang>
Component: rhel-system-rolesAssignee: Rich Megginson <rmeggins>
Status: CLOSED ERRATA QA Contact: Jon Trossbach <jtrossba>
Severity: unspecified Docs Contact: Marc Muehlfeld <mmuehlfe>
Priority: unspecified    
Version: 8.8CC: djez, jtrossba, nm-team, rmeggins, spetrosi, till
Target Milestone: rcKeywords: FutureFeature, Triaged
Target Release: ---Flags: pm-rhel: mirror+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: role:network
Fixed In Version: rhel-system-roles-1.21.0-0.2.network.el8 Doc Type: Enhancement
Doc Text:
.The `network` System Role supports setting a DNS priority value This enhancement adds the `dns_priority` parameter to the RHEL `network` System Role. You can set this parameter to a value from `-2147483648` to `2147483647`. The default value is `0`. Lower values have a higher priority. Note that negative values cause the System Role to exclude other configurations with a greater numeric priority value. Consequently, in presence of at least one negative priority value, the System Role uses only DNS servers from connection profiles with the lowest priority value. As a result, you can use the `network` System Role to define the order of DNS servers in different connection profiles.
Story Points: ---
Clone Of:
: 2133858 (view as bug list) Environment:
Last Closed: 2023-05-16 08:31:36 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:    
Bug Blocks: 2133858    

Description Wen Liang 2022-10-11 15:43:27 UTC
Description of problem:

The users want to configure the priority of DNS servers, add support for that.


Expected results:

The users can configure the priority of DNS servers through the network role.

Comment 4 Jon Trossbach 2022-12-08 23:26:24 UTC
which yaml file or files does this need to be tested with?

Comment 5 Rich Megginson 2022-12-09 00:22:18 UTC
(In reply to Jon Trossbach from comment #4)
> which yaml file or files does this need to be tested with?

Looking at the PR for this BZ - https://github.com/linux-system-roles/network/pull/531/files

looks like tests/tests_eth_dns_support_nm.yml and tests/tests_ipv6_dns_search_nm.yml

@nm-team please confirm

Comment 6 Wen Liang 2022-12-13 19:42:13 UTC
(In reply to Rich Megginson from comment #5)
> (In reply to Jon Trossbach from comment #4)
> > which yaml file or files does this need to be tested with?
> 
> Looking at the PR for this BZ -
> https://github.com/linux-system-roles/network/pull/531/files
> 
> looks like tests/tests_eth_dns_support_nm.yml and
> tests/tests_ipv6_dns_search_nm.yml
> 
> @nm-team please confirm

I confirm, the tests are `tests/tests_eth_dns_support_nm.yml` and `tests/tests_ipv6_dns_search_nm.yml`.

Comment 7 Jon Trossbach 2022-12-19 05:45:08 UTC
@djez 
@rmeggins

Same problem as https://bugzilla.redhat.com/show_bug.cgi?id=2129620

Comment 8 Jon Trossbach 2023-01-13 20:37:13 UTC
Only failing with Ansible 2.14 and RHEL 6.10 as expected. Everything else looks good

[root@netqe3 Upstream-testsuite]# uname -r
4.18.0-447.el8.x86_64
[root@netqe3 Upstream-testsuite]# rpm -q rhel-system-roles
rhel-system-roles-1.21.0-0.14.el8.noarch

tests_eth_dns_support_nm.yml
:: [ 14:56:40 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_6_10_GA (Expected 0, got 0)
:: [ 14:56:39 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)
:: [ 14:48:34 ] :: [   FAIL   ] :: Test network with ANSIBLE-2 against RHEL_6_10_GA (Expected 0, got 1)
:: [ 14:48:33 ] :: [   FAIL   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 2)
:: [ 15:00:47 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_7_9_GA (Expected 0, got 0)
:: [ 15:00:46 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)
:: [ 14:49:58 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_7_9_GA (Expected 0, got 0)
:: [ 14:49:57 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)
:: [ 15:02:36 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_8_7_0_GA (Expected 0, got 0)
:: [ 15:02:35 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)
:: [ 14:51:40 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_8_7_0_GA (Expected 0, got 0)
:: [ 14:51:39 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)
:: [ 15:04:15 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_8_8_TESTING (Expected 0, got 0)
:: [ 15:04:14 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)
:: [ 14:53:08 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_8_8_TESTING (Expected 0, got 0)
:: [ 14:53:06 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)
:: [ 15:05:40 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_9_1_0_GA (Expected 0, got 0)
:: [ 15:05:39 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)
:: [ 14:54:25 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_9_1_0_GA (Expected 0, got 0)
:: [ 14:54:24 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)
:: [ 15:07:07 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_9_2_TESTING (Expected 0, got 0)
:: [ 15:07:06 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)
:: [ 14:55:41 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_9_2_TESTING (Expected 0, got 0)
:: [ 14:55:40 ] :: [   PASS   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 0)

tests_eth_dns_support_nm.yml
:: [ 14:49:35 ] :: [   FAIL   ] :: Test network with ANSIBLE-2 against RHEL_6_10_GA (Expected 0, got 1)
:: [ 14:49:34 ] :: [   FAIL   ] :: Test tests_eth_dns_support_nm.yml (Assert: expected 0, got 2)
:: [ 14:57:00 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_6_10_GA (Expected 0, got 0)
:: [ 14:56:59 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)
:: [ 14:51:01 ] :: [   FAIL   ] :: Test network with ANSIBLE-2 against RHEL_6_10_GA (Expected 0, got 1)
:: [ 14:51:00 ] :: [   FAIL   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 2)
:: [ 14:58:01 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_7_9_GA (Expected 0, got 0)
:: [ 14:58:00 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)
:: [ 14:51:59 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_7_9_GA (Expected 0, got 0)
:: [ 14:51:58 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)
:: [ 14:59:10 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_8_7_0_GA (Expected 0, got 0)
:: [ 14:59:09 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)
:: [ 14:53:10 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_8_7_0_GA (Expected 0, got 0)
:: [ 14:53:09 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)
:: [ 15:00:17 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_8_8_TESTING (Expected 0, got 0)
:: [ 15:00:16 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)
:: [ 14:54:16 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_8_8_TESTING (Expected 0, got 0)
:: [ 14:54:15 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)
:: [ 15:01:19 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_9_1_0_GA (Expected 0, got 0)
:: [ 15:01:18 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)
:: [ 14:55:16 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_9_1_0_GA (Expected 0, got 0)
:: [ 14:55:15 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)
:: [ 15:02:24 ] :: [   PASS   ] :: Test network with ANSIBLE-2.9 against RHEL_9_2_TESTING (Expected 0, got 0)
:: [ 15:02:23 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)
:: [ 14:56:18 ] :: [   PASS   ] :: Test network with ANSIBLE-2 against RHEL_9_2_TESTING (Expected 0, got 0)
:: [ 14:56:17 ] :: [   PASS   ] :: Test tests_ipv6_dns_search_nm.yml (Assert: expected 0, got 0)

Comment 12 errata-xmlrpc 2023-05-16 08:31:36 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:2804