unicast-route label advertise

Function

The unicast-route label advertise command enables a device to convert received IPv4 public network unicast routes to labeled routes by allocating one BGP label to each route and advertise the labeled routes to peers with the labeled route exchange capability.

The undo unicast-route label advertise command restores the default configuration.

By default, a device does not convert received IPv4 public network unicast routes to labeled routes.

Format

unicast-route label advertise

undo unicast-route label advertise

undo unicast-route label advertise pop-go

Parameters

None

Views

BGP-IPv4 unicast address family view, BGP view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
bgp write

Usage Guidelines

Usage Scenario

Received IPv4 public network unicast routes are advertised as labeled routes only when the following conditions are met:

  • Both the labeled route sender and receiver are enabled to send or receive labeled routes using the peer { group-name | ipv4-address } label-route-capability [ check-tunnel-reachable ] command.
  • A route-policy is used on the labeled route sender to allocate MPLS labels to received IPv4 public network unicast routes and applied to labeled route advertisement.
  • The labeled route sender is enabled to convert received IPv4 public network unicast routes to labeled routes and advertise the labeled routes to peers with the labeled route exchange capability using the unicast-route label advertise command or the unicast-route label advertise pop-go command. After configured the unicast-route label advertise pop-go command, if the destination of received packets is reachable through an IP route, but not through an MPLS LSP, the labeled route sender pops out the BGP label in the packets and searches the local incoming label map (ILM) for an outbound interface based on the label to send the packets to the corresponding next hop.

Example

# Enable the device to convert received IPv4 public network unicast routes to labeled routes and advertise the labeled routes to peers with the labeled route exchange capability.
<HUAWEI> system-view
[~HUAWEI] route-policy policy1 permit node 10
[*HUAWEI-route-policy] apply mpls-label
[*HUAWEI-route-policy] quit
[~HUAWEI] bgp 100
[*HUAWEI-bgp] peer 10.1.1.1 as-number 200
[*HUAWEI-bgp] peer 10.1.1.1 label-route-capability check-tunnel-reachable
[*HUAWEI-bgp] peer 10.1.1.1 route-policy policy1 export
[*HUAWEI-bgp] unicast-route label advertise
# Enable the device to convert received IPv4 public network unicast routes to labeled routes by adding a BGP label to each route and advertise the labeled routes to peers with the labeled route exchange capability.
<HUAWEI> system-view
[~HUAWEI] bgp 100
[*HUAWEI-bgp] unicast-route label advertise pop-go
[*HUAWEI-bgp] ipv4-family unicast
[*HUAWEI-bgp-af-ipv4] unicast-route label advertise pop-go
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >