R3303-HP HSR6800 Routers MPLS Command Reference

2
Related commands
ip ip-prefix (Layer 3—IP Routing Command Reference)
advertise-label
Use advertise-label to configure a label advertisement policy.
Use undo advertise-label to restore the default.
Syntax
advertise-label ip-prefix ip-prefix-name [ peer peer-ip-prefix-name ]
undo advertise-label ip-prefix ip-prefix-name
Default
An LSR does not filter label bindings to be advertised.
Views
MPLS LDP view, MPLS LDP VPN instance view
Default command level
2: System level
Parameters
ip-prefix ip-prefix-name: Specifies an IP prefix list to be used for filtering the label bindings to be
advertised. The ip-prefix-name argument is the name of the IP prefix list, a string of 1 to 19 characters.
peer peer-ip-prefix-name: Specifies a list of LDP peers. The peer-ip-prefix-name argument is the IP prefix
list name, a string of 1 to 19 characters. If you do not specify the LDP peer list, the label advertisement
policy is for all LDP peers.
Usage guidelines
When advertising label bindings to peers, an LSR follows these rules:
If the IP prefix of a label binding to be advertised fails the IP prefix checking, the LSR does not
advertise the label binding to any peer.
If the IP prefix of a label binding to be advertised passes the IP prefix checking and the peer list is
not specified, the LSR will advertise the label binding to all peers.
If the IP prefix of a label binding to be advertised passes the IP prefix checking and a peer list is
specified, the LSR will advertise the label binding to the peers that pass the peer list checking.
If the IP prefix of a label binding to be advertised passes the checking of more than one IP prefix lists
(which are specified by executing the advertise-label command for multiple times), the LSR will
advertise the label binding based on the configuration by the first advertise-label command.
Examples
# Configure label advertisement control policies so that the device:
Advertises label bindings for FEC 10.1.1.0/24 to the LDP peer with the LSR ID 3.3.3.9
Advertises label bindings for FEC 10.2.1.0/24 to the LDP peer with the LSR ID 4.4.4.9.
Does not advertise label bindings of other subnets to any peers.
<Sysname> system-view
[Sysname] ip ip-prefix prefix-to-C permit 10.1.1.0 24
[Sysname] ip ip-prefix prefix-to-D permit 10.2.1.0 24