check out the 'sh run' and see if that version of IOS puts them on the same
line:
route-map TST deny 10
match as-path 3 5
which is an OR
my version will not put multiple as-path statements on separate lines, only
a match of a different value:
route-map TST deny 10
match metric 1
match tag 1
match as-path 3 5
match community 1
match policy-list TST_AND
i thought a policy-list might do the trick but it does the same thing:
ip policy-list TST_AND permit
match metric 0
match as-path 3 5
-- Garry L. Baker "There is no 'patch' for stupidity." - www.sqlsecurity.com On Tue, Nov 23, 2010 at 12:53 PM, Jack Router <pan.router_at_gmail.com> wrote: > Hello all, > > I have a problem with a route-map. Here is the scenario: > > R1(AS1)----R2(AS2)----R3(AS3)----R4(AS4)----R5(AS5)----R6(AS6) > > Routers advertise networks: R1: 1.0.0.0, R2: 2.0.0.0 etc... > > On R1 I want to filter routes that traversed AS3 *AND* originated in AS5. I > want to use route-map to do this. > > Step 1. Define as-path access list: > # ip as-path access-list 3 permit _3_ > # ip as-path access-list 5 permit _5$ > > Step 2. Match as-path in route map. This route map is meant to match both > as-path access lists: > # route-map TST deny 10 > # match as-path 3 > # match as-path 5 > # route-map TST permit 99 > > Step 3. Apply route-map to neighbor in AS2: > # router bgp 1 > # neighbor 10.1.12.2 route-map TST in > > At this point I should see on R1 all prefixs with xception of 5.0.0.0 > > "sh ip bgp" shows now: > > *> 1.0.0.0 0.0.0.0 0 32768 i > *> 2.0.0.0 10.1.12.2 0 0 2 i > > It looks that only as-path 3 was applied. Why ? > My understanding is that if multiple match statement are present within > single route-map instance, thy ALL must match. In this case only 5.0.0.0 > matches both access-lists and only 5.0.0.0 should be removed from R1. > > > Blogs and organic groups at http://www.ccie.net > > _______________________________________________________________________ > Subscription information may be found at: > http://www.groupstudy.com/list/CCIELab.html Blogs and organic groups at http://www.ccie.netReceived on Tue Nov 23 2010 - 14:25:17 ART
This archive was generated by hypermail 2.2.0 : Sun Dec 05 2010 - 22:14:56 ART