---
title: Network Quality Analysis
slug: aidc/network-quality-analysis
createdAt: 2025-12-01T11:11:10.000Z
---

# <font color="#1d50a2">Mirror</font>

## <font color="#1d50a2">Mirror View</font>

<font color="#1d05a2">Table 1 Mirror View</font>

| **Command**     | **Purpose**                   |
| --------------- | ----------------------------- |
| **show mirror** | Display mirror configuration. |

### <font color="#1d50a2">show mirror</font>

**\[Command]**
**show mirror**

**\[Purpose]**
Display mirror configuration.

**\[View]**
Privileged User View

**\[Use Cases]**

```plaintext
sonic# show mirror
```

## <font color="#1d50a2">Mirror Config</font>

<font color="#1d05a2">Table 2 Mirror Config</font>

| **Command**                                              | **Purpose**                                                  |
| -------------------------------------------------------- | ------------------------------------------------------------ |
| **mirror session** *session-id* **type \{span\|erspan}** | Create a mirror session.                                     |
| **source interface ethernet** *interface\_name*          | Specify the source interface of the local mirror.            |
| **destination interface ethernet** *interface\_name*     | Specify the destination interface of the local mirror.       |
| **direction** \[**in**\|**out**\|**both**]               | Specify local mirror diretion                                |
| **origin ip address** *A.B.C.D*                          | Specify the source IP of the remote mirror tunnel.           |
| **destination ip address** *A.B.C.D*                     | Specify the destination IP of the remote mirror tunnel.      |
| **ip ttl** *ttl\_value*                                  | Specify TTL value of the remote mirror tunnel.               |
| **ip dscp** *dscp\_value*                                | Specify DSCP value of the remote mirror tunnel.              |
| **queue** *queue-id*                                     | Specify the queue that the remote mirror tunnel is bound to. |
| **gre\_type** *type*                                     | Specify the type of the remote mirror tunnel.                |

### <font color="#1d50a2">mirror session *session-id* type \{span|erspan\}</font>

**\[Command]**
**mirror session** *session-id* **type** \{**span**|**erspan**}

**\[Purpose]**
Create a mirror session.

**\[Parameters]**

| **Parameter** | **Description**                         |
| ------------- | --------------------------------------- |
| *session-id*  | Mirror session ID, the range is \[1,63] |

**\[View]**
Global Configuration View

**\[Notes]**
**Span** is the local mirror type. **Erspan** is the remote mirror type, which sends traffic to the remote side through a GRE tunnel.
Run command **no mirror session** *session-id* to delete the mirror session.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# mirror session 0 type span
sonic(config)# mirror session 1 type erspan
```

### <font color="#1d50a2">source interface ethernet *interface\_name*</font>

**\[Command]**
**source interface ethernet** *interface\_name*

**\[Purpose]**
Specify the source interface of the local mirror.

**\[Parameters]**

| **Parameter**     | **Description**         |
| ----------------- | ----------------------- |
| *interface\_name* | Interface name (eg.0/1) |

**\[View]**
SPAN Mirror Configuration View

**\[Notes]**
Run command **no source interface ethernet** *interface\_name* to delete the source interface.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# mirror session 10 type span
sonic(config-span-mirror-10)# source interface ethernet 0/56
sonic(config-span-mirror-10)# source interface ethernet 0/4
```

### <font color="#1d50a2">destination interface ethernet *interface\_name*</font>

**\[Command]**
**destination interface ethernet** *interface\_name*

**\[Purpose]**
Specify the destination interface of the local mirror.

**\[Parameters]**

| **Parameter**     | **Description**         |
| ----------------- | ----------------------- |
| *interface\_name* | Interface name (eg.0/1) |

**\[View]**
SPAN Mirror Configuration View

