Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

header-navigation
keyboard_arrow_up
list Table of Contents
file_download PDF
{ "lLangCode": "en", "lName": "English", "lCountryCode": "us", "transcode": "en_US" }
English
keyboard_arrow_right

APM CLI Operational Commands

date_range 03-Oct-23

This topic provides an overview of show commands, including syntax, option descriptions, and sample output. Use these commands in APM.

request apm activate

Syntax

content_copy zoom_out_map
request apm activate entity ip-address pool-domain name pool pool-name

Description

Trigger APM to activate the specified pool by deleting the active drain on the pool. You can issue this command when the pool is in either of the following reclamation states:

  • drain—The command removes the active drain before the BNG has configured the drain on the pool.

  • drain-set—The command removes the active drain when the pool is being drained.

Use the show apm reclaim-events command on APM to check the pool’s reclamation state.

Note:

This command works only when the pool is in the draining or drain-set state as a result of manual reclamation. APM blocks the command when the reclamation state is the result of automatic reclamation.

Options

entity ip-address

Specify the IP address of the managed BNG that received the instruction.

pool-domain name

Specify the name of the pool domain that contains the targeted pool.

pool pool-name

Specify the name of the pool where the drain will be removed.

Required Privilege Level

root

Sample Output

request apm activate entity (Specific Pool)

content_copy zoom_out_map
root@jnpr-apm-mgmt> request apm activate entity 10.4.4.108 pool-domain vs009afd pool jnpr-ipb-vs009afd-004

Pool jnpr-ipb-vs009afd-004 in pool domain vs009afd at entity 10.4.4.108 has activated.

Release Information

Statement introduced in APM Release 3.0.0.

request apm drain

Syntax

content_copy zoom_out_map
request apm drain entity ip-address pool-domain name pool pool-name

Description

Trigger APM to instruct the specified BNG to drain the specified pool in the pool domain. When the drain is in place on the pool, it cannot allocate any addresses. You can request a drain when the pool has the reclaim status. If there is no drain placed on the pool, the BNG can still allocate addresses.

Use the show apm alarms command to display the alarm status. Use the show apm reclaim-events command to check the reclamation state; A drain and drain-setoutput indicate that a drain has been requested or placed on the pool.

Options

entity ip-address

Specify the IP address of the managed BNG that receives the instruction.

pool-domain name

Specify the name of the pool domain that contains the targeted pool.

pool pool-name

Specify the name of the pool to drain.

Required Privilege Level

root

Sample Output

request apm drain

content_copy zoom_out_map
root@jnpr-apm-mgmt> request apm drain entity 10.4.4.108 pool-domain vs009afd pool jnpr-ipb-vs009afd-004

Pool jnpr-ipb-vs009afd-004 in pool domain vs009afd at entity 10.4.4.108 has been set to drain.

Release Information

Statement introduced in APM Release 3.0.0.

request apm reclaim

Syntax

content_copy zoom_out_map
request apm reclaim entity ip-address pool-domain name pool pool-name

Description

Trigger APM to instruct the specified BNG to deprovision the specified pool in the pool domain. When the pool is deprovisioned, APM returns the addresses that had been assigned to the pool to the source partition for reallocation. The pool must be idle, meaning that it has no addresses in use. The command fails if any addresses are still in use.

Note:

This command works only when the pool is in the drain-set reclamation state as a result of manual reclamation. APM blocks the command when the pool state is the result of automatic reclamation.

Options

entity ip-address

Specify the IP address of the managed BNG that receives the instruction.

pool-domain name

Specify the name of the pool domain that contains the targeted pool.

pool pool-name

Specify the name of the drained pool from which addresses are recovered.

Required Privilege Level

root

Sample Output

request apm reclaim (Specific Pool)

content_copy zoom_out_map
root@jnpr-apm-mgmt> request apm reclaim entity 10.4.4.108 pool-domain vs009afd pool jnpr-ipb-vs009afd-004
Pool jnpr-ipb-vs009afd-004 in pool-domain vs009afd at entity 10.4.4.108 has been reclaimed.

Release Information

Statement introduced in APM Release 3.0.0.

request apm release entity

