contrail control is encoding as number wrongly

Bug #1787978 reported by yong sheng gong
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
Trunk
Fix Committed
High
Nikhil Bansal
OpenContrail
Fix Committed
Undecided
Nikhil Bansal

Bug Description

* 192.168.61.11.54495 > 192.168.62.31.179: Flags [P.], cksum 0xfce2 (incorrect -> 0xcc72), seq 1:66, ack 1, win 229, options [nop,nop,TS val 31521448 ecr 2154131218], length 65: BGP
    Open Message (1), length: 65
      Version 4, my AS 64512, Holdtime 90s, ID 192.168.61.11
      Optional parameters, length: 36
        Option Capabilities Advertisement (2), length: 34
          Multiprotocol Extensions (1), length: 4
        AFI IPv4 (1), SAFI labeled VPN Unicast (128)
        0x0000: 0001 0080
          Multiprotocol Extensions (1), length: 4
        AFI IPv6 (2), SAFI labeled VPN Unicast (128)
        0x0000: 0002 0080
          Multiprotocol Extensions (1), length: 4
        AFI IPv4 (1), SAFI Route Target Routing Information (132)
        0x0000: 0001 0084
          Multiprotocol Extensions (1), length: 4
        AFI VPLS (25), SAFI Unknown (70)
        0x0000: 0019 0046
          32-Bit AS Number (65), length: 4
         4 Byte AS 16515072
        0x0000: 00fc 0000
          Graceful Restart (64), length: 2
        Restart Flags: [none], Restart Time 0s
        0x0000: 0000*

I don’t know when the contrail control encodes the as 64512 as 16515072.

the following is vmx -> control:

    192.168.62.31.64052 > 192.168.61.11.179: Flags [P.], cksum 0x29ab (correct), seq 1:88, ack 1, win 17376, options [nop,nop,TS val 2154262266 ecr 31652497], length 87: BGP
 Open Message (1), length: 87
   Version 4, my AS 64512, Holdtime 90s, ID 192.168.62.31
   Optional parameters, length: 58
     Option Capabilities Advertisement (2), length: 6
       Multiprotocol Extensions (1), length: 4
  AFI IPv4 (1), SAFI labeled VPN Unicast (128)
  0x0000: 0001 0080
     Option Capabilities Advertisement (2), length: 6
       Multiprotocol Extensions (1), length: 4
  AFI IPv6 (2), SAFI labeled VPN Unicast (128)
  0x0000: 0002 0080
     Option Capabilities Advertisement (2), length: 6
       Multiprotocol Extensions (1), length: 4
  AFI IPv4 (1), SAFI Route Target Routing Information (132)
  0x0000: 0001 0084
     Option Capabilities Advertisement (2), length: 6
       Multiprotocol Extensions (1), length: 4
  AFI VPLS (25), SAFI Unknown (70)
  0x0000: 0019 0046
     Option Capabilities Advertisement (2), length: 2
       Route Refresh (Cisco) (128), length: 0
     Option Capabilities Advertisement (2), length: 2
       Route Refresh (2), length: 0
     Option Capabilities Advertisement (2), length: 4
       Graceful Restart (64), length: 2
  Restart Flags: [none], Restart Time 120s
  0x0000: 4078
     Option Capabilities Advertisement (2), length: 6
       32-Bit AS Number (65), length: 4
   4 Byte AS 64512
  0x0000: 0000 fc00
     Option Capabilities Advertisement (2), length: 2
       Unknown (71), length: 0
  no decoder for Capability 71

Revision history for this message
yong sheng gong (gongysh) wrote :

opencontrailnightly/contrail-controller-control-control latest 36e50348f3fb 12 hours ago 809 MB

Revision history for this message
yong sheng gong (gongysh) wrote :

I have tested with old contrail-control code, my control can peer with vmx.

where the control open message does not send as option in open message.

    192.168.61.11.55908 > 192.168.62.31.179: Flags [P.], cksum 0xfcdc (incorrect -> 0xe14b), seq 1:60, ack 1, win 229, options [nop,nop,TS val 91123509 ecr 2213731813], length 59: BGP
 Open Message (1), length: 59
   Version 4, my AS 64512, Holdtime 90s, ID 192.168.61.11
   Optional parameters, length: 30
     Option Capabilities Advertisement (2), length: 28
       Multiprotocol Extensions (1), length: 4
  AFI IPv4 (1), SAFI labeled VPN Unicast (128)
  0x0000: 0001 0080
       Multiprotocol Extensions (1), length: 4
  AFI IPv6 (2), SAFI labeled VPN Unicast (128)
  0x0000: 0002 0080
       Multiprotocol Extensions (1), length: 4
  AFI IPv4 (1), SAFI Route Target Routing Information (132)
  0x0000: 0001 0084
       Multiprotocol Extensions (1), length: 4
  AFI VPLS (25), SAFI Unknown (70)
  0x0000: 0019 0046
       Graceful Restart (64), length: 2
  Restart Flags: [none], Restart Time 0s
  0x0000: 0000

Revision history for this message
yong sheng gong (gongysh) wrote :
Jeba Paulaiyan (jebap)
tags: added: contrail-control contrail-networking
Changed in opencontrail:
assignee: nobody → Nikhil Bansal (nikhilb-u)
Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/45724
Submitter: Nikhil Bansal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/45724
Committed: http://github.com/Juniper/contrail-controller/commit/81df4a5e5bc6ba87972afb80eec4e1894d23db6a
Submitter: Zuul v3 CI (<email address hidden>)
Branch: master

commit 81df4a5e5bc6ba87972afb80eec4e1894d23db6a
Author: Nikhil Bansal <email address hidden>
Date: Thu Aug 23 14:51:43 2018 +0530

bgp open message should encode asn correctly

With 4 btye asn support, bgp open message should contain local asn
as it is if the value is < 0xffff, otherwise it should be as_trans
Also, asn value in capability should be encoded correctly.

Change-Id: I731c2172c586c6719440e85685be46c0eadb9f5f
Closes-Bug: #1787978

Changed in opencontrail:
status: New → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.