**\[Notes]**
Run command **no destination** to delete the destination interface.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# mirror session 10 type span
sonic(config-span-mirror-10)# no source interface ethernet 0/56
```

### <font color="#1d50a2">direction \[in|out|both\]</font>

**\[Command]**
**direction** \[**in**|**out**|**both**]

**\[Purpose]**
Specify local mirror diretion.

**\[View]**
SPAN Mirror Configuration View

**\[Notes]**
The default mirroring direction is both, i.e., both inbound and outbound directions are mirrored.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# mirror session 10 type span
sonic(config-span-mirror-10)# direction in
```

### <font color="#1d50a2">origin ip address *A.B.C.D*</font>

**\[Command]**
**origin ip address** *A.B.C.D*

**\[Purpose]**
Specify the source IP of the remote mirror tunnel.

**\[Parameters]**

| **Parameter** | **Description** |
| ------------- | --------------- |
| *A.B.C.D*     | IPv4 address    |

**\[View]**
ERSPAN Mirror Configuration View

**\[Notes]**
Run command **no origin** to delete the source IP.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# mirror session 10 type erspan
sonic(config-erspan-mirror-10)# origin ip address 10.0.0.2
```

### <font color="#1d50a2">destination ip address *A.B.C.D*</font>

**\[Command]**
**destination ip address** *A.B.C.D*

**\[Purpose]**
Specify the destination IP of the remote mirror tunnel.

**\[Parameters]**

| **Parameter** | **Description** |
| ------------- | --------------- |
| *A.B.C.D*     | IPv4 address    |

**\[View]**
ERSPAN Mirror Configuration View

**\[Notes]**
Run command **no destination** to delete the destination IP.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# mirror session 10 type erspan
sonic(config-erspan-mirror-10)# destination ip address 10.0.0.2
```

### <font color="#1d50a2">ip ttl *ttl\_value*</font>

**\[Command]**
**ip ttl** *ttl\_value*

**\[Purpose]**
Specify TTL value of the remote mirror tunnel.

**\[Parameters]**

| **Parameter** | **Description**                  |
| ------------- | -------------------------------- |
| *ttl\_value*  | TTL value, the range is \[1,255] |

**\[View]**
ERSPAN Mirror Configuration View

**\[Notes]**
Run command **no ip ttl** *ttl\_value* to delete TTL value configuration.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# mirror session 10 type erspan
sonic(config-erspan-mirror-10)# ip ttl 10
```

### <font color="#1d50a2">ip dscp *dscp\_value*</font>

**\[Command]**
**ipdscp** *dscp\_value*

**\[Purpose]**
Specify DSCP value of the remote mirror tunnel.

**\[Parameters]**

| **Parameter** | **Description**                  |
| ------------- | -------------------------------- |
| *dscp\_value* | DSCP value, the range is \[0,63] |

**\[View]**
ERSPAN Mirror Configuration View

**\[Notes]**
Run command **no ipdscp** *dscp\_value* to delete DSCP value configuration.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# mirror session 10 type erspan
sonic(config-erspan-mirror-10)# ip dscp 10
```

### <font color="#1d50a2">queue *queue-id*</font>

**\[Command]**
**queue** *queue-id*

**\[Purpose]**
Specify the queue that the remote mirror tunnel is bound to.

**\[Parameters]**

| **Parameter** | **Description**               |
| ------------- | ----------------------------- |
| *queue-id*    | Queue ID, the range is \[0,7] |

**\[View]**
ERSPAN Mirror Configuration View

**\[Notes]**
Run command **no queue** *id* to unbind the queue.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# mirror session 10 type erspan
sonic(config-erspan-mirror-10)# queue 5
```

### <font color="#1d50a2">gre\_type *type*</font>

**\[Command]**
**gre\_type** *type*

**\[Purpose]**
Specify the type of the remote mirror tunnel.

**\[Parameters]**

| **Parameter** | **Description**            |
| ------------- | -------------------------- |
| *type*        | GRE type in 0xHHHH format. |

**\[View]**
ERSPAN Mirror Configuration View

**\[Notes]**
Run command **no gre\_type** *type* to delete the type configuration.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# mirror session 10 type erspan
sonic(config-erspan-mirror-10)# gre_type 0x886e
```