Syntax

content_copy zoom_out_map
request apm release entity system-id   

Description

Trigger APM to clean up any pool domains established by the entity, and release an entity’s domains and their associated pool prefixes back to each domain’s source partition. If the access network isn't using an entity's APM-allocated prefixes, APM forces the cleanup of any domains and deallocates the associated pool prefixes in each domain's source partition. This command works only if the entity is unreachable or disconnected. A list of prefixes that were released and the associated target partition displays upon success.

Note:

Releasing the prefixes makes them available to other entities whose address pools are managed by APM and use the same partition. If you're not careful to ensure that the entity’s prefixes are no longer in use, reallocation to another entity could cause duplicate addresses, routing loops, and so on.

Options

entity system-id

Specify the system-id of the entity. The system-id is a unique string of up to 45 characters assigned to the managed BNG. It identifies the entity to APM upon successful connection.

Required Privilege Level

root

Sample Output

request apm drain

content_copy zoom_out_map
root@jnpr-apm-mgmt> request apm release entity test-002

Released Prefix Destination Partition
192.168.0.0/24  westford
192.168.1.0/24  westford
192.168.2.0/24  westford
192.168.3.0/24  westford
192.168.4.0/24  westford

Release Information

Statement introduced in APM Release 3.1.0.

show apm alarms

Syntax

content_copy zoom_out_map
show apm alarms
<entity ip-address>
<pool-domain name>

Description

Display all pending pool domain alarms. You can display alarms across all managed routers, or you can limit the display to a specific BNG router or pool domain.

Options

entity ip-address

(Optional) Display the alarms for the specified router.

pool-domain name

(Optional) Display the alarms in the specified pool domain.

Required Privilege Level

root

Output Fields

Table 1 lists the output fields for the show apm alarms command. Output fields are listed in alphabetical order.

Table 1: show apm alarms Output Fields

Field Name

Field Description

Entity

IP address of the managed BNG.

Pool Domain

Name of the pool domain with the critical pool.

Alarm

Name of the alarm.

  • reclaim—When the number of free addresses for the pool domain on the BNG rises above the reclaim threshold, the BNG sends a reclaim alarm message with the name of the pool to APM. APM can then initiated an active drain for the pool domain.
  • apportion—When the number of free addresses falls below the apportion threshold, the BNG sends an apportion alarm. APM responds by apportioning prefixes to be added to a pool domain.
  • pool-drained—When a pool is completely drained, the BNG sends a pool-drained alarm letting APM know that the prefix allocated for the pool can be recovered.

Info

Name of the apportioned pool.

Age

How long an alarm has been outstanding.

Sample Output

show apm alarms

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm alarms 
Entity        Pool Domain    Alarm                  Info                   Age                
10.4.4.108    vks009-default reclaim                vks009-default-0005    2:33:15            
10.2.1.1      alpha-drop     reclaim                alpha-Drop-0000        3 days, 15:20:01   
10.3.23.10    feeder-default apportion              -                      0:0:10
152.13.5.5    azimuth-ri2    pool-drained           azimuth-ri2-0007       0:0:21

Release Information

Statement introduced in APM Release 3.0.0.

show apm entity

Syntax

content_copy zoom_out_map
show apm entity
<id system-id>
<address ip-address>
<pool-domain name>

Description

Monitor APMs associations with managed BNGs. You can specify a particular router or pool domain to view additional details.

Options

id system-id

Specify the system-id of the entity. The system-id is a unique string of up to 45 characters assigned to the managed BNG. It identifies the entity to APM upon successful connection.

address ip-address

Specify the IP address of the managed BNG to display information for only that BNG.

pool-domain name

Specify the name of a pool domain to display information for only that domain.

Required Privilege Level

root

Output Fields

Table 2 lists the output fields for the show apm entity command, in alphabetical order.

Table 2: show apm entity Output Fields

Field Name

Field Description

Allocations

Number of allocations that APM has made to the pool domain.

Entity Id

Unique system id assigned to the entity.

APMi Version

APM version that the managed BNG uses to communicate.

Entity Address

IP address of the managed BNG.

Entity Statistics

