BGP aggregation example

Hello
just a quick question:

CCR1036 with 1 upstream and 2x public peering lans.
I announce 4x /22 classess (BGP Networks).

How can I announce to specific peers, individual /23 or /24 instead than the full /22 ?

can someone write an example?
thank you

You can add all the prefixes (/22, /23, /24) in Routing > BGP > Networks.

And then use separate filters on each peer to filter out which of those prefixes will be announced to each BGP peer.

I suggest you first create the filters, apply them to the BGP peers and then add the more specific prefixes to Routing > BGP > Networks so they don’t leak out before your filters are ready.

Example filters:
For your upstream (announce only /22s)

/routing filter add chain=upstream prefix=1.1.0.0/22 action=accept
/routing filter add chain=upstream prefix=1.1.4.0/22 action=accept
/routing filter add chain=upstream prefix=1.1.8.0/22 action=accept
/routing filter add chain=upstream prefix=1.1.12.0/22 action=accept
/routing filter add chain=upstream action=discard

For peer1 (announce only 2 /24s)

/routing filter add chain=peer1 prefix=1.1.0.0/24 action=accept
/routing filter add chain=peer1 prefix=1.1.1.0/24 action=accept
/routing filter add chain=peer1 action=discard

For peer2 (announce only 2 other /24s)

/routing filter add chain=peer2 prefix=1.1.3.0/24 action=accept
/routing filter add chain=peer2 prefix=1.1.4.0/24 action=accept
/routing filter add chain=peer2 action=discard

You then assign those filters to each BGP peer respectively and add the more specific prefixes to Routing > BGP > Networks.

You can check what you announce to each peer in Routing > BGP > Advertisements to make sure the proper prefixes are announced.