# <font color="#1d50a2">Inband Network Telemetry (INT)</font>

## <font color="#1d50a2">INT View</font>

<font color="#1d05a2">Table 3 INT View</font>

| **Command**                | **Purpose**                |
| -------------------------- | -------------------------- |
| **show collector session** | Display INT configuration. |

### <font color="#1d50a2">show collector session</font>

**\[Command]**
**show collector session**

**\[Purpose]**
Display INT configuration

**\[View]**
Privileged User View

**\[Use Cases]**

```plaintext
sonic# show collector session
```

## <font color="#1d50a2">INT Config</font>

<font color="#1d05a2">Table 4 INT Config</font>

| **Command**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 | **Purpose**                      |
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------- |
| **collector parser enable**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 | Enable INT                       |
| **collector high\_delay sip** *A.B.C.D* **dip** *A.B.C.D* **cos** *cos\_value* **delay\_threshold** *delay\_value* **ports** *ports\_name* **\[ttl** *ttl\_value*\|**dscp** *dscp\_value*\|**tc** *tc\_value*\|**df** *df\_value*] **sampler\_mode** \{**probabilistic** \[**capture\_rate** *capture\_rate\_value*]\|**microburst** \[**max\_packets\_rate** *max\_rate\_value*\|**max\_packets\_per\_burst** *max\_burst\_value*]*} **collection\_mode** \{**local** \[**cpu\_queue\_rate** cpu\_rate\_value\|**cpu\_queue\_burst\_size** cpu\_size\_value]*\|**remote**} | Set a high\_delay mode capture.  |
| **collector buffer\_drop sip** *A.B.C.D* **dip** *A.B.C.D* **cos** *cos\_value* \[**ttl** *ttl\_value*\|**dscp** *dscp\_value*\|**tc** *tc\_value*\|**df** *df\_value*] **sampler\_mode** \{**all**\|**probabilistic** \[**capture\_rate** *capture\_rate\_value*]\|**microburst** \[**max\_packets\_rate** *max\_rate\_value*\|**max\_packets\_per\_burst** *max\_burst\_value*]*} collection\_mode \{**local** \[**cpu\_queue\_rate** cpu\_rate\_value\|**cpu\_queue\_burst\_size** cpu\_size\_value]*\|**remote**}                                                       | Set a buffer\_drop mode capture. |

### <font color="#1d50a2">collector parser enable</font>

**\[Command]**
**collector parser enable**

**\[Purpose]**
Enable INT

**\[View]**
Global Configuration View

