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 1221185 - ip rule list does not allow selectors and shows incorrect usage
Summary: ip rule list does not allow selectors and shows incorrect usage
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: iproute
Version: 7.2
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: rc
: ---
Assignee: Phil Sutter
QA Contact: Marek Marusic
URL:
Whiteboard:
Depends On:
Blocks: 1359218
TreeView+ depends on / blocked
 
Reported: 2015-05-13 12:54 UTC by Jaroslav Aster
Modified: 2016-11-03 23:32 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1359218 (view as bug list)
Environment:
Last Closed: 2016-11-03 23:32:56 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2016:2162 0 normal SHIPPED_LIVE iproute bug fix and enhancement update 2016-11-03 13:14:33 UTC

Description Jaroslav Aster 2015-05-13 12:54:27 UTC
Description of problem:

ip rule list does not allow selectors and shows incorrect usage.


Version-Release number of selected component (if applicable):

iproute-3.10.0-26


How reproducible:

always


Steps to Reproduce:

# ip rule add from 172.29.0.0/24 to 172.29.1.0/24 table 1110

# ip rule show
0:      from all lookup local 
32765:  from 172.29.0.0/24 to 172.29.1.0/24 lookup 1110 
32766:  from all lookup main 
32767:  from all lookup default

# ip rule list
0:      from all lookup local 
32765:  from 172.29.0.0/24 to 172.29.1.0/24 lookup 1110 
32766:  from all lookup main 
32767:  from all lookup default 

# ip rule list from 172.29.0.0/24
"ip rule show" does not take any arguments.

# ip rule help
Usage: ip rule [ list | add | del | flush ] SELECTOR ACTION

man ip-rule:

ip rule  [ list | add | del | flush ] SELECTOR ACTION

There is no show command and selectors are allowed for list. It is a little bit confusing.

I think it is not a functional mistake of ip route (selectors for list command would be useful), it is just documentation problem (man page, help).

Comment 1 Pavel Šimerda (pavlix) 2015-05-20 18:14:37 UTC
So what are your expectations regarding selectors? Are they part of the bug report?

Comment 2 Jaroslav Aster 2015-05-21 09:08:55 UTC
Hi Pavel,

I expect consistency. There are two ways how to do it. The first, you can change documentation (help and man page) and the second, you can change the code and add new functionality. It is up to you which way will be chosen.

If you choose second, the selectors should be the same as they are for the other command.

# ip rule add from 192.168.1.0/24 lookup 3
# ip rule add from 192.168.2.0/24 lookup 3
# ip rule list lookup 3

I expect that last command will show me all rules where lookup is 3.

Comment 3 Pavel Šimerda (pavlix) 2015-07-07 15:53:42 UTC
Will fix the docs for now.

Comment 6 Phil Sutter 2016-03-07 19:51:14 UTC
This will be fixed as part of bug 1251186.

*** This bug has been marked as a duplicate of bug 1251186 ***

Comment 11 errata-xmlrpc 2016-11-03 23:32: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, 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://rhn.redhat.com/errata/RHEA-2016-2162.html


Note You need to log in before you can comment on or make changes to this bug.