Configuration Example 3; Filtering As Paths; Figure 2: Filtering With Access Lists - Juniper JUNOSE SOFTWARE FOR E SERIES 11.3.X - IP SERVICES CONFIGURATION GUIDE 2010-10-01 Configuration Manual

Software for e series broadband services routers ip services configuration guide
Table of Contents

Advertisement

JunosE 11.3.x IP Services Configuration Guide

Filtering AS Paths

22
NLPID:
0xcc
IP Address:
192.168.1.105
Metric: 10 IS 0000.0000.6666.01
Metric: 10 IS 0000.0000.3333.00
Metric: 10 IS 0000.0000.7777.00
Metric: 30 IP 20.20.20.0 255.255.255.0
Metric: 30 IP 20.20.21.0 255.255.255.0

Configuration Example 3

The following example demonstrates how to use an access list to filter routes advertised
to a BGP device. Consider the network structure in Figure 2 on page 22.

Figure 2: Filtering with Access Lists

The following commands configure router Boston to apply access list reject1 to routes
inbound from router SanJose. Access list reject1 rejects routes matching 172.24.160.0/19.
host1(config)#router bgp 17
host1(config-router)#neighbor 10.5.5.4 remote-as 873
host1(config-router)#neighbor 10.5.5.4 distribute-list reject1 in
host1(config-router)#exit
host1(config)#access-list reject1 permit 172.24.48.0 0.0.255
host1(config)#access-list reject1 deny 172.24.160.0 0.0.0.255
host1(config)#access-list reject1 permit 172.24.24.0 0.0.0.255
You can use a filter list to filter incoming and outgoing routes based on the value of the
AS-path attribute. Whenever a BGP route passes through an AS, BGP prepends its AS
number to the AS-path attribute. The AS-path attribute is the list of ASs that a route has
passed through to reach a destination.
To filter routes based on the AS path, define the access list with the ip as-path access-list
command, and apply the list to routes received from or passed to a neighbor with the
neighbor filter-list command. AS-path access lists use regular expressions to describe
the AS path to be matched. A regular expression uses special characters—often referred
to as metacharacters—to define a pattern that is compared with an input string. For a
full discussion of regular expressions, with examples of how to use them, see "Using
Regular Expressions" on page 42.
Copyright © 2010, Juniper Networks, Inc.

Advertisement

Table of Contents
loading

This manual is also suitable for:

Junose 11.3

Table of Contents