**\[Notes]**
Run command **no collector parser enable** to enable INT.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# collector parser enable
```

### <font color="#1d50a2">collector high\_delay</font>

**\[Command]**
**collector high\_delay sip** *A.B.C.D* **dip** *A.B.C.D* **cos** *cos\_value* **delay\_threshold** *delay\_value* **ports ports\_name \[ttl *ttl\_value*|dscp *dscp\_value*|tc *tc\_value*|df df\_value] sampler\_mode \{probabilistic \[capture\_rate *capture\_rate\_value*]|microburst \[max\_packets\_rate *max\_rate\_value*|max\_packets\_per\_burst *max\_burst\_value*]} collection\_mode \{local \[cpu\_queue\_rate** *cpu\_rate\_value*|**cpu\_queue\_burst\_size** *cpu\_size\_value*]|**remote**}

**\[Purpose]**
Set a high\_delay mode capture.

**\[Parameters]**

| **Parameter**          | **Description**                                                                                                                                                     |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| *A.B.C.D*              | Source and destination IPv4 addresses, used to encapsulate INT packets.                                                                                             |
| *cos*                  | List of cos to monitor for BDC and HDC, can be configured with one or more, eg. 0,5-7.                                                                              |
| *delay\_value*         | High Delay Threshold in nanoseconds.                                                                                                                                |
| *ports\_name*          | Matching ports can be configured with one or more or all, e.g. 0/0,0/4, all.                                                                                        |
| *ttl\_value*           | TTL value, default is 255, range (1-255), used to encapsulate INT packets.                                                                                          |
| *dscp\_value*          | DSCP value, default to 0, range (0-63), used to encapsulate INT packets.                                                                                            |
| *tc\_value*            | INT message export queue, default to 0, range (0-7), cannot be configured as lossless queue.                                                                        |
| *df\_value*            | DF flag, default is 0, range (0-1).                                                                                                                                 |
| *capture\_rate\_value* | Capture rate (1 in every N pkts) for visibility sampler in Probabilistic Capture mode. This specifies 'N' for the rate. N defaults to 10000, range (10-16,777,215). |
| *max\_rate\_value*     | Max rate (pkts/sec) of buffer dropped packets to be captured, default is 8192, range (122-100,000).                                                                 |
| *max\_burst\_value*    | Max number of buffer dropped packets to be captured per burst in multiples of 64, default is 256, range (64-16,384).                                                |
| *cpu\_rate\_value*     | Max rate (pkts/sec) on cpu\_queue, default is 1000, range (122-60,000,000).                                                                                         |
| *cpu\_size\_value*     | Bust size for packets on cpu\_queue, default is 512, range (1-1,000,000,000).                                                                                       |

**\[View]**
Global Configuration View

**\[Notes]**
Run command **no collector high\_delay** to delete HDC.

**\[Use Cases]**

```plaintext
sonic# configure
sonic(config)# collector high_delay sip 10.250.0.141 dip 10.250.0.142 cos 0 delay_threshold 100 ports 0/0,0/4 sampler_mode microburst collection_mode local
```

### <font color="#1d50a2">collector buffer\_drop</font>

**\[Command]**
**collector buffer\_drop sip** *A.B.C.D* **dip** *A.B.C.D* **cos** *cos\_value* \[**ttl** *ttl\_value*|**dscp** *dscp\_value*|**tc** *tc\_value*|**df** *df\_value*] **sampler\_mode** \{**all|probabilistic** \[**capture\_rate** *capture\_rate\_value*]|**microburst** \[**max\_packets\_rate** *max\_rate\_value*|**max\_packets\_per\_burst** *max\_burst\_value*]} **collection\_mode** \{**local** \[**cpu\_queue\_rate** *cpu\_rate\_value*|**cpu\_queue\_burst\_size** *cpu\_size\_value*]|**remote**}

**\[Purpose]**
Set a buffer\_drop mode capture.

**\[Parameters]**

| **Parameter**          | **Description**                                                                                                                                                     |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| *A.B.C.D*              | Source and destination IPv4 addresses, used to encapsulate INT packets.                                                                                             |
| *cos*                  | List of cos to monitor for BDC and HDC, cannot be configured as lossless queue, can be configured with one or more, eg. 0,5-7.                                      |
| *ttl\_value*           | TTL value, default is 255, range (1-255), used to encapsulate INT packets.                                                                                          |
| *dscp\_value*          | DSCP value, default to 0, range (0-63), used to encapsulate INT messages.                                                                                           |
| *tc\_value*            | INT message export queue, default to 0, range (0-7), cannot be configured as lossless queue.                                                                        |
| *df\_value*            | DF flag, default is 0, range (0-1).                                                                                                                                 |
| *capture\_rate\_value* | Capture rate (1 in every N pkts) for visibility sampler in Probabilistic Capture mode. This specifies 'N' for the rate. N defaults to 10000, range (10-16,777,215). |
| *max\_rate\_value*     | Max rate (pkts/sec) of buffer dropped packets to be captured, default is 8192, range (122-100,000).                                                                 |
| *max\_burst\_value*    | Max number of buffer dropped packets to be captured per burst in multiples of 64, default is 256, range (64-16,384).                                                |
| *cpu\_rate\_value*     | Max rate (pkts/sec) on cpu\_queue, default is 1000, range (122-60,000,000).                                                                                         |
| *cpu\_size\_value*     | Bust size for packets on cpu\_queue, default to 512, range (1-1,000,000,000).                                                                                       |

**\[View]**
Global Configuration View

**\[Notes]**
Run command **no collector buffer\_drop** to delete BDC.

**\[Use Cases]**

```plaintext
sonic# configure
sonic# collector buffer_drop sip 10.250.0.141 dip 10.250.0.142 cos 0 sampler_mode microburst collection_mode local
```

# <font color="#1d50a2">sFlow</font>

## <font color="#1d50a2">sFlow View</font>

<font color="#1d05a2">Table 5 sFlow View</font>

| **Command**                                         | **Purpose**                               |
| --------------------------------------------------- | ----------------------------------------- |
| **show sflow**                                      | Display global configuration of sFlow.    |
| **show sflow interface ethernet** *interface\_name* | Display interface configuration of sFlow. |

### show sflow

**\[Command]**
**show sflow**

**\[Purpose]**
Display global configuration of sFlow.

**\[View]**
Privileged User View

**\[Use Cases]**

```plaintext
sonic# show sflow
```

### <font color="#1d50a2">show sflow interface ethernet *interface\_name*</font>

**\[Command]**
**show sflow interface ethernet** *interface\_name*

**\[Purpose]**
Display interface configuration of sFlow.

**\[Parameters]**

| **Parameter**     | **Description**         |
| ----------------- | ----------------------- |
| *interface\_name* | Interface name (eg.0/1) |

**\[View]**
Privileged User View

**\[Use Cases]**

```plaintext
sonic# show sflow interface ethernet 0/0
```

## <font color="#1d50a2">sFlow Config</font>

<font color="#1d05a2">Table 6 sFlow Config</font>

| **Command**                                                                                                                         | **Purpose**                                        |
| ----------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------- |
| **sflow enable**                                                                                                                    | Enable sFlow feature.                              |
| **sflow collector** *collector-name ip-address* \[**vrf** *vrf*\|*dst\_port*]                                                       | Set the collector for sFlow.                       |
| **sflow polling-interval** *interval*                                                                                               | Set the sampling interval for sFlow.               |
| **sflow disable**                                                                                                                   | Disable sFlow feature of the interface.            |
| **sflow sample-rate** *rate*                                                                                                        | Set the sampling frequency for interface sFlow.    |
| **sflow agent-id \{ethernet\|link-aggregation\|loopback\|mgmt\|vlan}** *interface\_name*                                            | Set the agent ID for sFlow sampling.               |
| **sflow collector** *collector-name* **source** \{*A.B.C.D*\|*A\::B*}                                                               | Configure the source IP of sFlow collector.        |
| **sflow collector** *collector-name* **source-interface** \{**ethernet\|link-aggregation\|loopback\|mgmt\|vlan**} *interface\_name* | Configure the source interface of sFlow collector. |

### <font color="#1d50a2">sflow enable</font>

**\[Command]**
**sflow enable**

**\[Purpose]**
Enable sFlow feature.

**\[View]**
Global Configuration View

**\[Notes]**
Run command **no sflow enable** to disable sFlow feature.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# sflow enable
```

