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
close
keyboard_arrow_left
Junos Telemetry Interface User Guide
Table of Contents Expand all
list Table of Contents
file_download PDF
{ "lLangCode": "en", "lName": "English", "lCountryCode": "us", "transcode": "en_US" }
English
keyboard_arrow_right

Configuring a Junos Telemetry Interface Sensor (CLI Procedure)

date_range 28-Nov-24

Junos telemetry interface provides for the highly scalable streaming of telemetry information. Unlike previous monitoring systems, such as SNMP, which use the so-called pull model, the Junos telemetry interface uses the push model to collect data. The push model overcomes earlier scaling limits and reduces the processing required by the management station. You can enable monitoring and streaming of data for various system resources, such as physical and logical interfaces and firewall filters. To monitor a specific system resource, you configure a sensor. Each sensor configuration requires three main components:

  • Sensor profile—Enables the system resource to monitor and allows you to set related parameters, such as the destination server to send data.

  • Export profile—Specifies the attributes for the process of exporting collected data, such as the transport protocol to use and the interval at which to collect data.

  • Streaming server profile—Specifies the server for collecting data and related parameters, including the destination IP address and port number.

Note:

Junos telemetry interface was introduced in Junos OS Release 15.1F3 on MX Series routers with interfaces configured on MPC1 through MPC6E and on PTX Series routers with interfaces configured on FPC3. Starting in Junos OS Release 15.1F5, Junos telemetry interface is also supported on MPC7E, MPC8E, and MPC9E on MX Series routers.

Starting with Junos OS Release 16.1R3, FPC1 and FPC2 on PTX Series routers are also supported.

Starting with Junos OS Release 17.2R1, QFX10000 and PTX1000 switches are also supported.

Starting with Junos OS Release 17.3R1, EX9200 switches, and the Routing and Control Board (RCB) on PTX3000 routers are also supported.

Starting with Junos OS Release 17.4R1, virtual MX Series (vMX) routers are supported. All sensors are supported except for those for fabric statistics and high queue-scale statistics.

Starting with Junos OS Release 19.1R1, MX Series routers operating with MS-MIC and MS-MPC, QFX10002 switches, and PTX10002 routers are also supported.

Best Practice:

We recommend that you configure at least one export profile and at least one streaming server before you configure a sensor profile. This way you can associate an export profile and a streaming server with the sensor profile configuration.

Before you begin:

  • Configure a connection from your Juniper Networks device to a server that is using in-band management interfaces.

Configuring an Export Profile

An export profile defines the parameters of the export process of data generated through the Junos telemetry interface. You must configure at least one export profile, but you can configure multiple export profiles. Each export profile can be associated with multiple sensor profiles. However, you can associate only one export profile with a specific sensor profile.

Note:

Starting with Junos OS Release 17.3R1 on MX Series routers only, you can specify a packet loss priority for an export profile. As a result, you can apply the appropriate packet loss priority to each sensor. Loss priority settings help determine which packets are dropped from the network during periods of congestion. Previously, you could specify only the forwarding class and the DSCP value in an export profile. The following packet loss priority settings are supported: high, low, medium-high and medium-low. For more information about packet loss priority settings, see Mapping PLP to RED Drop Profiles.

