netenglabs / suzieq

Using network observability to operate and design healthier networks
https://www.stardustsystems.net/
Apache License 2.0
793 stars 106 forks source link

route show for a prefix doesn't give me the originating router, it shows me all the other routers #116

Open jopietsch opened 4 years ago

jopietsch commented 4 years ago

Describe the bug I'm not sure if this is a bug or I just don't understand. I'm lookking up 172.16.253.1. route show doesn't show it on internet device, but address does. shouldn't route show also have it?

To Reproduce

jpiet> route show namespace=single-attach_bgp_numbered  prefix='172.16.253.1'                                                                                                                             Error: 2                      namespace hostname           vrf           prefix                nexthopIps          oifs protocol source  metric  ipvers   action               timestamp
18   single-attach_bgp_numbered   edge01       default  172.16.253.1/32           [169.254.254.9]      [eth1.4]                      20       4  forward 2020-04-27 17:18:47.808
37   single-attach_bgp_numbered   exit01       default  172.16.253.1/32           [169.254.254.2]      [swp5.2]      bgp             20       4  forward 2020-04-27 17:18:47.808
55   single-attach_bgp_numbered   exit01  internet-vrf  172.16.253.1/32           [169.254.127.0]        [swp6]      bgp             20       4  forward 2020-04-27 17:18:47.808
77   single-attach_bgp_numbered   exit02       default  172.16.253.1/32           [169.254.253.2]      [swp5.2]      bgp             20       4  forward 2020-04-27 17:18:47.808
95   single-attach_bgp_numbered   exit02  internet-vrf  172.16.253.1/32          [169.254.253.10]      [swp5.4]      bgp             20       4  forward 2020-04-27 17:18:47.808
133  single-attach_bgp_numbered   leaf01       default  172.16.253.1/32  [10.127.0.0, 10.127.1.0]  [swp1, swp2]      bgp             20       4  forward 2020-04-27 17:18:47.808
154  single-attach_bgp_numbered   leaf02       default  172.16.253.1/32  [10.127.0.2, 10.127.1.2]  [swp1, swp2]      bgp             20       4  forward 2020-04-27 17:18:47.808
175  single-attach_bgp_numbered   leaf03       default  172.16.253.1/32  [10.127.0.4, 10.127.1.4]  [swp1, swp2]      bgp             20       4  forward 2020-04-27 17:18:47.808
196  single-attach_bgp_numbered   leaf04       default  172.16.253.1/32  [10.127.0.6, 10.127.1.6]  [swp1, swp2]      bgp             20       4  forward 2020-04-27 17:18:47.808
240  single-attach_bgp_numbered  spine01       default  172.16.253.1/32              [10.127.0.9]        [swp6]      bgp             20       4  forward 2020-04-27 17:18:47.808
264  single-attach_bgp_numbered  spine02       default  172.16.253.1/32              [10.127.1.9]        [swp6]      bgp             20       4  forward 2020-04-27 17:18:47.808
jpiet> address show namespace=single-attach_bgp_numbered address='172.16.253.1'
                     namespace  hostname ifname    ipAddressList macaddr ip6AddressList state               timestamp
33  single-attach_bgp_numbered  internet     lo  172.16.253.1/32                     []    up 2020-04-27 17:18:47.808
jpiet> 
ddutt commented 2 years ago

Need to add an additional filter called origin=True to show this info. It can only be shown in one of two possible ways:

the first two options are possible today, but not the third.