### <font color="#1d50a2">sflow collector *collector-name ip-address* \[vrf *vrf*|*dst\_port*\]</font>

**\[Command]**
**sflow collector** *collector-name ip-address* \[**vrf** vrf|*dst\_port*]

**\[Purpose]**
Set the collector for sFlow.

**\[Parameters]**

| **Parameter**    | **Description**                                                              |
| ---------------- | ---------------------------------------------------------------------------- |
| *collector-name* | Name of sFlow collector, in string form (length 1-16 characters)             |
| *ip-address*     | Destination IP address.                                                      |
| *vrf*            | Specify VRF for sampling, only supports management port VRF and default VRF  |
| *dst\_port*      | Destination port number, the range is \[1,65536], the default value is 6343. |

**\[View]**
Global Configuration View

**\[Notes]**
Run command **no sflow collector** *collector-name* to delete sflow collector.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# sflow collector 1 10.0.0.3 6
sonic(config)# sflow collector 2 10.0.0.4
```

### <font color="#1d50a2">sflow polling-interval *interval*</font>

**\[Command]**
**sflow polling-interval** *interval*

**\[Purpose]**
Set the sampling interval for sFlow.

**\[Parameters]**

| **Parameter** | **Description**                                                                    |
| ------------- | ---------------------------------------------------------------------------------- |
| *interval*    | Specify the interval in seconds. The range is from 5 to 300, and the default is 1. |

**\[View]**
Global Configuration View

**\[Notes]**
Run command **no sflow polling-interval** to restore the sampling interval to default.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# sflow polling-interval 300
```

