Layer 3 Routing Commands 1408set as-pathTo prepend one or more AS numbers to the AS path in a BGP route, use theset as-path command. To remove a set command from a route map, use theno form of this command.Syntaxset as-path prepend as-path-stringno set as-path prepend as-path-string• prepend as-path-string—A list of AS path numbers to insert at thebeginning of the AS_PATH attribute of matching BGP routes. To prependmore than one AS number, separate the ASNs with a space and enclose thestring in quotes. Up to ten AS numbers may be prepended.Default ConfigurationNo AS paths are prepending by default.Command ModeRoute ConfigurationUser GuidelinesThis command is normally used to insert one or more instances of the localAS number at the beginning of the AS_PATH attribute of a BGP route.Doing so increases the AS path length of the route. The AS path length has astrong influence on BGP route selection. Changing the AS path length caninfluence route selection on the local router or on routers to which the routeis advertised.When prepending an inbound route, if the first segment in the AS_PATH ofthe received route is an AS_SEQUENCE, as-path-string is inserted at thebeginning of the sequence. If the first segment is an AS_SET, as-path-string isadded as a new segment with type AS_SEQUENCE at the beginning of theAS path. When prepending an outbound route to an external peer, as-path-string follows the local AS number, which is always the first ASN.Command HistoryIntroduced in version 6.2.0.1 firmware.