cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2529
Views
105
Helpful
18
Replies

NXOS BGP route summary per neighbour

chris net
Level 1
Level 1

Hello

I'm trying to summarise bgp routes from a 9k to an individual 3k neighbour in a vrf with additional neighbours that should not get the summaries, ideally summarising down to rfc1918 .

 

I see the

aggregate-address 10.0.0.0/8 summary-only

command that can be applied in the address family of the vrf bgp config, but that applies to all the vrf neighbours, I can't find an equivalent that can be applied to the vrf's neighbours config.

 

any suggestions on how I can summarise to a specific bgp neighbour?

 

I see https://learningnetwork.cisco.com/s/question/0D53i00000KsxJKCAZ/how-to-advertise-bgp-summary-to-specific-neighbor-?t=1652876957196 but the 

neighbor distribute-list

does not work on nxos.

 

looking forward to any responses.

 

 

18 Replies 18

So when we try help you we doubt you.

Thanks.

@MHM Cisco World 
In the politest way possible, I’m not sure what you are getting at. 

if you think something is possible then please provide example code of your solution and I, and others, can then evaluate it and see if it works for our use cases. 

@Harold Ritter mentioned some things and I was able to put code together that used what he mentioned and for clarity I posted my code which works for me, if it doesn’t work for you then explain what does not work.

It’s not been possible to create code from your suggestions to work with my use case. 

if you provide the code in an example then great, we can all have a look. 

otherwise we have at best a logic disconnect.

ip prefix-list pl-rfc1918 seq 10 permit 10.0.0.0/8
ip prefix-list pl-rfc1918 seq 20 permit 172.16.0.0/12
ip prefix-list pl-rfc1918 seq 30 permit 192.168.0.0/16

route-map remove-null0-address deny 10
  match prefix-list pl-rfc1918

route-map remove-null0-address permit 100


route-map add-null0-address permit 10
  match prefix-list pl-rfc1918

router bgp 1234
vrf 3k
    timers bgp 1 3
    address-family ipv4 unicast
    redistribute eigrp 1 route-map req-eigrp-routes
    aggregate-address 10.0.0.0/8 as-set<-remove and add static route null0
    aggregate-address 172.16.0.0/12 as-set<-remove and add static route null0
    aggregate-address 192.168.0.0/16 as-set<-remove and add static route null0
    neighbor 10.10.10.1
      remote-as 12345
      description set up eBGP with R1-7K
      password passwordfortest1
      update-source Ethernet1/1
      address-family ipv4 unicast
        route-map rm-remove-null9-address out
        route-map R1-R3-statics in
        soft-reconfiguration inbound always
    neighbor 172.16.254.90
      remote-as 12346
      description set up eBGP with R2-7K
      password passwordfortest2
      update-source Ethernet1/2
      address-family ipv4 unicast
        route-map rm-remove-null0-address out
        soft-reconfiguration inbound always

    neighbor 192.168.202.101
      remote-as 12347
      description set up eBGP with R3-3k
      password passwordfortest1
      update-source Ethernet1/3

      address-family ipv4 unicast
        route-map add-null0-address out
        soft-reconfiguration inbound always

this what I mean, do try this way ? 

 

a logic disconnect it is then!!

 

at least this question now contains examples of both ways of doing this. 

FYI if you look at the docs I’ve quoted it mentions that aggregate-address does the null route procedure for you. 

they are effectively the same thing, pros and cons for doing either, you’d choose 1 way or the other if you needed something specific.

 

I hope this all helps someone coming across this. 

Review Cisco Networking for a $25 gift card