netstream mpls-aware

Function

The ip netstream mpls-aware command configures the sampling mode for IPv4 Multiprotocol Label Switching (MPLS) packets.

The undo ip netstream mpls-aware command restores the default sampling mode for IPv4 MPLS packets.

The ipv6 netstream mpls-aware command configures the sampling mode for IPv6 Multiprotocol Label Switching (MPLS) packets.

The undo ipv6 netstream mpls-aware command restores the default sampling mode for IPv6 MPLS packets.

By default, only inner IP packets in MPLS packets are sampled.

Format

ip netstream mpls-aware { label-only | ip-only | label-and-ip }

ipv6 netstream mpls-aware { label-only | ip-only | label-and-ip }

undo ip netstream mpls-aware

undo ipv6 netstream mpls-aware

Parameters

Parameter Description Value
label-only

Samples only MPLS labels, not inner IP packets.

-

ip-only

Samples only inner IP packets, not MPLS labels.

-

label-and-ip

Samples both inner IP packets and MPLS labels.

-

ipv6

Displays the IPv6 netstream feature.

-

ip

Displays the IPv4 netstream feature.

-

Views

System view

Default Level

3: Management level

Task Name and Operations

Task Name Operations
netstream write

Usage Guidelines

Usage Scenario

On an MPLS network, MPLS labels carry important information that users are concerned about. The device supports the sampling of the three outer MPLS labels. If this command is not configured, only inner IP packets carried in the MPLS packets are sampled.

Precautions

When the sampling mode of MPLS packets is set to ip-only, you cannot configure the MPLS-label aggregation mode.

For flexible flows, this command takes effect only when the aggregation keywords of the flexible flow statistics template configured using the match command contain mpls top-label ip-address and mpls label.

If the sampling mode is set to label-only, IP packets are not collected.

Example

# Configure NetStream to sample IPv6 MPLS labels, not inner IP packets, of MPLS packets.
<HUAWEI> system-view
[~HUAWEI] ipv6 netstream mpls-aware label-only
# Configure NetStream to sample IPv4 MPLS labels, not inner IP packets, of MPLS packets.
<HUAWEI> system-view
[~HUAWEI] ip netstream mpls-aware label-only
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >