- Table of Contents
- Related Documents
-
Title | Size | Download |
---|---|---|
03-Telemetry stream commands | 69.49 KB |
Telemetry stream commands
display telemetry stream
Use display telemetry stream to display telemetry stream configuration and deployment state.
Syntax
display telemetry stream [ slot slot-number ]
Views
Any view
Predefined user roles
network-admin
network-operator
Parameters
slot slot-number: Specifies an IRF member device by its member ID. If you do not specify a member device, this command displays entries for the master device.
Examples
# Display telemetry stream configuration and deployment state.
[Sysname] display telemetry stream
Telemetry stream status : Enabled
Telemetry stream timestamp status: Disabled
Telemetry stream device ID : 10.0.0.3
Telemetry stream action:
Twenty-FiveGigE1/0/1:
Telemetry stream action 1:
ACL : user-defined abc
Sampler: samp
Telemetry stream action 2:
ACL : user-defined abcd
Sampler: samp
Telemetry stream collector: (Configuration succeeded)
Source IP : 20.0.0.2
Destination IP : 30.0.0.1
Source port : 12
Destination port: 14
VPN instance : abc
Destination MAC : 0CDA-411D-9F4C
VLAN ID : 20
Output Interface: Twenty-FiveGigE1/0/1
Truncation : Enable
Field |
Description |
Telemetry stream status |
Telemetry stream status: · Enabled. · Disabled. |
Telemetry stream timestamp status |
Telemetry stream timestamp status: Enabled. Disabled. |
Telemetry stream action |
Telemetry stream action: · Inactive indicates that the action is not issued because telemetry stream is disabled. · Failed indicates that the action fails to be issued. |
Telemetry stream collector: (Configuration succeeded) |
Whether the telemetry stream collector command configuration was successfully deployed to the driver, and the addressing parameters for telemetry stream packets. · Configuration succeeded—The configuration was successfully deployed. · Configuration failed—The configuration failed to be deployed. A possible reason is that the chip resources are insufficient. · Destination MAC. This field is displayed only if telemetry stream timestamping is disabled. · VLAN ID. This field is displayed only if telemetry stream timestamping is disabled. · Output Interface—Output interface name. This field is displayed only if telemetry stream timestamping is disabled. · Truncation—This field is displayed only if the truncation function is enabled. |
telemetry stream action
Use telemetry stream action to configure a telemetry stream action.
Use undo telemetry stream action to delete a telemetry stream action.
Syntax
telemetry stream action action-id [ acl [ mac | user-defined ] { acl-number | name acl-name } | sampler sampler-name ] *
undo telemetry stream action action-id
Default
No telemetry stream action is configured.
Views
Layer 2 Ethernet interface view
Layer 3 Ethernet interface view
Predefined user roles
network-admin
Parameters
action-id: Specifies an action ID in the range of 1 to 32.
acl: Specifies an ACL.
· mac: Specifies the Layer 2 ACL type.
· user-defined: Specifies the user-defined ACL type.
· acl-number: Specifies the ACL number. The following are available value ranges:
¡ 2000 to 2999 for basic ACLs.
¡ 3000 to 3999 for advanced ACLs.
¡ 4000 to 4999 for Layer 2 ACLs.
¡ 5000 to 5999 for user-defined ACLs.
· name acl-name: Specifies the ACL name, a case-insensitive string of 1 to 63 characters.
sampler sampler-name: Specifies a sampler by its name, a case-insensitive string of 1 to 31 characters. If you do not specify a sampler, all matching packets are mirrored.
Usage guidelines
When receiving a packet on an interface configured with a telemetry stream action, the device copies the packet, encapsulates the copied packet with the configured addressing parameters, and sends it to the collector.
Specifying an ACL limits telemetry stream to the traffic that matches the ACL. To specify an IPv4 ACL, do not specify the mac or user-defined keyword. To specify a Layer 2 or user-defined ACL, you must specify the mac or user-defined keyword before specifying the ACL number or name.
Specifying a sampler reduces the number of packets copied and sent to the collector, but provides less granular monitoring.
When specifying an ACL, follow these restrictions and guidelines:
· If the specified ACL does not exist or does not have any rules, no traffic will match the ACL, and no packets will be copied.
· In the specified ACL, a rule with the vpn-instance keyword specified takes effect only on VPN packets, and a rule without the vpn-instance keyword specified takes effect on both packets in the public network and VPN packets.
If you configure multiple telemetry stream actions on an interface, you can only specify the same sampler for all of them.
Examples
# Configure telemetry stream action 1 on Twenty-FiveGigE 1/0/1 to use sampler samp.
<Sysname> system-view
[Sysname] interface twenty-fivegige 1/0/1
[Sysname-Twenty-FiveGigE1/0/1] telemetry stream 1 sampler samp
telemetry stream collector
Use telemetry stream collector to configure the addressing parameters to encapsulate in telemetry stream packets sent to the collector.
Use undo telemetry stream collector to restore the default.
Syntax
telemetry stream collector source source-address destination destination-address source-port source-port destination-port destination-port [ vpn-instance vpn-instance-name ] [ truncation ]
undo telemetry stream collector
Default
No addressing parameters are configured for telemetry stream packets.
Views
System view
Predefined user roles
network-admin
Parameters
source source-address: Specifies the source IP address for telemetry stream packets.
destination destination-address: Specifies the destination IP address for telemetry stream packets.
source-port source-port: Specifies the source port number for telemetry stream packets.
destination-port destination-port: Specifies the destination port number for telemetry stream packets.
vpn-instance vpn-instance-name: Specifies a VPN instance by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a VPN instance, the device forwards the telemetry stream packets to the collector according to the routing table of the public network.
truncation: Enables the truncation function. If you do not specify this keyword, the truncation function is disabled.
Usage guidelines
The device uses the addressing parameters to route the telemetry stream packets to the collector.
The destination IP address must be the IP address of the collector, and the destination port number must be the listening port number on the collector.
The vpn-instance vpn-instance-name option of this command is mutually exclusive with the telemetry stream timestamp enable command.
The truncation function can save the link bandwidth consumed between the device and the collector and reduce the parsing load of the collector. With the truncation function, the device will encapsulate the packet carrying collected data, truncates a portion from the tail of the packet, and send it to the collector. The truncated packets retain complete input interface, timestamp, and output interface,information.
Examples
# Specify source IP address 10.10.10.10, destination IP address 20.20.20.20, source port number 10, and destination port number 20 for telemetry stream packets.
<Sysname> system-view
[Sysname] telemetry stream collector source 10.10.10.10 destination 20.20.20.20 source-port 10 destination-port 20
Related commands
telemetry stream timestamp enable
telemetry stream device-id
Use telemetry stream device-id to specify a device ID.
Use undo telemetry stream device-id to restore the default.
Syntax
telemetry stream device-id address
undo telemetry stream device-id
Default
No device ID is specified.
Views
System view
Predefined user roles
network-admin
Parameters
address: Specifies an IPv4 address as the device ID. You can specify any IPv4 address other than 0.0.0.0. The specified IP address is encapsulated in a copied packet for the collector to identify the source of the packet.
Usage guidelines
This command takes effect only if telemetry stream timestamp is enabled.
Examples
# Specify IPv4 address 10.10.10.10 as the device ID.
<Sysname> system-view
[Sysname] telemetry stream device-id 10.10.10.10
telemetry stream enable
Use telemetry stream enable to enable telemetry stream.
Use undo telemetry stream enable to disable telemetry stream.
Syntax
telemetry stream enable
undo telemetry stream enable
Default
Telemetry stream is enabled.
Views
System view
Predefined user roles
network-admin
Examples
# Enable telemetry stream.
<Sysname> system-view
[Sysname] telemetry stream enable
telemetry stream timestamp enable
Use telemetry stream timestamp enable to enable telemetry stream timestamp.
Use undo telemetry stream timestamp enable to disable telemetry stream timestamp.
Syntax
telemetry stream timestamp enable
undo telemetry stream timestamp enable
Default
Telemetry stream timestamp is disabled.
Views
System view
Predefined user roles
network-admin
Usage guidelines
This command enables the device to add to a copied packet the timestamps that the original packet enters and leaves the device.
This command is mutually exclusive with the vpn-instance vpn-instance-name option in the telemetry stream collector command.
This command takes effect only after you create a service loopback group and assign a Layer 2 Ethernet interface to the group. For more information about service loopback groups, see Layer 2—LAN Switching Configuration Guide.
Examples
# Enable telemetry stream timestamp.
<Sysname> system-view
[Sysname] telemetry stream timestamp enable
Related commands
service-loopback group (Layer 2—LAN Switching Command Reference)
telemetry stream collector