To configure an export profile:

  1. Specify a name for the export profile.
    content_copy zoom_out_map
    [edit services analytics]
    user@host# set export-profile name]
    

    For example, to specify an export-profile name of export-params:

    content_copy zoom_out_map
    [edit services analytics]
    user@host# set export-profile export-params
    
  2. Specify the source IP address of exported packets.
    content_copy zoom_out_map
    [edit services analytics export-profile name]
    user@host# set local-address ip-address
    

    For example, to specify a source IP address of 192.0.2.3 for an export profile with the name export-params:

    content_copy zoom_out_map
    [edit services analytics export-profile export-params]
    user@host# set local-address 192.0.2.3
    
  3. Specify the source port number of exported packets.
    content_copy zoom_out_map
    [edit services analytics export-profile name]
    user@host# set local-port number
    

    For example, to specify a source port number of 21111 for an export profile with the name export-params:

    content_copy zoom_out_map
    [edit services analytics export-profile export-params]
    user@host# set local-port 21111
    
  4. Specify the interval, in seconds, at which the sensor generates telemetry data.
    content_copy zoom_out_map
    [edit services analytics export-profile name]
    user@host# set reporting-rate seconds
    

    For example, to specify an interval of 20 seconds at which any sensor associated with the export-profile with the name export-params generates telemetry data :

    content_copy zoom_out_map
    [edit services analytics sensor export-profile export-params]
    user@host# set reporting-rate 20
    
  5. Specify the format to define the structure of the exported data.
    Note:

    The only currently supported format is Google protocol buffers (gpb)

    content_copy zoom_out_map
    [edit services analytics export-profile name]
    user@host# set format gpb
    

    For example, to specify the Google protocol buffers format for exported data for an export-profile with the name export-params:

    content_copy zoom_out_map
    [edit services analytics export-profile export-params]
    user@host# set format gpb
    
  6. Specify the transport protocol to carry the telemetry data in the IP packets.
    content_copy zoom_out_map
    [edit services analytics export-profile name]
    user@host# set transport protocol-name
    

    For example, to specify the UDP as the transport protocol for telemetry data for an export profile with the name export-params:

    content_copy zoom_out_map
    [edit services analytics export-profile export-params]
    user@host# set transport udp
    
  7. (Optional) Specify the DiffServ code point (DSCP) value to assign to exported packets.
    Note:

    The default value is 0 (zero).

    Any interface-level DSCP rewrite rules you have configured override the DSCP value you specify for the export profile. You need to specify a DSCP value for the export profile only if you do not configure DSCP rewrite rules on the outgoing interface. For more information, see Configuring Rewrite Rules.

    content_copy zoom_out_map
    [edit services analytics export-profile name]
    user@host# set dscp value
    

    For example, to specify a DSCP value of 20 for an export profile with the name export-params:

    content_copy zoom_out_map
    [edit services analytics export-profile export-params]
    user@host# set dscp 20
    
  8. (Optional) Specify a forwarding class to assign to exported packets.
    Note:

    You can specify a forwarding class only for packets exported by Packet Forwarding Engine sensors. The default value is best-effort.

    content_copy zoom_out_map
    [edit services analytics export-profile name]
    user@host# set forwarding-class class-name
    

    For example, to specify a forwarding class of assured-forwarding for an export-profile with the name export-params:

    content_copy zoom_out_map
    [edit services analytics export-profile export-params]
    user@host# set forwarding-class assured forwarding
    
  9. (Optional) (MX Series routers only on Junos OS Release 17.3R1 or later) Specify a packet loss priority to assign to exported packets.
    content_copy zoom_out_map
    [edit services analytics export-profile name]
    user@host# set loss-priority (low | high | medium-low | medium-high)
    

    For example, to specify a loss priority of high for an export profile with the name export-params:

    content_copy zoom_out_map
    [edit services analytics export-profile export-params]
    user@host# set loss-priority high
    

Configuring a Streaming Server Profile

A server profile defines the parameters of the server that collects exported telemetry data. You can define more than one server profile. You can also associate the same server profile with more than one sensor profile. Starting in Junos OS Release 15.1F6, you can associate more than one server with a specific sensor.

To define the profile of a streaming server to collect exported telemetry data:

  1. Specify the name of the streaming sever.
    content_copy zoom_out_map
    [edit services analytics]
    user@host# set streaming-server server-name
    

    For example, to specify a streaming-server name of telemetry server:

    content_copy zoom_out_map
    [edit services analytics]
    user@host# set streaming-server telemetry-server
    
  2. Specify a destination IP address for the exported packets.
    content_copy zoom_out_map
    [edit services analytics streaming-server server-name]
    user@host# set remote-address ip-address
    

    For example, to specify a destination address of 192.0.2.2 for a streaming server with the name telemetry-server:

    content_copy zoom_out_map
    [edit services analytics streaming-server telemetry-server]
    user@host# set remote-address 192.0.2.2
    
  3. Specify a destination port number for the exported packets.
    content_copy zoom_out_map
    [edit services analytics streaming-server server-name]
    user@host# set remote-port number
    

    For example, to specify a destination port number of 30000 for a streaming server with the name telemetry-server:

    content_copy zoom_out_map
    [edit services analytics streaming-server telemetry-server]
    user@host# set remote-port 30000
    

Configuring a Sensor Profile

A sensor profile defines the parameters of the system resource to monitor and stream data. You can enable only one system resource to monitor for each sensor profile. Configure a different sensor profile for each system resource you want to monitor. You can, however, configure more than one sensor to monitor the same system resource. For example, you might want to configure different parameters for exporting data for the same system resource.