### <font color="#1d50a2">sflow disable</font>

**\[Command]**
**sflow disable**

**\[Purpose]**
Disable sFlow feature of the interface.

**\[View]**
Physical Interface Configuration View

**\[Notes]**
Run command **no sflow disable** to enable sFlow feature of the interface.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# interface ethernet 0/0
sonic(config-if-0/0)# sflow disable
```

### <font color="#1d50a2">sflow sample-rate *rate*</font>

**\[Command]**
**sflow sample-rate** *rate*

**\[Purpose]**
Configure the sampling frequency of sFlow globally or on the interface.

**\[Parameters]**

| **Parameter** | **Description**                                                         |
| ------------- | ----------------------------------------------------------------------- |
| *rate*        | Frequency value, the range is 4096-1000000, the default value is 10000. |

**\[View]**
Physical Interface Configuration View

**\[Notes]**
Run command **no sflow sample-rate** to restore the sampling frequency to default.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# sflow sample-rate 70000
sonic(config)# interface ethernet 0/0
sonic(config-if-0/0)# sflow sample-rate 50000
```

### <font color="#1d50a2">sflow agent-id \{ethernet|link-aggregation|loopback|mgmt|vlan\} *interface\_name*</font>

**\[Command]**
**sflow agent-id** \{**ethernet|link-aggregation|loopback|mgmt|vlan**} *interface\_name*

**\[Purpose]**
Configure the agent ID for sFlow sampling.

**\[Parameters]**

| **Parameter**     | **Description** |
| ----------------- | --------------- |
| *interface\_name* | Interface name. |

**\[View]**
Global Configuration View

**\[Notes]**
After specifying the agent ID, the agent IP address is the IP address of the specified interface.
Run command **no sflow sgent-id** to restore the agent ID to its default value, with the agent IP address set to 240.127.1.1 by default.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# sflow agent-id ethernet 0/10
```

### <font color="#1d50a2">sflow collector *collector-name* source \{*A.B.C.D*|*A\:\:B*\}</font>

**\[Command]**
**sflow collector** *collector-name* **source** \{*A.B.C.D*|*A\::B*}

**\[Purpose]**
Configure the source IP of sFlow collector.

**\[Parameters]**

| **Parameter**    | **Description**                                                  |
| ---------------- | ---------------------------------------------------------------- |
| *collector-name* | Name of sFlow collector, in string form (length 1-16 characters) |
| *A.B.C.D*        | IPv4 address                                                     |
| *A\::B*          | IPv6 address                                                     |

**\[View]**
Physical Interface Configuration View

**\[Notes]**
Run command **no sflow collector** *collector-name* **source** to delete the source IP of sFlow collector.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# sflow collector test 39.0.0.2
sonic(config)# sflow collector test source 100.0.0.1
```

