Configuring LDP inbound FEC filtering

Configure LDP inbound-FEC filtering to filter inbound label bindings on a MPLS router.

To enable LDP inbound FEC filtering,
  1. In privileged EXEC mode, enter global configuration mode.
    device# configure terminal
  2. Configure the prefix list to be referenced by the LDP inbound-FEC filter.
    device(config)# ip prefix-list list-abc permit 10.20.20.0/24
    In this example, the list-abc prefix list allows the 10.20.20.0/24 route address.
  3. Enable MPLS on the device.
    device(config)# router mpls
  4. Access LDP configuration mode.
    device(config-router-mpls)# ldp
  5. Configure the LDP inbound FEC filter.
    device(config-router-mpls-ldp)# filter-fec-in list-abc

    In this example, LDP accepts inbound FEC 10.20.20.0/24 through the list-abc prefix list and filter out all others FECs.

    Note

    Note

    When the prefix list referenced by the LDP inbound-FEC filter is configured or changed, all the existing in-bound FECs and received later are subject to the changed prefix list. There is a configurable delay between changing the prefix list and the changed prefix list taking effect on LDP FEC-filter configuration.
  6. Verify the inbound FEC-filter configuration.
    device(config-router-mpls-ldp)# do show running-config router mpls ldp
    router mpls
     ldp
      ....
      filter-fec-in list-abc
     !
    !

Example

The following example shows the previous steps to configure the LDP inbound-FEC filter.

device# configure terminal
device(config)# ip prefix-list list-abc permit 10.20.20.0/24
device(config)# router mpls
device(config-router-mpls)# ldp
device(config-router-mpls-ldp)# filter-fec-in list-abc