Details about the managed router.

  • IP Address—IP address of the managed BNG.

  • Name—Name of the managed BNG.

  • Status—Status of the connection to the BNG: up or down.

Pool

Name of a pool in the domain. An asterisk (*) next to the name indicates that an active drain has been configured for the pool.

Pool Domain Statistics

Details about the pool domain:

  • Free addresses—Number of addresses in the pool domain that are available for allocation.

  • Last Allocation—Timestamp when the last address allocation operation completed.

  • Last Discovery—Timestamp when the last discovery operation completed.

  • Last Reclamation—Timestamp when the last pool reclamation occurred.

  • Pool Domain—Name of pool domain on the managed router.

  • Pool head—Name of the domain’s pool head.

  • Pools—Number of pools in the pool domain.

  • Reclamations—Number of pools in the domain that have been deprovisioned and their addresses recovered to the source partition for future use.

  • Allocations—Number of prefixes (pools) that have been added to this pool domain.

  • Source Partition— The partition from which prefixes have been allocated for this pool domain.

  • Apportion Alarms—Number of apportion alarms sent for this pool domain.

  • Reclamation Alarms—Number of reclamation alarms sent for this pool domain.

  • Pool-drained Alarms—Number of pool-drained alarms sent for this pool domain.

Pool Domains

Number of pool domains on the managed BNG.

Prefix

Subnetwork allocated to an address pool. APM creates this prefix by subdividing the source partition’s root prefix.

Status

Displays whether the entity is reachable or unreachable.

Used

Number of used addresses in the pool. The pool is idle when the value is zero.

Sample Output

show apm entity (All BNGs)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm entity

root@jnpr-apm-mgmt> show apm entity
Entity ID                      APMi Ver  Name         Status    Pool Domains
test-002                       1                     reachable 1         
10.9.164.40                     0         yarmouth    reachable 1 

show apm entity (Specific BNG)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm entity id test-002
   
Entity Statistics
  ID      :  test-002
  APMi Ver:  1
  Name    :  test-002
  Status  :  reachable
  Pool Domain                Last Discovery         Pools       Last Allocation       Allocations   Last Reclamation      Reclamations
  iroh-default               2022-03-29T22:11:55Z   1           2022-03-29T22:11:55Z  1             -                     0
          –                   0

show apm entity (Pool Domain)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm entity id test-002 pool-domain iroh-default
Entity Statistics:
  Entity ID:  test-002
  APMi Ver :  1
  Name     :  test-002
  Status   :  reachable
  Pool Domain Statistics:
    Pool Domain     :  iroh-default
    Source Partition:  westford
    Free Addresses  :  245
    Pool Head       :  iroh-default
    Pools           :  1
    Thresholds:
  	Apportion  :  200
  	Reclamation:  457
    Events:
  	Last Discovery  :  2022-03-28T13:05:27Z
  	Last Allocation :  2022-03-28T13:05:27Z
  	Last Reclamation:  -
  	Allocations     :  1
  	Reclamations    :  0
    Alarms:
  	Apportion   :  1
  	Reclamation :  0
  	Pool-drained:  0
  	Abatement   :  0
    Pool                           Prefix              Total Addrs    Used Addrs
    iroh-default                   192.168.41.0/24     255            10   

Release Information

Statement introduced in APM Release 3.0.0.

<id system-id> option introduced in 3.1.0

show apm inet-pool allocation

Syntax

content_copy zoom_out_map
show apm inet-pool allocation
<entity ip-address>
<partition name>

Description

Display information about how prefixes are allocated across all partitions, for a specific partition, for a specific entity, or for a specific partition on a specific entity.

Options

entity ip-address

Specify the IP address of the managed BNG to display information for only that BNG.

partition name

Specify the name of a partition to display information for only that partition. The partition might be used for multiple BNGs.

Required Privilege Level

root

Output Fields

Table 3 lists the output fields for the show apm inet-pool allocation command. Output fields are listed in alphabetical order.

Table 3: show apm inet-pool allocation Fields

Field Name

Field Description

Allocations

Number of allocations that APM has made from a partition.

Entity Address

IP address of the managed BNG.

Filter fields