### <font color="#1d50a2">sflow collector collector-name source-interface \{ethernet|link-aggregation|loopback|mgmt|vlan\} interface\_name</font>

**\[Command]**
**sflow collector** *collector-name* **source-interface** \{**ethernet**|**link-aggregation|loopback|mgmt|vlan**} *interface\_name*

**\[Purpose]**
Configure the source interface of sFlow collector.

**\[Parameters]**

| **Parameter**     | **Description**                                                  |
| ----------------- | ---------------------------------------------------------------- |
| *collector-name*  | Name of sFlow collector, in string form (length 1-16 characters) |
| *interface\_name* | Interface name                                                   |

**\[View]**
Physical Interface Configuration View

**\[Notes]**
Run command **no sflow collector** *collector-name* **source-interface** to delete the source interface of sFlow collector.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# sflow collector test 39.0.0.2
sonic(config)# sflow collector test source-interface ethernet 0/24
```

# <font color="#1d50a2">Telemetry</font>

## <font color="#1d50a2">Telemetry Config</font>

<font color="#1d05a2">Table 7 Telemetry Config</font>

| **Command**                                                                         | **Purpose**                                                                                      |
| ----------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------ |
| **&#x20;client**                                                                    | Create the Telemetry client and enter the Telemetry client configuration view.                   |
| **destination-group** *destination-group-name*                                      | Create the Telemetry collector group and enter the Telemetry collector group configuration view. |
| \{**ipv4-address** *A.B.C.D*\|**ipv6-address** *A\::B*} **port&#x20;***port-number* | Configure the collector's IP address and port number.                                            |
| **subscription** *subscription-name*                                                | Create a Telemetry subscription and enter the Telemetry subscription configuration view.         |
| **destination-group** *destination-group-name*                                      | Configure the collector group associated with the subscription.                                  |
| **path-target&#x20;**\[**COUNTERS\_DB**\|**&#x20;STATE\_DB**\|**OTHERS**]           | Configure collection target.                                                                     |
| **paths** *path-name*                                                               | Configure collection path.                                                                       |
| **report-interval** *time*                                                          | Configure reporting interval.                                                                    |
| **report-type&#x20;**\[**periodic**\|**stream**]                                    | Configure reporting method.                                                                      |

### <font color="#1d50a2">telemetry client</font>

**\[Command]**
**telemetry client**

**\[Purpose]**
Create the Telemetry client and enter the Telemetry client configuration view.

**\[View]**
Global Configuration View

**\[Notes]**
Run command **no telemetry client** to delete the Telemetry client configuration.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# telemetry client
sonic(telemetry-client)#
```

### <font color="#1d50a2">destination-group *destination-group-name*</font>

**\[Command]**
**destination-group** *destination-group-name*

**\[Purpose]**
Create the Telemetry collector group and enter the Telemetry collector group configuration view.

**\[Parameters]**

| **Parameter**            | **Description**      |
| ------------------------ | -------------------- |
| *destination-group-name* | Collector group name |

**\[View]**
Telemetry Client Configuration View

**\[Notes]**
Run command **no destination-group** *destination-group-name* to delete the Telemetry collector group configuration.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# telemetry client
sonic(telemetry-client)# destination-group test
```

### \{ipv4-address *A.B.C.D*|ipv6-address *A\::B*} port *port-number*

**\[Command]**
\{**ipv4-address** *A.B.C.D*|**ipv6-address** *A\::B*} **port&#x20;***port-number*

**\[Purpose]**
Configure the collector's IP address and port number.

**\[Parameters]**

| **Parameter** | **Description**                                 |
| ------------- | ----------------------------------------------- |
| *A.B.C.D*     | Collector IP                                    |
| *A\::B*       | Collector IPv6                                  |
| *port-number* | Collector Port Number, the range is \[1, 65535] |

**\[View]**
Telemetry Collector Group Configuration View

**\[Notes]**
Run command **no** \{**ipv4-address** *A.B.C.D*|**ipv6-address** *A\::B*} **port&#x20;***port-number* to delete the Telemetry collector configuration.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# telemetry client
sonic(telemetry-client)# destination-group test
sonic(telemetry-destination-group-test)# ipv4-address 192.168.20.102 port 8081
```

