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 1487486 - flowlabel for ip6gre can't be set as exptected with ip
Summary: flowlabel for ip6gre can't be set as exptected with ip
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: iproute
Version: 7.4-Alt
Hardware: Unspecified
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Phil Sutter
QA Contact: Jaroslav Aster
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-09-01 05:08 UTC by Jianlin Shi
Modified: 2018-04-10 14:31 UTC (History)
2 users (show)

Fixed In Version: iproute-4.11.0-6.el7
Doc Type: Bug Fix
Doc Text:
Cause: Code modifying flowlabel value of ip6gre devices didn't clear previously set bits of that field. Consequence: Changing the flowlabel value resulted in a new flowlabel value comprised of the old value binary OR'ed with the new one. Fix: Affected code was fixed. Result: Changing flowlabel value now leads to expected results.
Clone Of:
Environment:
Last Closed: 2018-04-10 14:31:17 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2018:0815 0 None None None 2018-04-10 14:31:54 UTC

Description Jianlin Shi 2017-09-01 05:08:10 UTC
Description of problem:
flowlabel for ip6gre can't be set as exptected with ip

Version-Release number of selected component (if applicable):
4.11.0-28.el7a.x86_64

How reproducible:
Always

Steps to Reproduce:
1. set flowlabel for ip6gre as 0x33333
2. set flowlabel for ip6gre as 0x11111

Actual results:
flowlabel is still 0x33333 even set 0x11111

Expected results:
flowlabel is the value set

Additional info:


[root@hp-dl388g8-05 ip6gre]# uname -a
Linux hp-dl388g8-05.rhts.eng.pek2.redhat.com 4.11.0-28.el7a.x86_64 #1 SMP Sat Aug 26 21:09:45 EDT 2017 x86_64 x86_64 x86_64 GNU/Linux

[root@hp-dl388g8-05 ip6gre]# ip link add ip6gre1 type ip6gre local 2000::1 remote 2001::1
[root@hp-dl388g8-05 ip6gre]# ip -d link sh ip6gre1
19: ip6gre1@NONE: <POINTOPOINT,NOARP> mtu 1448 qdisc noop state DOWN mode DEFAULT group default qlen 1000
    link/gre6 20:00:00:00:00:00:00:00:00:00:00:00:00:00:00:01 peer 20:01:00:00:00:00:00:00:00:00:00:00:00:00:00:01 promiscuity 0 
    ip6gre remote 2001::1 local 2000::1 hoplimit 64 encaplimit 4 flowlabel 0x00000 addrgenmode eui64 numtxqueues 1 numrxqueues 1 gso_max_size 65536 gso_max_segs 65535 
[root@hp-dl388g8-05 ip6gre]# ip link set ip6gre1 type ip6gre flowlabel 0x33333
[root@hp-dl388g8-05 ip6gre]# ip -d link sh ip6gre1
19: ip6gre1@NONE: <POINTOPOINT,NOARP> mtu 1448 qdisc noop state DOWN mode DEFAULT group default qlen 1000
    link/gre6 20:00:00:00:00:00:00:00:00:00:00:00:00:00:00:01 peer 20:01:00:00:00:00:00:00:00:00:00:00:00:00:00:01 promiscuity 0 
    ip6gre remote 2001::1 local 2000::1 hoplimit 64 encaplimit 4 flowlabel 0x33333 addrgenmode eui64 numtxqueues 1 numrxqueues 1 gso_max_size 65536 gso_max_segs 65535 
[root@hp-dl388g8-05 ip6gre]# ip link set ip6gre1 type ip6gre flowlabel 0x11111
[root@hp-dl388g8-05 ip6gre]# ip -d link sh ip6gre1
19: ip6gre1@NONE: <POINTOPOINT,NOARP> mtu 1448 qdisc noop state DOWN mode DEFAULT group default qlen 1000
    link/gre6 20:00:00:00:00:00:00:00:00:00:00:00:00:00:00:01 peer 20:01:00:00:00:00:00:00:00:00:00:00:00:00:00:01 promiscuity 0 
    ip6gre remote 2001::1 local 2000::1 hoplimit 64 encaplimit 4 flowlabel 0x33333 addrgenmode eui64 numtxqueues 1 numrxqueues 1 gso_max_size 65536 gso_max_segs 65535 

<==== still 0x33333 even set as 0x11111

Comment 1 Jianlin Shi 2017-09-01 05:36:01 UTC
[root@hp-dl388g8-05 ip6gre]# ip -V
ip utility, iproute2-ss170501
[root@hp-dl388g8-05 ip6gre]# rpm -q iproute
iproute-4.11.0-1.el7a.x86_64

Comment 2 Phil Sutter 2017-09-01 14:16:14 UTC
Fix sent upstream:

https://marc.info/?l=linux-netdev&m=150427491715652&w=2

Comment 3 Phil Sutter 2017-09-01 14:39:09 UTC
Since this issue is not a regression (it exists since introduction of GRE6 support in iproute2), I am rescheduling this ticket to RHEL7.5 (which will become the basis for Pegas1.1 later).

Please let me know if there is an urgent need for the fix to land in Pegas1.0 still so we can try to get exception flag for it.

Comment 4 Phil Sutter 2017-09-28 17:50:16 UTC
Upstream accepted my patch:

commit e7fefb3214b5a1ed030cab9df513560c503a9851
Author: Phil Sutter <phil>
Date:   Fri Sep 1 16:08:08 2017 +0200

    link_gre6: Fix for changing tclass/flowlabel
    
    When trying to change tclass or flowlabel of a GREv6 tunnel which has
    the respective value set already, the code accidentally bitwise OR'ed
    the old and the new value, leading to unexpected results. Fix this by
    clearing the relevant bits of flowinfo variable prior to assigning the
    new value.
    
    Fixes: af89576d7a8c4 ("iproute2: GRE over IPv6 tunnel support.")
    Signed-off-by: Phil Sutter <phil>

Comment 10 errata-xmlrpc 2018-04-10 14:31:17 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/RHEA-2018:0815


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