To configure a sensor profile:

  1. Specify the name of the sensor.
    content_copy zoom_out_map
    [edit services analytics]
    user@host# set sensor sensor-name
    

    For example, to specify a sensor name of interface-1:

    content_copy zoom_out_map
    [edit services analytics]
    user@host# set sensor interface-1
    
  2. Specify the system resource to monitor and stream data.
    content_copy zoom_out_map
    [edit services analytics sensor sensor-name]
    user@host# set resource resource-string-identifier
    

    For example, to enable monitoring of logical interfaces for sensor interface-1:

    content_copy zoom_out_map
    [edit services analytics sensor interface-1]
    user@host# set resource /junos/system/linecard/interface/logical/usage/
    
    Note:

    You must enter the resource string exactly.

  3. (Optional) Specify a regular expression to filter data for the system resource you specified in Step 2. If you do not specify a regular expression, the system resource is monitored globally, that is, systemwide.
    content_copy zoom_out_map
    [edit services analytics sensor sensor-name]
    user@host# set resource-filter regular-expression
    

    For example, to filter data only for Ethernet logical interfaces for sensor interface-1:

    content_copy zoom_out_map
    [edit services analytics sensor interface-1]
    user@host# set resource-filter et-*
    
  4. Specify the name of a export profile configured at the [edit export-profile profile-name] hierarchy level to associate with the sensor profile. This export profile defines the parameters for exporting telemetry data.
    content_copy zoom_out_map
    [edit services analytics sensor sensor-name]
    user@host# set export-name export-profile-name
    

    For example, to associate an export profile named export-params with a sensor named interface-1:

    content_copy zoom_out_map
    [edit services analytics sensor interface-1]
    user@host# set export-name export-params
    
  5. Specify the name of a streaming server name configured at the [edit services analytics streaming-server server-name] hierarchy level to collect exported data.
    Note:

    Starting in Junos OS Release 15.1F6, you can specify more than one streaming server for a sensor profile. To specify more than one streaming server for a sensor, you must enclose the names in brackets.

    content_copy zoom_out_map
    [edit services analytics sensor sensor-name]
    user@host# set streaming-server server-name
    

    For example, to associate a streaming server name telemetry-server with a sensor named interface-1:

    content_copy zoom_out_map
    [edt services analytics sensor interface-1]
    user@host# set streaming-server telemetry-server
    

Verifying Junos Telemetry Interface Sensor Configuration

Purpose

Confirm your configuration.

Action

From configuration mode, confirm your configuration by entering the show services analytics command. If your output does not display the intended configuration, repeat the instructions in this configuration procedure to correct the configuration.

content_copy zoom_out_map
user@host# show services analytics
streaming-server telemetry-server {
    remote-address 192.0.2.2;
    remote-port 30000;
}
export-profile export-params {
    local-address 192.0.2.3;
    local-port 21111;
    dscp 20;
    forwarding-class assured-forwarding;
    loss-priority high;
    reporting-rate 20;
    format gpb;
    transport udp;
}
sensor interface-1 {
    server-name telemetry-server;
    export-name export-params;
    resource /junos/system/linecard/interface/logical/usage/;
    resource-filter et-*;
}

After you commit the configuration, verify that the sensor is enabled by issuing the show agent sensors operational command.

content_copy zoom_out_map
user@host> show agent sensors
Sensor Information :

   Name                                    : interface-1
   Resource                                : /junos/system/linecard/interface/logical/usage/
   Version                                 : 1.0
   Sensor-id                               : 193570469
   Resource-filter                         : et-*

   Server Information :

       Name                                : telemetry-server
       Scope-id                            : 0
       Remote-Address                      : 192.0.2.2
       Remote-port                         : 30000

   Profile Information :

       Name                                : export-params
       Rep-interval                        : 20
       Address                             : 192.0.2.3
       Port                                : 21111
       Timestamp                           : 1
       Format                              : GPB
       Transport                           : UDP
       DSCP                                : 20
       Forwarding-class                    : assured-forwarding
       Loss-priority                       : high 
Note:

The show agent sensors command output for gRPC sensors is truncated on the Junos OS Evolved platform to align with the output format of the Junos OS platform.

Change History Table

Feature support is determined by the platform and release you are using. Use Feature Explorer to determine if a feature is supported on your platform.

Release
Description
19.1R1
Starting with Junos OS Release 19.1R1, MX Series routers operating with MS-MIC and MS-MPC, QFX10002 switches, and PTX10002 routers are also supported.
17.4R1
Starting with Junos OS Release 17.4R1, virtual MX Series (vMX) routers are supported.
17.3R1
Starting with Junos OS Release 17.3R1, EX9200 switches, and the Routing and Control Board (RCB) on PTX3000 routers are also supported.
17.3R1
Starting with Junos OS Release 17.3R1 on MX Series routers only, you can specify a packet loss priority for an export profile.
17.2R1
Starting with Junos OS Release 17.2R1, QFX10000 and PTX1000 switches are also supported.
16.1R3
Starting with Junos OS Release 16.1R3, FPC1 and FPC2 on PTX Series routers are also supported.
15.1F5
Starting in Junos OS Release 15.1F5, Junos telemetry interface is also supported on MPC7E, MPC8E, and MPC9E on MX Series routers.
15.1F3
Junos telemetry interface was introduced in Junos OS Release 15.1F3 on MX Series routers with interfaces configured on MPC1 through MPC6E and on PTX Series routers with interfaces configured on FPC3.
footer-navigation