DIGITAL GIGAswitch/Router User Reference Manual
109
Basic BGP Tasks
For example:
(4250 .*)
Means anything beginning with 4250.
(.* 6301 .*) Means anything with 6301.
(.* 4250)
Means anything ending with 4250.
(. * 1104|1125|1888|1135 .*)
Means anything containing 1104 or 1125 or 1888 or 1135.
AS-path regular expressions are used as one of the parameters for determining which
routes are accepted and which routes are advertised.
AS-Path Regular Expression Examples
To import MCI routes with a preference of 165:
To import all routes (.* matches all AS paths) with the default preference:
To export all active routes from 284 or 813 or 814 or 815 or 816 or 3369 or 3561 to
autonomous system 64800.
ip-router policy create bgp-import-source mciRoutes aspath-regular-
expression "(.* 3561 .*)" origin any sequence-number 10
ip-router policy import source mciRoutes network all preference 165
ip-router policy create bgp-import-source allOthers aspath-regular-
expression "(.*)" origin any sequence-number 20
ip-router policy import source allOthers network all
ip-router policy create bgp-export-destination to-64800 autonomous-
system 64800
ip-router policy create aspath-export-source allRoutes aspath-regular-
expression "(.*(284|813|814|815|816|3369|3561) .*)" origin any
protocol all
ip-router policy export destination to-64800 source allRoutes network
all