R5.1.0 - 4-Octet ASN :: config node does not pass 4 Octet ASN to the control and peering with MX fails.
Affects | Status | Importance | Assigned to | Milestone | ||
---|---|---|---|---|---|---|
Juniper Openstack | Status tracked in Trunk | |||||
Trunk |
Fix Committed
|
High
|
Nikhil Bansal |
Bug Description
I saw that from config, the ASN coming to the control-node still seems to be 64512 only.
2018-09-21 12:03:20.966 BgpConfigNeighb
I tried to modify the ASN in the GlobalSystemConfig to 75000, but see that API doesn't take any value between 1-65534. Is there some knob that we can modify to allow 4-byte ASN number:
>>> g1=vh.global_
>>> g1.get_
64512
>>> g1.set_
>>> vh.global_
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/
return func(self, *args, **kwargs)
File "/usr/lib/
OP_PUT, uri, data=json_body)
File "/usr/lib/
retry_
File "/usr/lib/
raise BadRequest(status, content)
vnc_api.
Thanks & Regards,
Ganesha HV.
"To be conscious that you're ignorant, is a great step to success" - Dr.Kalam
_______
From: Ritam Gangopadhyay
Sent: Friday, September 21, 2018 1:04:15 PM
To: Nikhil Bansal
Cc: Ganesha H V; Sudheendra Rao
Subject: Peering fails when ASN is set to 75000.
Hi Nikhil,
I have configured internal bgp on the MX with ASN as 75000 and on the controller I added the bgp router with same configs. I see peering is failing with this. Am I going wrong with the configuration somewhere.
[edit]
root@blr-mx2# run show bgp group testbed_
Group Type: Internal AS: 75000 Local AS: 75000
Name: testbed_
Options: <LocalAS>
Holdtime: 0 Local AS: 75000 Local System AS: 75000
Total peers: 1 Established: 0
192.168.100.11
Trace options: detail packets
Trace file: /var/log/
[edit]
root@blr-mx2#
Logs from MX:-
Sep 21 07:13:45.566882 BGP RECV 192.168.100.11+179 -> 192.168.
Sep 21 07:13:45.566941 BGP RECV message type 1 (Open) length 71
Sep 21 07:13:45.566969 BGP RECV version 4 as 64512 holdtime 90 id 192.168.100.11 parmlen 42
Sep 21 07:13:45.566986 BGP RECV MP capability AFI=1, SAFI=128
Sep 21 07:13:45.567002 BGP RECV MP capability AFI=2, SAFI=128
Sep 21 07:13:45.567017 BGP RECV MP capability AFI=1, SAFI=132
Sep 21 07:13:45.567033 BGP RECV MP capability AFI=25, SAFI=70
Sep 21 07:13:45.567048 BGP RECV MP capability AFI=1, SAFI=243
Sep 21 07:13:45.567067 BGP RECV 4 Byte AS-Path capability (65), as_num 64512
Sep 21 07:13:45.567085 BGP RECV Restart capability, code=64, time=0, flags=
Sep 21 07:13:45.567289 bgp_parse_
Sep 21 07:13:45.567360 bgp_process_
Sep 21 07:13:45.567385 BGP_75000.
Sep 21 07:13:45.567409
Sep 21 07:13:45.567409 BGP SEND 192.168.
Sep 21 07:13:45.567435 BGP SEND message type 3 (Notification) length 21
Sep 21 07:13:45.567452 BGP SEND Notification code 2 (Open Message Error) subcode 2 (bad peer AS number)
Sep 21 07:13:45.567567 BGP_75000.
Sep 21 07:13:45.567609 bgp_send_
Sep 21 07:14:00.971174
This is the configuration on the router:-
[edit]
root@blr-mx2# show routing-options autonomous-system
75000;
[edit]
root@blr-mx2# show protocols bgp group testbed_
type internal;
traceoptions {
file bgp_4byte_asn.log size 65535 world-readable;
flag packets detail;
}
local-address 192.168.100.100;
keep all;
family inet-vpn {
unicast;
}
family route-target;
local-as 75000;
neighbor 192.168.100.11 {
peer-as 75000;
}
The bgp-router config on the control node:-
[root@nodec28 ~]# curl -X GET -H "X-Auth-Token: dd0e878b97514fb
% Total % Received % Xferd Average Speed Time Time Time Current
100 1674 100 1674 0 0 17830 0 --:--:-- --:--:-- --:--:-- 18000
{
"bgp-router": {
},
{
},
],
}
],
"fq_name": [
],
"href": "http://
"id_perms": {
},
"uuid": {
}
},
"name": "blr-mx2",
"perms2": {
},
"uuid": "d84af715-
}
}
[root@nodec28 ~]#
Regards,
Ritam.
I was able to change the Local ASN on the bgp_router using the following snippet:
>>> b1=vh.bgp_ router_ read(id= 'd84af715- 31b2-4798- 9ab7-670f0fbc72 ad') bgp_router_ refs()] bgp_router_ refs()] s_system = 0, address_families = family = [], auth_data = None, family_attributes = [], private_as_action = None, route_origin_ override = None]]] domain' , u'default-project', u'ip-fabric', u'__default__', u'nodec28']] list[0] .session[ 0].attributes[ 0] list[0] .session[ 0].attributes[ 0].set_ local_autonomou s_system( 75000) s_system = 75000, address_families = family = [], auth_data = None, family_attributes = [], private_as_action = None, route_origin_ override = None]]] bgp_router_ list(ref_ obj_list, ref_data_list) router_ update( b1) 10.204. 217.13: 8082/bgp- router/ d84af715- 31b2-4798- 9ab7-670f0fbc72 ad", "uuid": "d84af715- 31b2-4798- 9ab7-670f0fbc72 ad"}}' router_ update( b1) 10.204. 217.13: 8082/bgp- router/ d84af715- 31b2-4798- 9ab7-670f0fbc72 ad", "uuid": "d84af715- 31b2-4798- 9ab7-670f0fbc72 ad"}}'
>>> ref_obj_list = [ref['to'] for ref in b1.get_
>>> ref_data_list = [ref['attr'] for ref in b1.get_
>>> ref_data_list
[session = [uuid = None, attributes = [bgp_router = None, admin_down = False, passive = False, as_override = False, hold_time = 0, loop_count = 0, local_autonomou
>>> ref_obj_list
[[u'default-
>>> ref_data_
>>> ref_data_
>>> ref_data_list
[session = [uuid = None, attributes = [bgp_router = None, admin_down = False, passive = False, as_override = False, hold_time = 0, loop_count = 0, local_autonomou
>>> b1.set_
>>> vh.bgp_
u'{"bgp-router": {"href": "http://
>>> vh.bgp_
u'{"bgp-router": {"href": "http://
>>>
Now the BGP session is Established.
[edit]
root@blr-mx2# run show bgp neighbor 192.168.100.11 | grep Established
Type: Internal State: Established Flags: <Sync>
[edit] bgp_4byte_ asn.log size 65535 files 10
root@blr-mx2# run show bgp neighbor 192.168.100.11 | grep byte
Peer supports 4 byte AS extension (peer-as 75000)
Trace file: /var/log/
[edit]
16 16 0 0 0 0
0 0 0 0 0 0
0 0 0 0 0 0
0 0 0 0 0 0
0 0 0 0 0 0
0 0 0 0 0 0 Active/ Received/ Accepted/ Damped. ..
root@blr-mx2# run show bgp summary
Groups: 11 Peers: 16 Down peers: 14
Table Tot Paths Act Paths Suppressed History Damp State Pending
bgp.rtarget.0
bgp.l3vpn.0
inet6.0
bgp.l3vpn-inet6.0
bgp.evpn.0
inet.0
Peer AS InPkt OutPkt OutQ Flaps Last Up/Dwn State|#
10.10.11.16 64512 0 0 0 509 4d 5:10:42 Active
10.10.11.17 64512 0 0 0 559 4d 5:10:04 Active
10.10.11.18 64512 0 0 0 497 4d 5:09:38 Active
10.204.216.232 64520 19 19 0 16 7:16 Establ
bgp.rtarget.0: 13/13/13/0
bgp.l3vpn.0: 0/0/0/0
10.204.217.4 64512...