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 1374446 - Prevent some double spaces in ip route output
Summary: Prevent some double spaces in ip route output
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: iproute
Version: 7.4
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: rc
: ---
Assignee: Timothy Redaelli
QA Contact: Jaroslav Aster
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-09-08 16:47 UTC by Phil Sutter
Modified: 2017-08-01 21:32 UTC (History)
3 users (show)

Fixed In Version: iproute-3.10.0-82.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-08-01 21:32:13 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:2171 0 normal SHIPPED_LIVE iproute bug fix and enhancement update 2017-08-01 18:40:13 UTC

Description Phil Sutter 2016-09-08 16:47:25 UTC
Backport the following fix from upstream:

    commit 7cc7cb8a888bf50c4e118b6bce4c6926321d0689
    Author: Phil Sutter <phil>
    Date:   Tue Aug 23 11:52:45 2016 +0200
    
        ip-route: Prevent some double spaces in output
    
        The code is a bit messy, as it starts with space after text and at some
        point switches to space before text. But either way, printing space
        before *and* after text almost certainly leads to printing more
        whitespace than necessary.
    
        Signed-off-by: Phil Sutter <phil>

Comment 2 Timothy Redaelli 2017-02-10 11:21:31 UTC
Backported commit 7cc7cb8a888bf50c4e118b6bce4c6926321d0689

Comment 4 Jaroslav Aster 2017-03-30 13:10:44 UTC
Unfortunately, it is not fixed. There are still two spaces before features option. Switching to assigned state.

# ip route add 172.29.29.0/24 dev eth0 table 1234
# ip route change 172.29.29.0/24 dev eth0 features ecn table 1234
# ip route show table 1234 | grep 172.29.29.0/24 | grep '  features'
172.29.29.0/24 dev eth0 scope link  features ecn

Comment 5 Phil Sutter 2017-04-04 14:54:04 UTC
Hi Jaroslav,

(In reply to Jaroslav Aster from comment #4)
> Unfortunately, it is not fixed. There are still two spaces before features
> option. Switching to assigned state.
> 
> # ip route add 172.29.29.0/24 dev eth0 table 1234
> # ip route change 172.29.29.0/24 dev eth0 features ecn table 1234
> # ip route show table 1234 | grep 172.29.29.0/24 | grep '  features'
> 172.29.29.0/24 dev eth0 scope link  features ecn

Strictly speaking, this is a different issue. The problems this ticket addressed (namely, fix *some* double spaces in output) are fixed as expected. Yet Timothy is currently preparing a fix for upstream and if it gets accepted I'll kindly pull it in in order to get rid of the remaining issues of this type in ip route output.

Anyway, thanks a lot for having a close look. Iproute output is constantly broken, so I'm aware this is not the most rewarded job out there. :)


Thanks, Phil

Comment 6 Jaroslav Aster 2017-04-10 08:22:52 UTC
Hi Phil,

disagree :-), I have test for that => it is what I have reported to you. Anyway, do your best, it doesn't have hight priority.

Comment 7 Phil Sutter 2017-04-20 12:41:38 UTC
Hi Jaroslav,

(In reply to Jaroslav Aster from comment #6)
> disagree :-), I have test for that => it is what I have reported to you.

Oh, OK! :)

> Anyway, do your best, it doesn't have hight priority.

I have backported Tim's fix:

    commit 5551ed44d394fac6e9a035dadb259580fbda84d3
    Author: Timothy Redaelli <tredaelli>
    Date:   Wed Apr 5 19:10:26 2017 +0200
    
        ip-route: Prevent some other double spaces in output
    
        Print spaces only after text.
    
        CC: Phil Sutter <phil>
        Signed-off-by: Timothy Redaelli <tredaelli>
        Acked-by: Phil Sutter <phil>

Comment 9 errata-xmlrpc 2017-08-01 21:32:13 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://access.redhat.com/errata/RHBA-2017:2171


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