Closed treemanzhou closed 6 years ago
Hello @treemanzhou
You are not providing your configuration and the output of ExaBGP with the option -d
I have no idea what route you sent, and what could have gone wrong, but the fact that your router consider one of the route received as invalid.
I can not help you without more information.
i added the -d option and there is no detail output . from the pcap in attachment , i saw the notification message said no match with the V and L flag (i guess that is the flags in ISIS prefix-SID TLV)
) here is my command , and the output is the same as before i presented. ./exabgp -d bgp_bgpls.conf
and my configuration below
process parsed-route-backend { run linkstate.py; encoder json; } neighbor 192.168.255.10 { local-address 10.20.200.1; local-as 65200; peer-as 65200; family{ bgp-ls bgp-ls; }
api {
processes [ parsed-route-backend ];
receive {
parsed;
update;
}
}
} need help thx
You are still not providing me with what your program generated as command AND the output of exabgp -d .. Therefore I still can not help you. If there was not detailed output, it probably mean that you are using a packaged version of ExaBGP which is sending the logs to syslog .. if so, please use the latest version from GitHub.
Hi thomas
i git the latest version and run exabgp -d bgp.conf ,still no detail output ........
"/var/log/exabgp.log" 3788L, 639561C 3,1 Top Wed, 14 Mar 2018 10:05:54 12338 outgoing-9 << message of type UPDATE Wed, 14 Mar 2018 10:05:54 12338 parser parsing UPDATE ( 236) 0000 00E8 900E 0062 4004 4704 AC10 FF0A 0000 0200 5502 0000 0000 0000 0000 0100 001A 0200 0004 00 00 FEB0 0201 0004 0000 0000 0203 0006 0100 1700 2004 0101 001A 0200 0004 0000 FEB0 0201 0004 0000 0000 0203 0006 2232 0204 9002 0103 0004 AC10 FE26 0104 0004 AC10 FE2 5 4001 0100 4002 0040 0504 0000 0064 801D 7104 0400 04AC 10FF 0A04 0600 04AC 10FF 0104 4000 0400 0000 0004 4100 044E 9502 F904 4200 0400 0000 0004 4300 2000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0004 4400 0400 0000 3204 4700 0300 0032 044B 0007 7000 0000 005E CC04 4B00 0730 0000 0000 5ECD Wed, 14 Mar 2018 10:05:54 12338 parser withdrawn NLRI none Wed, 14 Mar 2018 10:05:54 12338 parser attribute mp-reach-nlri flag 0x90 type 0x0e len 0x62 payload 4004 4704 AC10 FF0A 0000 0200 5502 0000 0000 0000 000 0 0100 001A 0200 0004 0000 FEB0 0201 0004 0000 0000 0203 0006 0100 1700 2004 0101 001A 0200 0004 0000 FEB0 0201 0004 0000 0000 0203 0006 2232 0204 9002 0103 0004 AC10 FE26 0104 0004 AC10 FE25 Wed, 14 Mar 2018 10:05:54 12338 parser NLRI bgp-ls bgp-ls without path-information payload 0002 0055 0200 0000 0000 0000 0001 0000 1A02 0000 040 0 00FE B002 0100 0400 0000 0002 0300 0601 0017 0020 0401 0100 1A02 0000 0400 00FE B002 0100 0400 0000 0002 0300 0622 3202 0490 0201 0300 04AC 10FE 2601 0400 04AC 10FE 25 Wed, 14 Mar 2018 10:05:54 12338 parser attribute origin flag 0x40 type 0x01 len 0x01 payload 00 Wed, 14 Mar 2018 10:05:54 12338 parser attribute as-path flag 0x40 type 0x02 len 0x00 Wed, 14 Mar 2018 10:05:54 12338 parser attribute local-preference flag 0x40 type 0x05 len 0x04 payload 0000 0064 Wed, 14 Mar 2018 10:05:54 12338 parser attribute bgp-ls flag 0x80 type 0x1d len 0x71 payload 0404 0004 AC10 FF0A 0406 0004 AC10 FF01 0440 0004 000 0 0000 0441 0004 4E95 02F9 0442 0004 0000 0000 0443 0020 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0444 0004 0000 0032 0447 0003 0000 3204 4B00 0770 0000 0000 5ECC 044B 0007 3000 0000 005E CD Wed, 14 Mar 2018 10:05:54 12338 parser announced NLRI none Wed, 14 Mar 2018 10:05:54 12338 peer-1 << UPDATE #4 Wed, 14 Mar 2018 10:05:54 12338 peer-1 UPDATE #4 nlri ( 2) { "ls-nlri-type": 2, "l3-routing-topology": 0, "protocol-id": 2, "local-node-descriptors": {
Wed, 14 Mar 2018 10:05:54 12338 outgoing-9 received TCP payload ( 19) FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF 007C 02 Wed, 14 Mar 2018 10:05:54 12338 outgoing-9 received TCP payload ( 105) 0000 0065 900E 003D 4004 4704 AC10 FF0A 0000 0300 3002 0000 0000 0000 0000 0100 001A 0200 0 004 0000 FEB0 0201 0004 0000 0000 0203 0006 0100 1700 8006 0109 0005 20AC 10FF 0340 0101 0040 0200 4005 0400 0000 6480 1D13 0483 0004 0000 0000 0486 0007 4000 0000 00 00 03 Wed, 14 Mar 2018 10:05:54 12338 outgoing-9 << message of type UPDATE Wed, 14 Mar 2018 10:05:54 12338 parser parsing UPDATE ( 105) 0000 0065 900E 003D 4004 4704 AC10 FF0A 0000 0300 3002 0000 0000 0000 0000 0100 001A 0200 0004 00 00 FEB0 0201 0004 0000 0000 0203 0006 0100 1700 8006 0109 0005 20AC 10FF 0340 0101 0040 0200 4005 0400 0000 6480 1D13 0483 0004 0000 0000 0486 0007 4000 0000 0000 03 Wed, 14 Mar 2018 10:05:54 12338 parser withdrawn NLRI none Wed, 14 Mar 2018 10:05:54 12338 parser attribute mp-reach-nlri flag 0x90 type 0x0e len 0x3d payload 4004 4704 AC10 FF0A 0000 0300 3002 0000 0000 0000 000 0 0100 001A 0200 0004 0000 FEB0 0201 0004 0000 0000 0203 0006 0100 1700 8006 0109 0005 20AC 10FF 03 Wed, 14 Mar 2018 10:05:54 12338 parser NLRI bgp-ls bgp-ls without path-information payload 0003 0030 0200 0000 0000 0000 0001 0000 1A02 0000 040 0 00FE B002 0100 0400 0000 0002 0300 0601 0017 0080 0601 0900 0520 AC10 FF03 Wed, 14 Mar 2018 10:05:54 12338 parser attribute origin flag 0x40 type 0x01 len 0x01 payload 00 Wed, 14 Mar 2018 10:05:54 12338 parser attribute as-path flag 0x40 type 0x02 len 0x00 Wed, 14 Mar 2018 10:05:54 12338 parser attribute local-preference flag 0x40 type 0x05 len 0x04 payload 0000 0064 Wed, 14 Mar 2018 10:05:54 12338 parser attribute bgp-ls flag 0x80 type 0x1d len 0x13 payload 0483 0004 0000 0000 0486 0007 4000 0000 0000 03 Wed, 14 Mar 2018 10:05:54 12338 outgoing-9 sending TCP payload ( 68) FFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFF 0044 0303 0553 4944 2F4C 6162 656C 2073 697A 6520 64 6F 6573 6E27 7420 6D61 7463 6820 5620 616E 6420 4C20 666C 6167 2073 7461 7465 Wed, 14 Mar 2018 10:05:54 12338 outgoing-9 >> NOTIFICATION (3,5,"SID/Label size doesn't match V and L flag state") Wed, 14 Mar 2018 10:05:54 12338 outgoing-9 peer reset, message [notification sent (3,5)] error[UPDATE message error / Attribute Length Error / SID/Label size does n't match V and L flag state] Wed, 14 Mar 2018 10:05:54 12338 outgoing-9 outgoing-9 10.20.253.8-172.16.255.10, closing connection Wed, 14 Mar 2018 10:06:02 12338 reactor ^C received Wed, 14 Mar 2018 10:06:02 12338 reactor performing shutdown Wed, 14 Mar 2018 10:06:02 12338 process terminating process parsed-route-backend-linkstate Wed, 14 Mar 2018 10:06:02 12338 daemon Removed PIDfile /var/run/exabgp.pid
============================================================ anything else I can do to fix this ?
Hi @treemanzhou,
What version of IOS XR are you using?
From what I can see the flags the router is sending to ExaBGP are these: {'E': 0, 'L': 0, 'N': 1, 'P': 0, 'R': 0, 'V': 0, 'RSV': 0}
If those are indeed the flags, then I'm afraid it's an IOS-XR bug, unless my interpretation of the draft is incorrect. Quoting the draft:
SID/Index/Label: according to the V and L flags, it contains
either:
* A 4 octet index defining the offset in the SID/Label space
advertised by this router using the encodings defined in
Section 3.1. In this case the V and L flags MUST be unset.
* A 3 octet local label where the 20 rightmost bits are used for
encoding the label value. In this case the V and L flags MUST
be set.
In this case ExaBGP complains about the index being only 3 octets long, instead of 4, as it should be because both V and L are unset.
Let me know what the BGP dissector in Wireshark is telling you and I'll check if we're parsing the TLV incorrectly if you're not seeing the same flags and prefix length as I mentioned above(look at the UPDATE message sent by your ios box, right before the NOTIFICATION sent by ExaBGP)
cheers, Evelio
Hi @ruissalo
First thanks for your reply , The version of my router box is "Cisco IOS XR Software, Version
6.1.4[Default] " . I run segment routing on my production environments.
As the pcap below . that's might be a bug , can i work around it ?
###########################################
@treemanzhou - I did not write the part of the code .. but .. you could modify the code inlib/exabgp/bgp/message/update/attribute/bgpls/prefix/srprefix.py
to accept a TLV length <> 4 and see if it works for you.
if len(data) != 4:
# Cisco IOS XR Software, Version 6.1.1.19I is not
# correctly setting the flags
raise Notify(3,5, "SID/Label size doesn't match V and L flag state")
@thomas-mangin @ruissalo
it works !! really appreciate! that's great help
thank you @thomas-mangin :)
@ruissalo no - thank YOU - for helping 👍 but let's end the bromance here 🤣
ISSUE TYPE
OS
CentOS release 6.7 (Final)
VERSION
ENVIRONMENT
CONFIGURATION
SUMMARY
the router 's neighbor the exabge become flapping when i run segmentrouting feather in my igp .
router: RP/0/RSP0/CPU0:Mar 12 14:02:56.520 : bgp[1058]: %ROUTING-BGP-5-ADJCHANGE : neighbor 10.20.200.1 Down - BGP Notification received, invalid length for attribute (VRF: default) (AS: 65000) RP/0/RSP0/CPU0:Mar 12 14:03:03.593 : bgp[1058]: %ROUTING-BGP-5-ADJCHANGE : neighbor 10.20.200.1 Up (VRF: default) (AS: 65000) RP/0/RSP0/CPU0:Mar 12 14:03:08.661 : bgp[1058]: %ROUTING-BGP-5-ADJCHANGE : neighbor 10.20.200.1 Down - BGP Notification received, invalid length for attribute (VRF: default) (AS: 65000) RP/0/RSP0/CPU0:Mar 12 14:03:17.729 : bgp[1058]: %ROUTING-BGP-5-ADJCHANGE : neighbor 10.20.200.1 Up (VRF: default) (AS: 65000)
exabgp: 14:21:13 | 22138 | welcome | Thank you for using ExaBGP 14:21:13 | 22138 | version | 4.0.2-1c737d99 14:21:13 | 22138 | interpreter | 2.7.12 (default, Mar 2 2017, 10:26:20) [GCC 4.4.7 20120313 (Red Hat 4.4.7-11)] 14:21:13 | 22138 | os | Linux 20-200-1 2.6.32-504.30.3.el6.x86_64 #1 SMP Wed Jul 15 10:13:09 UTC 2015 x86_64 14:21:13 | 22138 | installation |
14:21:13 | 22138 | cli | could not find the named pipes (exabgp.in and exabgp.out) required for the cli 14:21:13 | 22138 | cli | we scanned the following folders (the number is your PID): 14:21:13 | 22138 | cli control | - /run/0/ 14:21:13 | 22138 | cli control | - /run/ 14:21:13 | 22138 | cli control | - /var/run/0/ 14:21:13 | 22138 | cli control | - /var/run/ 14:21:13 | 22138 | cli control | - /run/0/ 14:21:13 | 22138 | cli control | - /run/ 14:21:13 | 22138 | cli control | - /var/run/0/ 14:21:13 | 22138 | cli control | - /var/run/ 14:21:13 | 22138 | cli control | please make them in one of the folder with the following commands: 14:21:13 | 22138 | cli control | > mkfifo /root/bgp_conn/run/exabgp.{in,out} 14:21:13 | 22138 | cli control | > chmod 600 /root/bgp_conn/run/exabgp.{in,out} 14:21:13 | 22138 | configuration | performing reload of exabgp 4.0.2-1c737d99 14:21:13 | 22138 | configuration | > process | 'parsed-route-backend' 14:21:13 | 22138 | configuration | . run | 'linkstate.py' 14:21:13 | 22138 | configuration | . encoder | 'json' 14:21:13 | 22138 | configuration | < process | 14:21:13 | 22138 | configuration | > neighbor | '192.168.255.10' 14:21:13 | 22138 | configuration | . local-address | '10.20.200.1' 14:21:13 | 22138 | configuration | . local-as | '65000' 14:21:13 | 22138 | configuration | . peer-as | '65000' 14:21:13 | 22138 | configuration | > family | 14:21:13 | 22138 | configuration | . bgp-ls | 'bgp-ls' 14:21:13 | 22138 | configuration | < family | 14:21:13 | 22138 | configuration | > api | 14:21:13 | 22138 | configuration | . processes | '[' 'parsed-route-backend' ']' 14:21:13 | 22138 | configuration | > receive | 14:21:13 | 22138 | configuration | . parsed | 14:21:13 | 22138 | configuration | . update | 14:21:13 | 22138 | configuration | < receive | 14:21:13 | 22138 | configuration | < api | 14:21:13 | 22138 | configuration | < neighbor | 14:21:13 | 22138 | reactor | new peer: neighbor 192.168.255.10 local-ip 10.20.200.1 local-as 65000 peer-as 65200 router-id 10.20.200.1 family-allowed in-open 14:21:13 | 22138 | reactor | loaded new configuration successfully 14:21:13 | 22138 | process | forked process parsed-route-backend
STEPS TO REPRODUCE
EXPECTED RESULTS
ACTUAL RESULTS
IMPORTANCE