### <font color="#1d50a2">subscription *subscription-name*</font>

**\[Command]**
**subscription** *subscription-name*

**\[Purpose]**
Create a Telemetry subscription and enter the Telemetry subscription configuration view.

**\[Parameters]**

| **Parameter**       | **Description**   |
| ------------------- | ----------------- |
| *subscription-name* | Subscription name |

**\[View]**
Telemetry Client Configuration View

**\[Notes]**
Run command **no subscription** *subscription-name* to delete the Telemetry subscription configuration.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# telemetry client
sonic(telemetry-client)# subscription test
```

### <font color="#1d50a2">destination-group *destination-group-name*</font>

**\[Command]**
**destination-group** *destination-group-name*

**\[Purpose]**
Configure the collector group associated with the subscription.

**\[Parameters]**

| **Parameter**            | **Description**      |
| ------------------------ | -------------------- |
| *destination-group-name* | Collector group name |

**\[View]**
Telemetry Subscription Configuration View

**\[Notes]**
Run command **no destination-group** *destination-group-name* to delete the collector group associated with the subscription configuration.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# telemetry client
sonic(telemetry-client)# subscription test
sonic(telemetry-subscription-test)# destination-group test
```

### <font color="#1d50a2">path-target \[COUNTERS\_DB|STATE\_DB|OTHERS\]</font>

**\[Command]**
**path-target \[COUNTERS\_DB|STATE\_DB|OTHERS]**
**\[Purpose]**
Configure collection target.

**\[View]**
Telemetry Subscription Configuration View

**\[Notes]**
Run command **no path-target** to delete the  collection target configuration.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# telemetry client
sonic(telemetry-client)# subscription test
sonic(telemetry-subscription-test)# path-target OTHERS
```

### <font color="#1d50a2">paths *path-name*</font>

**\[Command]**
**paths** *path-name*

**\[Purpose]**
Configure collection path.

**\[Parameters]**

| **Parameter** | **Description**                                                                  |
| ------------- | -------------------------------------------------------------------------------- |
| *path-name*   | Collection path, subfolders are separated by ‘/’, multiple settings are allowed. |

**\[View]**
Telemetry Subscription Configuration View

**\[Notes]**
Run command **no paths** *path-name* to delete the collection path configuration.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# telemetry client
sonic(telemetry-client)# subscription test
sonic(telemetry-subscription-test)# paths platform/cpu
```

### <font color="#1d50a2">report-interval *time*</font>

**\[Command]**
**report-interval** *time*

**\[Purpose]**
Configure reporting interval.

**\[Parameters]**

| **Parameter** | **Description**                                                                                              |
| ------------- | ------------------------------------------------------------------------------------------------------------ |
| *time*        | Interval, the unit is milliseconds, the range is \[100, 1800000], with a default value of 5000 milliseconds. |

**\[View]**
Telemetry Subscription Configuration View

**\[Notes]**
Run command **no report-interval** to delete the reporting interval configuration.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# telemetry client
sonic(telemetry-client)# subscription test
sonic(telemetry-subscription-test)# report-interval 10000
```

### <font color="#1d50a2">report-type \[periodic|stream\]</font>

**\[Command]**
**report-type** \[**periodic**|**stream**]

**\[Purpose]**
Configure reporting method.

**\[View]**
Telemetry Subscription Configuration View

**\[Notes]**
Run command **no report-type** to delete the reporting method configuration.

**\[Use Cases]**

```plaintext
sonic# configure terminal
sonic(config)# telemetry client
sonic(telemetry-client)# subscription test
sonic(telemetry-subscription-test)# report-type periodic
```

