sflow flow-sampling rate

Function

The sflow flow-sampling rate command configures a flow sampling rate on an interface.

The undo sflow flow-sampling rate command restores the default flow sampling rate on an interface.

By default, the sampling rate is 8192.

Format

sflow flow-sampling rate rate { inbound | outbound }

undo sflow flow-sampling rate rate { inbound | outbound }

Parameters

Parameter Description Value
rate rate

Specifies a sampling rate in the format of 1/rate. rate specifies the number of packets out of which the interface will sample a packet.

The value is an integer ranging from 1 to 65535.

inbound

Specifies to get inbound direction sampling packet.

-

outbound

Specifies to get inbound direction sampling packet.

-

Views

100GE interface view, 25GE interface view, 400GE interface view, 40GE interface view, 50GE interface view, GE interface view, GE electrical interface view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
sflow write

Usage Guidelines

Usage Scenario

To configure a flow sampling rate on an interface, run the sflow flow-sampling rate command. Setting a large sampling rate reduces the system's load but distorts the sampled data more than when a small sampling rate is set.

Precautions

sFlow cannot be configured on a channelized sub-interface with network slicing configured.

Example

# Set a flow sampling rate to 1/1000.
<HUAWEI> system-view
[*HUAWEI] sflow
[~HUAWEI-sflow] sflow collector 1
[~HUAWEI-sflow-collector-1] quit
[~HUAWEI-sflow] quit
[~HUAWEI] interface GigabitEthernet0/1/1
[*HUAWEI-GigabitEthernet0/1/1] sflow flow-sampling collector 1 inbound
[*HUAWEI-GigabitEthernet0/1/1] sflow flow-sampling rate 1000 inbound
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >