Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat(eos_cli_config_gen): Add support for Postcard telemetry #3642

Merged
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
2b93bb6
Feat(eos_cli_config_gen): Add support for Postcard telemetry
laxmikantchintakindi Feb 20, 2024
58a209a
Feat(eos_cli_config_gen): Add support for Postcard telemetry
laxmikantchintakindi Feb 20, 2024
f1a5d56
Feat(eos_cli_config_gen): Add support for Postcard telemetry
laxmikantchintakindi Feb 21, 2024
345d233
Fixing data model and template
laxmikantchintakindi Feb 21, 2024
09110f5
Adding support to include port name in match rules
laxmikantchintakindi Feb 21, 2024
0b2e7f6
[pre-commit.ci lite] apply automatic fixes
pre-commit-ci-lite[bot] Feb 21, 2024
7b453e7
Multiple sample policies and match rules can be created
laxmikantchintakindi Feb 22, 2024
6d5334f
Fixing pre-commit
Shivani-gslab Feb 22, 2024
d8c35ec
Modified test data and few descriptions in schema
laxmikantchintakindi Feb 22, 2024
def7f99
Added punctuations to descriptions
laxmikantchintakindi Feb 28, 2024
0dd1c76
Made some changes in Schema and template
laxmikantchintakindi Mar 1, 2024
ced7e97
Changing template file after editing EOL
laxmikantchintakindi Mar 1, 2024
40d40ea
Changing template file after removing one line EOF
laxmikantchintakindi Mar 1, 2024
5aa9032
Again changing template file after editing EOL
laxmikantchintakindi Mar 1, 2024
71ccd57
[pre-commit.ci lite] apply automatic fixes
pre-commit-ci-lite[bot] Mar 1, 2024
bd32c3f
Added template file based on unix
laxmikantchintakindi Mar 1, 2024
c81b5f3
Added template file based on unix
laxmikantchintakindi Mar 1, 2024
8adb05d
Fix schema and template.
laxmikantchintakindi Apr 22, 2024
0df054a
Corrected schemas to support for multiple source/destination ports c…
laxmikantchintakindi Apr 22, 2024
0c815cf
Merge branch 'devel' into postcardtelemetry
laxmikantchintakindi Apr 23, 2024
26f6da5
Fixed CI failure.
laxmikantchintakindi Apr 23, 2024
f4b043d
Adding range to tcp-udp-checksum.
laxmikantchintakindi Apr 29, 2024
36ea338
Added document template and marker command.
laxmikantchintakindi May 7, 2024
13021ff
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] May 7, 2024
a589237
Fixing CI issues.
laxmikantchintakindi May 7, 2024
6b3468c
Address comments.
laxmikantchintakindi May 7, 2024
caaae2c
Fixing template.
laxmikantchintakindi May 7, 2024
e8549d2
Merge branch 'devel' into postcardtelemetry
laxmikantchintakindi May 7, 2024
9b68d1f
Merge branch 'devel' into postcardtelemetry
laxmikantchintakindi May 8, 2024
b294146
Address multiple comments.
laxmikantchintakindi May 8, 2024
9160898
Merge branch 'devel' into postcardtelemetry
laxmikantchintakindi May 8, 2024
3e51d70
Adding new changes in eos template.
laxmikantchintakindi May 9, 2024
490e0f4
Update ansible_collections/arista/avd/roles/eos_cli_config_gen/schema…
laxmikantchintakindi May 9, 2024
7df10a5
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] May 9, 2024
3831b36
Fixing order of prefix commands.
laxmikantchintakindi May 9, 2024
86ef12a
Removing extra empty line characters.
laxmikantchintakindi May 10, 2024
be1ab2e
Fix logic for empty line character.
laxmikantchintakindi May 10, 2024
cfb8e22
Fixing the template
Shivani-gslab May 10, 2024
a176ff6
Making disabled key defaulttrue.
laxmikantchintakindi May 10, 2024
c17fff7
Merge branch 'devel' into HEAD
Shivani-gslab May 14, 2024
2b02bc2
Fixing EOS template.
laxmikantchintakindi May 14, 2024
0741f6f
Update ansible_collections/arista/avd/roles/eos_cli_config_gen/templa…
Vibhu-gslab May 14, 2024
440b15c
Fixed marker configuration.
May 17, 2024
ee33f26
Fixing schemas and eos template for source and destination ports.
May 22, 2024
cf39994
Minor change in schema.
May 22, 2024
6812a4a
Minor correctiong in schema.
May 22, 2024
47be37a
Correction in schema.
May 22, 2024
736fe0f
Enhacing eos template.
May 22, 2024
606b46f
Fixing eos template for marker config.
May 24, 2024
822c219
Merge branch 'devel' into postcardtelemetry
ClausHolbechArista May 29, 2024
d5e4027
Fixing CI issue.
May 29, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# monitor-telemetry-postcard
ClausHolbechArista marked this conversation as resolved.
Show resolved Hide resolved

