Hello,
This is pretty easy if You remember how JUNOS evaluates communities (hint-they are treated as strings):
Community regular expressions evaluate the string specified in term on a
character-by-character basis
So, if You recall that regular communities are essentially "1-to-5 decimal digits {colon} 1-to-5 decimal digits " strings, then You need to define Your regular community as
set policy-options community std members "^[0-9]{1,5}:[0-9]{1,5}"
Lab verification:
regress@VMX> show configuration routing-instances TEST { instance-type vrf; route-distinguisher 169.254.3.242:3; vrf-import remove-std; vrf-export vrf-export; vrf-table-label; } regress@VMX> show configuration policy-options policy-statement remove-std term 1 { from community [ std test ]; then { community delete std; next term; } } term 2 { from community test; then accept; } regress@VMX> show configuration policy-options | grep members community std members "^[0-9]{1,5}:[0-9]{1,5}"; community test members target:65000:3;
And the route in question is 198.51.100.3/32.
regress@VMX> show route receive-protocol bgp 169.254.0.252 table bgp.l3vpn.0 extensive 198.51.100.3/32 bgp.l3vpn.0: 3 destinations, 3 routes (3 active, 0 holddown, 0 hidden) * 169.254.3.231:3:198.51.100.3/32 (1 entry, 0 announced) Import Accepted Route Distinguisher: 169.254.3.231:3 VPN Label: 16 Nexthop: 169.254.3.231 Localpref: 100 AS path: I (Originator) Cluster list: 169.254.0.252 Originator ID: 169.254.3.231 Communities: 65000:65000 target:65000:3 bandwidth:65000:200 regress@VMX> show route table TEST.inet.0 198.51.100.3/32 detail | grep commun Communities: target:65000:3 bandwidth:65000:200
^
|
+--- regular community 65000:65000 missing!
HTH
Thx
Alex