Filters applied to the output before it is displayed. The filters correspond to the qualifiers you specify when you issue the command, such as a partition name or entity IP address.

Partition

Name of a partition from which APM allocates addresses to a pool domain.

Pool Domain

Name of a pool domain provisioned from the partition.

Prefix

Subnetwork allocated to an address pool. This prefix is split off from a partition’s root prefix by APM. A given pool can have multiple allocated prefixes.

Source Partition

Name of a partition from which APM allocates addresses to a pool domain.

Sample Output

show apm inet-pool allocation (All Partitions)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm inet-pool allocation

Partition           Allocations 
new-england         4
wholesalers         2
vpn                 7

show apm inet-pool allocation (Specific Partition)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm inet-pool allocation partition wholesalers

Filter fields:     partition=wholesalers, entity=
Source Partition      Prefix                Entity Address    Pool Domain
wholesalers           198.51.100.100/20     192.0.2.108        cust-a970
wholesalers           198.51.100.200/20     192.0.2.108        cust-a970
wholesalers           198.51.100.1/20       192.0.2.233        L3-001a    

show apm inet-pool allocation (Specific BNG)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm inet-pool allocation entity 192.0.2.108

Filter fields:     partition=, entity=192.0.2.108
Source Partition      Prefix                Entity Address    Pool Domain
new-england           203.0.113.10/24       192.0.2.108        mx480-a3-default 
new-england           203.0.113.20/24       192.0.2.108        mx480-a3-default 
new-england           203.0.113.30/24       192.0.2.108        mx480-a3-default 
new-england           203.0.113.40/24       192.0.2.108        mx480-a3-default 
new-england           203.0.113.50/24       192.0.2.108        mx480-a3-red 
new-england           203.0.113.60/24       192.0.2.108        mx480-a3-red 
wholesalers           198.51.100.100/20     192.0.2.108        cust-a970
wholesalers           198.51.100.200/20     192.0.2.108        cust-a970
vpn                   192.0.2.0/25          192.0.2.108        local56    

show apm inet-pool allocation (Specific Partition and BNG)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm inet-pool allocation entity 192.0.2.108 partition new-england

Filtered Partition Allocations
Filter fields:     partition=new-england, entity=192.0.2.108
Source Partition      Prefix                Entity Address    Pool Domain
new-england           203.0.113.10/24       192.0.2.108        mx480-a3-default 
new-england           203.0.113.20/24       192.0.2.108        mx480-a3-default 
new-england           203.0.113.30/24       192.0.2.108        mx480-a3-default 
new-england           203.0.113.40/24       192.0.2.108        mx480-a3-default 
new-england           203.0.113.50/24       192.0.2.108        mx480-a3-red 
new-england           203.0.113.60/24       192.0.2.108        mx480-a3-red 

Release Information

Statement introduced in APM Release 3.0.0.

show apm inet-pool utilization

Syntax

content_copy zoom_out_map
show apm inet-pool utilization
<partition name>
<prefix address/prefix length>

Description

Display information about how prefixes are being used. You can display utilization for all partitions, for a specific partition, or for a specific prefix and partition.

Options

partition name

Specify the name of a partition to display address utilization for only that partition.

prefix address/prefix-length

Specify a root (source) prefix and partition name to display address utilization for only that combination.

Required Privilege Level

root

Output Fields

Table 4 lists the output fields for the show apm inet-pool utilization command. Output fields are listed in alphabetical order.

Table 4: show apm inet-pool utilization Fields

Field Name

Field Description

Allocated

Number of prefixes that are currently allocated from a partition or from a partition’s root prefix. It is possible for a prefix to be both reserved and allocated.

Partition Name

Name of a partition from which APM allocates addresses to a pool domain.

Prefix

Route (source) prefix of a partition. Listed statistics are shown for all prefixes in a partition or for only that specific prefix in a specific partition.

Prefixes

Total number of prefixes available for allocation from a partition or from a partition’s root prefix.

Reserved

Number of prefixes that are held in reserve from a partition or from a specific root prefix in a partition.

State

