Configuring LDP Labels

Configuring Session Protection Parameters

Configuring Session Protection Parameters
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "mplsldpLDP": {
          "attributes": {
            "adminSt": "enabled"
          },
          "children": [
            {
              "mplsldpSessProt": {
                "attributes": {
                  "duration": "0",
                  "infinite": "no",
                  "pfxList": ""
}}}]}}]}}
{
    imdata:[]
}
<System>
  <ldp-items>
    <adminSt>enabled</adminSt>
    <sessprot-items>
      <duration>0</duration>
      <infinite>false</infinite>
      <pfxList></pfxList>
    </sessprot-items>
  </ldp-items>
</System>

Note: This example was added in Release 9.3(3).


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

mpls ldp configuration
  session protection


Verifying a DME Configuration

The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
mplsldpLDP sys/ldp
mplsldpSessProt sys/ldp/sessprot


mplsldpLDP Properties

The following table contains information about the mplsldpLDP properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
adminStnw:AdminSt
(scalar:Enum8)
The administrative state of the object or policy.SELECTION:
1 - enabled
2 - disabled
DEFAULT: enabled


mplsldpSessProt Properties

The following table contains information about the mplsldpSessProt properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
durationmplsldp:ProtectDuration
(scalar:Uint32)
The duration keyword enables you to specify how long the router should retain the LDP targeted hello adjacency following the loss of the LDP link hello adjacency. The range is from 30 to 2,147,483 seconds.
RANGE: [0 , 2147483]
infinitescalar:Bool
The infinite keyword allows the LDP targeted hello adjacency to exist indefinitely following the loss of the LDP link hello adjacency.SELECTION: true or false
DEFAULT: false
pfxListmplsldp:LdpPrefixListName
(string:Basic)
Prefix list for LDP peers that should be protected. Session protection is then enabled for the peer routers in that prefix listA sequence of characters


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html

Deleting Session Protection Parameters

Deleting Session Protection Parameters
POST http://<mgmt0_IP>/api/mo/sys.json
{
  "topSystem": {
    "children": [
      {
        "mplsldpLDP": {
          "attributes": {
            "adminSt": "enabled"
          },
          "children": [
            {
              "mplsldpSessProt": {
                "attributes": {
                  "status": "deleted"
}}}]}}]}}
{
    imdata:[]
}
<System>
  <ldp-items>
    <adminSt>enabled</adminSt>
    <sessprot-items nc:operation="delete">
    </sessprot-items>
  </ldp-items>
</System>

Note: This example was added in Release 9.3(3).


CLI Commands

The CLI commands are equivalent to the payload examples displayed in the pane on the right. Click the DME tab in the top-left corner of the right pane to view the JSON payload. Click the YANG tab to view the XML payload.

mpls ldp configuration
  no session protection


Verifying a DME Configuration

The following table contains the distinguished name (DN) for each managed object (MO) in the DME payload. Issue a GET request using the DN to verify the configuration was posted or to get information about the configured properties of a particular object.

MODN
topSystem sys
mplsldpLDP sys/ldp
mplsldpSessProt sys/ldp/sessprot


mplsldpLDP Properties

The following table contains information about the mplsldpLDP properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
adminStnw:AdminSt
(scalar:Enum8)
The administrative state of the object or policy.SELECTION:
1 - enabled
2 - disabled
DEFAULT: enabled


mplsldpSessProt Properties

The following table contains information about the mplsldpSessProt properties in the DME payload. For more information about the properties and MOs, see the NX-API DME Model Reference linked in the Related Documentation section below.

Property NameData TypeDescriptionValues
statusmo:ModificationStatus
(scalar:Bitmask32)
The upgrade status. This property is for internal use only.SELECTION:
2 - created
4 - modified
8 - deleted
16 - replaced


Related Documentation

For other CLI options, see the Cisco Nexus 9000 Series NX-OS Command Reference:

http://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-command-reference-list.html

See the NX-API DME Model Reference for detailed information about classes and attributes described in the payload:

https://developer.cisco.com/site/nx-os/docs/nexus-model-reference/

For information about using the payloads, see the Cisco Nexus 9000 Series NX-OS Programmability Guide:

https://www.cisco.com/c/en/us/support/switches/nexus-9000-series-switches/products-programming-reference-guides-list.html