## Table of Contents

- [Management](#management)
- [Management Interfaces](#management-interfaces)

## Management

### Management Interfaces

#### Management Interfaces Summary

##### IPv4

| Management Interface | Description | Type | VRF | IP Address | Gateway |
| -------------------- | ----------- | ---- | --- | ---------- | ------- |
| Management1 | oob_management | oob | MGMT | 10.73.255.122/24 | 10.73.255.2 |

##### IPv6

| Management Interface | Description | Type | VRF | IPv6 Address | IPv6 Gateway |
| -------------------- | ----------- | ---- | --- | ------------ | ------------ |
| Management1 | oob_management | oob | MGMT | - | - |

#### Management Interfaces Device Configuration

```eos
!
interface Management1
description oob_management
vrf MGMT
ip address 10.73.255.122/24
```
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
!RANCID-CONTENT-TYPE: arista
!
transceiver qsfp default-mode 4x10G
!
hostname monitor-telemetry-postcard
!
no enable password
no aaa root
!
interface Management1
description oob_management
vrf MGMT
ip address 10.73.255.122/24
!
monitor telemetry postcard policy
no disabled
ingress collection gre source 10.3.3.3 destination 10.3.3.4 version 2
ingress sample rate 16384
ingress sample tcp-udp-checksum 2343223
profile profile1
ingress sample policy ingresspo1
profile profile2
ingress sample policy ingresspo1
sample policy samplepo1
match rule rule1 ipv4
destination prefix 10.3.3.0/24
source prefix 3.4.5.0/24
protocol tcp destination port www
protocol tcp destination port 78-80
protocol tcp destination port 77
match rule rule2 ipv6
destination prefix 10.3.4.0/24
source prefix 3.4.4.0/24
protocol udp destination port ssh
protocol udp destination port 748-800
protocol udp destination port 747
sample policy samplepo2
match rule rule1 ipv4
destination prefix 10.3.3.0/24
source prefix 3.4.5.0/24
protocol udp source port www
protocol udp source port 78-80
protocol udp source port 77
sample policy samplepo3
match ipv4-all-default ipv4
!
match ipv6-all-default ipv6
!
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
monitor_telemetry_postcard:
disabled: false
ingress:
collection:
source: 10.3.3.3
destination: 10.3.3.4
version: 2
sample:
rate: 16384
tcp_udp_checksum: 2343223
profiles:
- name: profile1
ingress_sample_policy: ingresspo1
- name: profile2
ingress_sample_policy: ingresspo1
sample_policies:
- name: samplepo1
match_rules:
- rule_name: rule1
type: ipv4
destination_prefix: 10.3.3.0/24
source_prefix: 3.4.5.0/24
protocol_type: tcp
destination_port:
- '77'
- 78-80
- www
- rule_name: rule2
type: ipv6
destination_prefix: 10.3.4.0/24
source_prefix: 3.4.4.0/24
protocol_type: udp
destination_port:
- '747'
- 748-800
- ssh
- name: samplepo2
match_rules:
- rule_name: rule1
type: ipv4
destination_prefix: 10.3.3.0/24
source_prefix: 3.4.5.0/24
protocol_type: udp
source_port:
- '77'
- 78-80
- www
- name: samplepo3
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ mlag-configuration
monitor-layer1
monitor-connectivity
monitor-sessions
monitor-telemetry-postcard
mpls
none_configuration
ntp
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
<!--
~ Copyright (c) 2024 Arista Networks, Inc.
~ Use of this source code is governed by the Apache License 2.0
~ that can be found in the LICENSE file.
-->
=== "Table"

| Variable | Type | Required | Default | Value Restrictions | Description |
| -------- | ---- | -------- | ------- | ------------------ | ----------- |
| [<samp>monitor_telemetry_postcard</samp>](## "monitor_telemetry_postcard") | Dictionary | | | | |
| [<samp>&nbsp;&nbsp;disabled</samp>](## "monitor_telemetry_postcard.disabled") | Boolean | | | | Enable or disable the postcard telemetry feature. |
| [<samp>&nbsp;&nbsp;ingress</samp>](## "monitor_telemetry_postcard.ingress") | Dictionary | | | | |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;collection</samp>](## "monitor_telemetry_postcard.ingress.collection") | Dictionary | | | | Collector configuration. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;source</samp>](## "monitor_telemetry_postcard.ingress.collection.source") | String | | | | Configure source IP address of GRE tunnel. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;destination</samp>](## "monitor_telemetry_postcard.ingress.collection.destination") | String | | | | Configure destination IP address of GRE tunnel. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;version</samp>](## "monitor_telemetry_postcard.ingress.collection.version") | Integer | | | Valid Values:<br>- <code>1</code><br>- <code>2</code> | Postcard version |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;sample</samp>](## "monitor_telemetry_postcard.ingress.sample") | Dictionary | | | | Configure sampling parameters. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;rate</samp>](## "monitor_telemetry_postcard.ingress.sample.rate") | Integer | | | Valid Values:<br>- <code>16384</code><br>- <code>32768</code><br>- <code>65536</code> | Configure sampling rate. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;tcp_udp_checksum</samp>](## "monitor_telemetry_postcard.ingress.sample.tcp_udp_checksum") | Integer | | | | Configure TCP/UDP checksum or IP ID checksum. |
| [<samp>&nbsp;&nbsp;profiles</samp>](## "monitor_telemetry_postcard.profiles") | List, items: Dictionary | | | | Configure the postcard telemetry profile. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;name</samp>](## "monitor_telemetry_postcard.profiles.[].name") | String | Required, Unique | | | Profile name |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;ingress_sample_policy</samp>](## "monitor_telemetry_postcard.profiles.[].ingress_sample_policy") | String | | | | Configure ingress sample policy for the profile. |
| [<samp>&nbsp;&nbsp;sample_policies</samp>](## "monitor_telemetry_postcard.sample_policies") | List, items: Dictionary | | | | Configure sample policies. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;name</samp>](## "monitor_telemetry_postcard.sample_policies.[].name") | String | Required, Unique | | | Configure sample policy name. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;match_rules</samp>](## "monitor_telemetry_postcard.sample_policies.[].match_rules") | List, items: Dictionary | | | | Configure rules for sample policy. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&nbsp;rule_name</samp>](## "monitor_telemetry_postcard.sample_policies.[].match_rules.[].rule_name") | String | Required, Unique | | | |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;type</samp>](## "monitor_telemetry_postcard.sample_policies.[].match_rules.[].type") | String | | | Valid Values:<br>- <code>ipv4</code><br>- <code>ipv6</code> | Select the IP address version. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;destination_prefix</samp>](## "monitor_telemetry_postcard.sample_policies.[].match_rules.[].destination_prefix") | String | | | | IPv4 Network/Mask or IPv6 Network/Mask. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;source_prefix</samp>](## "monitor_telemetry_postcard.sample_policies.[].match_rules.[].source_prefix") | String | | | | IPv4 Network/Mask or IPv6 Network/Mask. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;protocol_type</samp>](## "monitor_telemetry_postcard.sample_policies.[].match_rules.[].protocol_type") | String | | | Valid Values:<br>- <code>tcp</code><br>- <code>udp</code> | Select TCP/UDP. |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;destination_port</samp>](## "monitor_telemetry_postcard.sample_policies.[].match_rules.[].destination_port") | List | | | | Enter the port name or range or port numbers in a list.<br>Example:<br> ["12","14-20", "www"] |
| [<samp>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;source_port</samp>](## "monitor_telemetry_postcard.sample_policies.[].match_rules.[].source_port") | List | | | | Enter the port name or range or port numbers in a list.<br>Example:<br> ["12","14-20", "www"] |

=== "YAML"

```yaml
monitor_telemetry_postcard:

# Enable or disable the postcard telemetry feature.
disabled: <bool>
ingress:

# Collector configuration.
collection:

# Configure source IP address of GRE tunnel.
source: <str>

# Configure destination IP address of GRE tunnel.
destination: <str>

# Postcard version
version: <int; 1 | 2>

# Configure sampling parameters.
sample:

# Configure sampling rate.
rate: <int; 16384 | 32768 | 65536>

# Configure TCP/UDP checksum or IP ID checksum.
tcp_udp_checksum: <int>

# Configure the postcard telemetry profile.
profiles:

# Profile name
- name: <str; required; unique>

# Configure ingress sample policy for the profile.
ingress_sample_policy: <str>

# Configure sample policies.
sample_policies:

# Configure sample policy name.
- name: <str; required; unique>

# Configure rules for sample policy.
match_rules:
- rule_name: <str; required; unique>

# Select the IP address version.
type: <str; "ipv4" | "ipv6">

# IPv4 Network/Mask or IPv6 Network/Mask.
destination_prefix: <str>

# IPv4 Network/Mask or IPv6 Network/Mask.
source_prefix: <str>

# Select TCP/UDP.
protocol_type: <str; "tcp" | "udp">

# Enter the port name or range or port numbers in a list.
# Example:
# ["12","14-20", "www"]
destination_port: <list>

# Enter the port name or range or port numbers in a list.
# Example:
# ["12","14-20", "www"]
source_port: <list>
```
Loading
Loading