The threshold state of the partition. The threshold is set by the free-prefix-utilization statement at the [edit apm inet-pool partition partition-name] hierarchy level. A partition can have one of the following threshold states:

  • empty
  • above-threshold
  • below-threshold

Prefix Statistics

The following statistics are displayed for a specified partition and root prefix combination:

  • Prefix—Route (source) prefix of a partition for which statistics are displayed.

  • Total sub-prefixes—Total number of subnetworks possible for the partition’s root prefix.

  • Total reserved—Total number of prefixes that are currently reserved for all subnetworks of the root prefix.

  • Total allocated—Total number of prefixes that are currently allocated for all subnetworks of the root prefix.

  • Prefix length—Length of a prefix subdivided from the partition’s root prefix.

  • Free—Number of prefixes that are currently unallocated or free for subnetworks of the root prefix, indicated by the prefix length.

  • Allocated—Number of prefixes that are currently allocated for subnetworks of the root prefix, indicated by the prefix length.

Sample Output

show apm inet-pool utilization (All Partitions)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm inet-pool utilization
Partition           State            Prefixes    Reserved    Allocated
new-england         above-threshold  3           0           0
wholesalers         above-threshold  511         0           2

show apm inet-pool utilization (Specific Partition)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm inet-pool utilization partition new-england

Partition Statistics
    Partition Name:  new-england
    State:           above-threshold
    Prefixes:        7
    Reserved:        0
    Allocated:       4
    Prefix           Prefixes    Reserved    Allocated
    203.0.113.0/24   7           0           4

show apm inet-pool utilization (Specific Prefix and Partition)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm inet-pool utilization partition new-england prefix 203.0.113.0/16
Partition Statistics:
    Partition Name:  new-england
    State:           above-threshold
    Prefixes:        7
    Reserved:        0
    Allocated:       4
    Prefix Statistics:
        Prefix:             203.0.113.0/24
        Total sub-prefixes: 7
        Total reserved:     0
        Total allocated:    4
        Prefix Length    Free        Allocated
        24               0           1          
        25               1           1          
        26               2           2         

Release Information

Statement introduced in APM Release 3.0.0.

show apm reclaim-events

Syntax

content_copy zoom_out_map
show apm reclaim-events
<entity ip-address>
<pool-domain name>

Description

Display information about active pool reclamation events for all BNGs, for a specific BNG, or for a specific BNG and pool domain.

Options

entity ip-address

Specify the IP address of the managed BNG to display information for pools in only that BNG.

pool-domain name

Specify the name of a pool domain to display information for pools in only that domain.

Required Privilege Level

root

Output Fields

Table 5 lists the output fields for the show apm reclaim-events command. Output fields are listed in alphabetical order.

Table 5: show apm reclaim-events Fields

Field Name

Field Description

Entity

IP address of a managed BNG.

Pool Domain

Name of a pool domain.

Pool

Name of a pool in the pool domain.

State

Current reclamation state of the pool:

  • draining—APM has sent instructions to the BNG to configure an active drain on the pool. The pool is not yet draining. This is a transient state. When the draining operation completes, the state transitions to drain-set.

  • drain-set—The BNG has configured a drain on this pool in response to instructions from APM. The pool cannot allocate any addresses. This means that the pool is idle.

  • pending—The pool is in the process of being deprovisioned (removed from the BNG) by APM. This is a transient state. If this operation fails, the state transitions back to drain-set.

    Deprovisioning and address recovery follow this sequence:

    1. BNG notifies the provisioning manager when the last address in use in the pool is freed.

    2. APM sends deprovisioning instructions to the router.

    3. When the router finishes deprovisioning the pool, the pool entry disappears from show command output.

    4. APM puts the drained addresses back in the associated partition for future allocation.

Sample Output

show apm reclaim-events (Specific Entity)

content_copy zoom_out_map
root@jnpr-apm-mgmt> show apm reclaim-events entity 10.4.4.108

Entity        Pool Domain    Pool                     State      
10.4.4.108    vks009afd      jnpr-ipb-vs009afd-0003   draining   
10.4.4.108    uk001bnf       jnpr-ipb-uk001bnf-0001   pending

Release Information

Statement introduced in APM Release 3.0.0.

footer-navigation