The peer path-attribute-treat command configures a mode in which a device processes specified path attributes in received BGP Update messages.
The undo peer path-attribute-treat command cancels the configuration.
By default, BGP path attributes are processed according to a standard protocol.
Parameter | Description | Value |
---|---|---|
peerIpv4Addr |
Specifies the IPv4 address of a peer. |
The value is an IPv4 address, in dotted decimal notation. |
attribute-id id |
Specifies an attribute ID. |
The value is an integer, which can be: 0: Reserved 11: DPA 12: ADVERTISER 13: RCID_PATH / CLUSTER_ID 16: Extended Communities 19: SAFI Specific Attribute (SSA) 20: Connector Attribute 21: AS_PATHLIMIT 22: PMSI_TUNNEL 23: Tunnel Encapsulation Attribute 24: Traffic Engineering 25: IPv6 Address Specific Extended Community 26: AIGP 27: PE Distinguisher Labels 28: ELC 29: LS_TYPE 30: REMOTE_NEXTHOP 32: LARGE_COMMUNITY 40: PREFIX_SID 128: ATTR_SET 129: WIDE_COMMUNITY 255: Reserved for development 31, 33-39, 41-127, and 130-254: Unassigned |
to id2 |
Specifies an end attribute ID. |
The value is an integer, which can be: 0: Reserved 11: DPA 12: ADVERTISER 13: RCID_PATH / CLUSTER_ID 16: Extended Communities 19: SAFI Specific Attribute (SSA) 20: Connector Attribute 21: AS_PATHLIMIT 22: PMSI_TUNNEL 23: Tunnel Encapsulation Attribute 24: Traffic Engineering 25: IPv6 Address Specific Extended Community 26: AIGP 27: PE Distinguisher Labels 28: ELC 29: LS_TYPE 30: REMOTE_NEXTHOP 32: LARGE_COMMUNITY 40: PREFIX_SID 128: ATTR_SET 129: WIDE_COMMUNITY 255: Reserved for development 31, 33-39, 41-127, and 130-254: Unassigned |
discard |
Discards specified path attributes. |
- |
withdraw |
Withdraws BGP routes with specified path attributes. |
- |
treat-as-unknown |
Processes the specified attributes as unknown attributes. If a specified attribute is optional transitive, the BGP device accepts this attribute and advertises it to other peers; if the specified attribute is of any other type, the BGP device discards this attribute. |
- |
Usage Scenario
A BGP Update message contains various path attributes. If a local device receives Update messages containing malformed path attributes, the involved BGP sessions may flap. To enhance reliability, run the peer path-attribute-treat command to configure a special mode in which a device processes specified path attributes in received BGP Update messages. Special modes indicate those that are not defined in the standard protocol and include the following:
Precautions
This command may cause the specified path attributes to be discarded or routes carrying the path attributes to be withdrawn. Therefore, exercise caution when you run this command.
The command configuration takes effect immediately for the routes received after the command is run. However, for the routes received before the command is run, the configuration can take effect only after the refresh bgp command is run.<HUAWEI> system-view [~HUAWEI] bgp 100 [*HUAWEI-bgp] peer 10.1.1.1 as-number 100 [*HUAWEI-bgp] ipv4-family multicast [*HUAWEI-bgp-af-multicast] peer 10.1.1.1 enable [*HUAWEI-bgp-af-multicast] peer 10.1.1.1 path-attribute-treat attribute-id 19 to 21 discard