ajout partie parseurs_logs_switch
This commit is contained in:
82
Parseurs_logs_Switch/src/modèles/ietf-snmp@2014-12-10.yang
Normal file
82
Parseurs_logs_Switch/src/modèles/ietf-snmp@2014-12-10.yang
Normal file
@@ -0,0 +1,82 @@
|
||||
module ietf-snmp {
|
||||
|
||||
namespace "urn:ietf:params:xml:ns:yang:ietf-snmp";
|
||||
prefix snmp;
|
||||
|
||||
include ietf-snmp-common {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
include ietf-snmp-engine {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
include ietf-snmp-target {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
include ietf-snmp-notification {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
include ietf-snmp-proxy {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
include ietf-snmp-community {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
include ietf-snmp-usm {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
include ietf-snmp-tsm {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
include ietf-snmp-vacm {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
include ietf-snmp-tls {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
include ietf-snmp-ssh {
|
||||
revision-date 2014-12-10;
|
||||
}
|
||||
|
||||
organization
|
||||
"IETF NETMOD (NETCONF Data Modeling Language) Working Group";
|
||||
|
||||
contact
|
||||
"WG Web: <http://tools.ietf.org/wg/netmod/>
|
||||
WG List: <mailto:netmod@ietf.org>
|
||||
|
||||
WG Chair: Thomas Nadeau
|
||||
<mailto:tnadeau@lucidvision.com>
|
||||
|
||||
WG Chair: Juergen Schoenwaelder
|
||||
<mailto:j.schoenwaelder@jacobs-university.de>
|
||||
|
||||
Editor: Martin Bjorklund
|
||||
<mailto:mbj@tail-f.com>
|
||||
|
||||
Editor: Juergen Schoenwaelder
|
||||
<mailto:j.schoenwaelder@jacobs-university.de>";
|
||||
description
|
||||
"This module contains a collection of YANG definitions for
|
||||
configuring SNMP engines.
|
||||
|
||||
Copyright (c) 2014 IETF Trust and the persons identified as
|
||||
authors of the code. All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or
|
||||
without modification, is permitted pursuant to, and subject
|
||||
to the license terms contained in, the Simplified BSD License
|
||||
set forth in Section 4.c of the IETF Trust's Legal Provisions
|
||||
Relating to IETF Documents
|
||||
(http://trustee.ietf.org/license-info).
|
||||
|
||||
This version of this YANG module is part of RFC 7407; see
|
||||
the RFC itself for full legal notices.";
|
||||
|
||||
revision 2014-12-10 {
|
||||
description
|
||||
"Initial revision.";
|
||||
reference
|
||||
"RFC 7407: A YANG Data Model for SNMP Configuration";
|
||||
}
|
||||
|
||||
}
|
||||
211
Parseurs_logs_Switch/src/modèles/openconfig-aaa-radius.yang
Normal file
211
Parseurs_logs_Switch/src/modèles/openconfig-aaa-radius.yang
Normal file
@@ -0,0 +1,211 @@
|
||||
submodule openconfig-aaa-radius {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
belongs-to "openconfig-aaa" {
|
||||
prefix "oc-aaa";
|
||||
}
|
||||
|
||||
// import some basic types
|
||||
import openconfig-inet-types { prefix oc-inet; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-aaa-types { prefix oc-aaa-types; }
|
||||
import openconfig-types { prefix oc-types; }
|
||||
import openconfig-yang-types { prefix oc-yang; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines configuration and operational state data
|
||||
related to the RADIUS protocol for authentication,
|
||||
authorization, and accounting.";
|
||||
|
||||
oc-ext:openconfig-version "1.1.0";
|
||||
|
||||
revision 2025-10-31 {
|
||||
description
|
||||
"Added GLOME path.";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
revision "2022-07-29" {
|
||||
description
|
||||
"Update user role to be mandatory.";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
revision "2020-07-30" {
|
||||
description
|
||||
"Add secret-key-hashed.";
|
||||
reference "0.5.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.4.1";
|
||||
}
|
||||
|
||||
revision "2017-09-18" {
|
||||
description
|
||||
"Updated to use OpenConfig types modules";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2017-07-06" {
|
||||
description
|
||||
"Move to oc-inet types, add IETF attribution, add RADIUS
|
||||
counters, changed password leaf names to indicate hashed";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2017-01-29" {
|
||||
description
|
||||
"Initial public release";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// extension statements
|
||||
|
||||
// feature statements
|
||||
|
||||
// identity statements
|
||||
|
||||
identity RADIUS {
|
||||
base oc-aaa-types:AAA_SERVER_TYPE;
|
||||
description
|
||||
"Remote Authentication Dial In User Service (RADIUS) AAA
|
||||
server";
|
||||
reference
|
||||
"RFC 2865 - Remote Authentication Dial In User Service
|
||||
(RADIUS)";
|
||||
}
|
||||
|
||||
// typedef statements
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping aaa-radius-server-config {
|
||||
description
|
||||
"Configuration data for a RADIUS server";
|
||||
|
||||
leaf auth-port {
|
||||
type oc-inet:port-number;
|
||||
default 1812;
|
||||
description
|
||||
"Port number for authentication requests";
|
||||
}
|
||||
|
||||
leaf acct-port {
|
||||
type oc-inet:port-number;
|
||||
default 1813;
|
||||
description
|
||||
"Port number for accounting requests";
|
||||
}
|
||||
|
||||
leaf secret-key {
|
||||
type oc-types:routing-password;
|
||||
description
|
||||
"The unencrypted shared key used between the authentication
|
||||
server and the device.";
|
||||
}
|
||||
|
||||
leaf secret-key-hashed {
|
||||
type oc-aaa-types:crypt-password-type;
|
||||
description
|
||||
"The hashed shared key used between the authentication
|
||||
server and the device.";
|
||||
}
|
||||
|
||||
leaf source-address {
|
||||
type oc-inet:ip-address;
|
||||
description
|
||||
"Source IP address to use in messages to the RADIUS server";
|
||||
}
|
||||
|
||||
leaf retransmit-attempts {
|
||||
type uint8;
|
||||
description
|
||||
"Number of times the system may resend a request to the
|
||||
RADIUS server when it is unresponsive";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-radius-server-state {
|
||||
description
|
||||
"Operational state data for a RADIUS server";
|
||||
|
||||
container counters {
|
||||
description
|
||||
"A collection of RADIUS related state objects.";
|
||||
|
||||
leaf retried-access-requests {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Retransmitted Access-Request messages.";
|
||||
}
|
||||
|
||||
leaf access-accepts {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Received Access-Accept messages.";
|
||||
}
|
||||
|
||||
leaf access-rejects {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Received Access-Reject messages.";
|
||||
}
|
||||
|
||||
leaf timeout-access-requests {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Access-Request messages that have timed-out,
|
||||
requiring retransmission.";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-radius-server-top {
|
||||
description
|
||||
"Top-level grouping for RADIUS server data";
|
||||
|
||||
container radius {
|
||||
description
|
||||
"Top-level container for RADIUS server data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for RADIUS servers";
|
||||
|
||||
uses aaa-radius-server-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for RADIUS servers";
|
||||
|
||||
uses aaa-radius-server-config;
|
||||
uses aaa-radius-server-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
// rpc statements
|
||||
|
||||
// notification statements
|
||||
|
||||
}
|
||||
172
Parseurs_logs_Switch/src/modèles/openconfig-aaa-types.yang
Normal file
172
Parseurs_logs_Switch/src/modèles/openconfig-aaa-types.yang
Normal file
@@ -0,0 +1,172 @@
|
||||
module openconfig-aaa-types {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/aaa/types";
|
||||
|
||||
prefix "oc-aaa-types";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines shared types for data related to AAA
|
||||
(authentication, authorization, accounting).";
|
||||
|
||||
oc-ext:openconfig-version "0.4.1";
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.4.1";
|
||||
}
|
||||
|
||||
revision "2018-04-12" {
|
||||
description
|
||||
"Add when conditions, correct identities";
|
||||
reference "0.4.0";
|
||||
}
|
||||
|
||||
revision "2017-09-18" {
|
||||
description
|
||||
"Updated to use OpenConfig types modules";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2017-07-06" {
|
||||
description
|
||||
"Move to oc-inet types, add IETF attribution, add RADIUS
|
||||
counters, changed password leaf names to indicate hashed";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2017-01-29" {
|
||||
description
|
||||
"Initial public release";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
identity AAA_SERVER_TYPE {
|
||||
description
|
||||
"Base identity for types of AAA servers";
|
||||
}
|
||||
|
||||
|
||||
identity SYSTEM_DEFINED_ROLES {
|
||||
description
|
||||
"Base identity for system_defined roles that can be assigned
|
||||
to users.";
|
||||
}
|
||||
|
||||
identity SYSTEM_ROLE_ADMIN {
|
||||
base SYSTEM_DEFINED_ROLES;
|
||||
description
|
||||
"Built-in role that allows the equivalent of superuser
|
||||
permission for all configuration and operational commands
|
||||
on the device.";
|
||||
}
|
||||
|
||||
identity AAA_ACCOUNTING_EVENT_TYPE {
|
||||
description
|
||||
"Base identity for specifying events types that should be
|
||||
sent to AAA server for accounting";
|
||||
}
|
||||
|
||||
identity AAA_ACCOUNTING_EVENT_COMMAND {
|
||||
base AAA_ACCOUNTING_EVENT_TYPE;
|
||||
description
|
||||
"Specifies interactive command events for AAA accounting";
|
||||
}
|
||||
|
||||
identity AAA_ACCOUNTING_EVENT_LOGIN {
|
||||
base AAA_ACCOUNTING_EVENT_TYPE;
|
||||
description
|
||||
"Specifies login events for AAA accounting";
|
||||
}
|
||||
|
||||
identity AAA_AUTHORIZATION_EVENT_TYPE {
|
||||
description
|
||||
"Base identity for specifying activities that should be
|
||||
sent to AAA server for authorization";
|
||||
}
|
||||
|
||||
identity AAA_AUTHORIZATION_EVENT_COMMAND {
|
||||
base AAA_AUTHORIZATION_EVENT_TYPE;
|
||||
description
|
||||
"Specifies interactive command events for AAA authorization";
|
||||
}
|
||||
|
||||
identity AAA_AUTHORIZATION_EVENT_CONFIG {
|
||||
base AAA_AUTHORIZATION_EVENT_TYPE;
|
||||
description
|
||||
"Specifies configuration (e.g., EXEC) events for AAA
|
||||
authorization";
|
||||
}
|
||||
|
||||
identity AAA_METHOD_TYPE {
|
||||
description
|
||||
"Base identity to define well-known methods for AAA
|
||||
operations";
|
||||
}
|
||||
|
||||
identity TACACS_ALL {
|
||||
base AAA_METHOD_TYPE;
|
||||
description
|
||||
"The group of all TACACS+ servers.";
|
||||
}
|
||||
|
||||
identity RADIUS_ALL {
|
||||
base AAA_METHOD_TYPE;
|
||||
description
|
||||
"The group of all RADIUS servers.";
|
||||
}
|
||||
|
||||
identity LOCAL {
|
||||
base AAA_METHOD_TYPE;
|
||||
description
|
||||
"Locally configured method for AAA operations.";
|
||||
}
|
||||
|
||||
|
||||
// typedef statements
|
||||
|
||||
typedef crypt-password-type {
|
||||
type string;
|
||||
description
|
||||
"A password that is hashed based on the hash algorithm
|
||||
indicated by the prefix in the string. The string
|
||||
takes the following form, based on the Unix crypt function:
|
||||
|
||||
$<id>[$<param>=<value>(,<param>=<value>)*][$<salt>[$<hash>]]
|
||||
|
||||
Common hash functions include:
|
||||
|
||||
id | hash function
|
||||
---+---------------
|
||||
1 | MD5
|
||||
2a| Blowfish
|
||||
2y| Blowfish (correct handling of 8-bit chars)
|
||||
5 | SHA-256
|
||||
6 | SHA-512
|
||||
|
||||
These may not all be supported by a target device.";
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
865
Parseurs_logs_Switch/src/modèles/openconfig-aaa.yang
Normal file
865
Parseurs_logs_Switch/src/modèles/openconfig-aaa.yang
Normal file
@@ -0,0 +1,865 @@
|
||||
module openconfig-aaa {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/aaa";
|
||||
|
||||
prefix "oc-aaa";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-inet-types { prefix oc-inet; }
|
||||
import openconfig-yang-types { prefix oc-yang; }
|
||||
import openconfig-aaa-types { prefix oc-aaa-types; }
|
||||
|
||||
include openconfig-aaa-tacacs;
|
||||
include openconfig-aaa-radius;
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines configuration and operational state data
|
||||
related to authorization, authentication, and accounting (AAA)
|
||||
management.
|
||||
|
||||
Portions of this model reuse data definitions or structure from
|
||||
RFC 7317 - A YANG Data Model for System Management";
|
||||
|
||||
oc-ext:openconfig-version "1.1.0";
|
||||
|
||||
revision 2025-10-31 {
|
||||
description
|
||||
"Added GLOME path.";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
revision "2022-07-29" {
|
||||
description
|
||||
"Update user role to be mandatory.";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
revision "2020-07-30" {
|
||||
description
|
||||
"Add secret-key-hashed for TACACS and RADIUS.";
|
||||
reference "0.5.0";
|
||||
}
|
||||
|
||||
revision "2019-10-28" {
|
||||
description
|
||||
"Fix bug in when statement path";
|
||||
reference "0.4.3";
|
||||
}
|
||||
|
||||
revision "2019-08-20" {
|
||||
description
|
||||
"Fix identity prefixes and when statement paths";
|
||||
reference "0.4.2";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.4.1";
|
||||
}
|
||||
|
||||
revision "2018-04-12" {
|
||||
description
|
||||
"Add when conditions, correct identities";
|
||||
reference "0.4.0";
|
||||
}
|
||||
|
||||
revision "2017-09-18" {
|
||||
description
|
||||
"Updated to use OpenConfig types modules";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2017-07-06" {
|
||||
description
|
||||
"Move to oc-inet types, add IETF attribution, add RADIUS
|
||||
counters, changed password leaf names to indicate hashed";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2017-01-29" {
|
||||
description
|
||||
"Initial public release";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
// grouping statements
|
||||
grouping aaa-servergroup-common-config {
|
||||
description
|
||||
"Configuration data for AAA server groups";
|
||||
|
||||
leaf name {
|
||||
type string;
|
||||
description
|
||||
"Name for the server group";
|
||||
}
|
||||
|
||||
leaf type {
|
||||
type identityref {
|
||||
base oc-aaa-types:AAA_SERVER_TYPE;
|
||||
}
|
||||
description
|
||||
"AAA server type -- all servers in the group must be of this
|
||||
type";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-servergroup-common-state {
|
||||
description
|
||||
"Operational state data for AAA server groups";
|
||||
|
||||
//TODO: add list of group members as opstate
|
||||
}
|
||||
|
||||
grouping aaa-servergroup-common-top {
|
||||
description
|
||||
"Top-level grouping for AAA server groups";
|
||||
|
||||
container server-groups {
|
||||
description
|
||||
"Enclosing container for AAA server groups";
|
||||
|
||||
list server-group {
|
||||
key "name";
|
||||
description
|
||||
"List of AAA server groups. All servers in a group
|
||||
must have the same type as indicated by the server
|
||||
type.";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "../config/name";
|
||||
}
|
||||
description
|
||||
"Reference to configured name of the server group";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for each server group";
|
||||
|
||||
uses aaa-servergroup-common-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for each server group";
|
||||
|
||||
uses aaa-servergroup-common-config;
|
||||
uses aaa-servergroup-common-state;
|
||||
}
|
||||
|
||||
uses aaa-server-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-server-config {
|
||||
description
|
||||
"Common configuration data for AAA servers";
|
||||
|
||||
leaf name {
|
||||
type string;
|
||||
description
|
||||
"Name assigned to the server";
|
||||
}
|
||||
|
||||
|
||||
leaf address {
|
||||
type oc-inet:ip-address;
|
||||
description "Address of the authentication server";
|
||||
}
|
||||
|
||||
leaf timeout {
|
||||
type uint16;
|
||||
units seconds;
|
||||
description
|
||||
"Set the timeout in seconds on responses from the AAA
|
||||
server";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-server-state {
|
||||
description
|
||||
"Common operational state data for AAA servers";
|
||||
|
||||
leaf connection-opens {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of new connection requests sent to the server, e.g.
|
||||
socket open";
|
||||
}
|
||||
|
||||
leaf connection-closes {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of connection close requests sent to the server, e.g.
|
||||
socket close";
|
||||
}
|
||||
|
||||
leaf connection-aborts {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of aborted connections to the server. These do
|
||||
not include connections that are close gracefully.";
|
||||
}
|
||||
|
||||
leaf connection-failures {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of connection failures to the server";
|
||||
}
|
||||
|
||||
leaf connection-timeouts {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of connection timeouts to the server";
|
||||
}
|
||||
|
||||
leaf messages-sent {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of messages sent to the server";
|
||||
}
|
||||
|
||||
leaf messages-received {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of messages received by the server";
|
||||
}
|
||||
|
||||
leaf errors-received {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of error messages received from the server";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
grouping aaa-server-top {
|
||||
description
|
||||
"Top-level grouping for list of AAA servers";
|
||||
|
||||
container servers {
|
||||
description
|
||||
"Enclosing container the list of servers";
|
||||
|
||||
list server {
|
||||
key "address";
|
||||
description
|
||||
"List of AAA servers";
|
||||
|
||||
leaf address {
|
||||
type leafref {
|
||||
path "../config/address";
|
||||
}
|
||||
description
|
||||
"Reference to the configured address of the AAA server";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data ";
|
||||
|
||||
uses aaa-server-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data ";
|
||||
|
||||
uses aaa-server-config;
|
||||
uses aaa-server-state;
|
||||
}
|
||||
|
||||
uses aaa-tacacs-server-top {
|
||||
when "../../config/type = 'oc-aaa:TACACS'";
|
||||
}
|
||||
|
||||
uses aaa-radius-server-top {
|
||||
when "../../config/type = 'oc-aaa:RADIUS'";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-admin-config {
|
||||
description
|
||||
"Configuration data for the system built-in
|
||||
administrator / root user account";
|
||||
|
||||
leaf admin-password {
|
||||
type string;
|
||||
oc-ext:openconfig-hashed-value;
|
||||
description
|
||||
"The admin/root password, supplied as a cleartext string.
|
||||
The system should hash and only store the password as a
|
||||
hashed value.";
|
||||
}
|
||||
|
||||
leaf admin-password-hashed {
|
||||
type oc-aaa-types:crypt-password-type;
|
||||
description
|
||||
"The admin/root password, supplied as a hashed value
|
||||
using the notation described in the definition of the
|
||||
crypt-password-type.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-admin-state {
|
||||
description
|
||||
"Operational state data for the root user";
|
||||
|
||||
leaf admin-username {
|
||||
type string;
|
||||
description
|
||||
"Name of the administrator user account, e.g., admin, root,
|
||||
etc.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-authentication-admin-top {
|
||||
description
|
||||
"Top-level grouping for root user configuration and state
|
||||
data";
|
||||
|
||||
container admin-user {
|
||||
description
|
||||
"Top-level container for the system root or admin user
|
||||
configuration and operational state";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for the root user account";
|
||||
|
||||
uses aaa-admin-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for the root user account";
|
||||
|
||||
uses aaa-admin-config;
|
||||
uses aaa-admin-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
grouping aaa-authentication-user-config {
|
||||
description
|
||||
"Configuration data for local users";
|
||||
|
||||
leaf username {
|
||||
type string;
|
||||
description
|
||||
"Assigned username for this user";
|
||||
}
|
||||
|
||||
leaf password {
|
||||
type string;
|
||||
oc-ext:openconfig-hashed-value;
|
||||
description
|
||||
"The user password, supplied as cleartext. The system
|
||||
must hash the value and only store the hashed value.";
|
||||
}
|
||||
|
||||
leaf password-hashed {
|
||||
type oc-aaa-types:crypt-password-type;
|
||||
description
|
||||
"The user password, supplied as a hashed value
|
||||
using the notation described in the definition of the
|
||||
crypt-password-type.";
|
||||
}
|
||||
|
||||
leaf ssh-key {
|
||||
type string;
|
||||
description
|
||||
"SSH public key for the user (RSA or DSA)";
|
||||
}
|
||||
|
||||
leaf role {
|
||||
type union {
|
||||
type string;
|
||||
type identityref {
|
||||
base oc-aaa-types:SYSTEM_DEFINED_ROLES;
|
||||
}
|
||||
}
|
||||
mandatory true;
|
||||
description
|
||||
"Role assigned to the user. The role must be supplied
|
||||
as a role defined by the SYSTEM_DEFINED_ROLES
|
||||
identity or a string that matches a user defined role.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-authentication-user-state {
|
||||
description
|
||||
"Operational state data for local users";
|
||||
}
|
||||
|
||||
grouping aaa-authentication-user-top {
|
||||
description
|
||||
"Top-level grouping for local users";
|
||||
|
||||
container users {
|
||||
description
|
||||
"Enclosing container list of local users";
|
||||
|
||||
list user {
|
||||
key "username";
|
||||
description
|
||||
"List of local users on the system";
|
||||
|
||||
leaf username {
|
||||
type leafref {
|
||||
path "../config/username";
|
||||
}
|
||||
description
|
||||
"References the configured username for the user";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for local users";
|
||||
|
||||
uses aaa-authentication-user-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for local users";
|
||||
|
||||
uses aaa-authentication-user-config;
|
||||
uses aaa-authentication-user-state;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-accounting-methods-common {
|
||||
description
|
||||
"Common definitions for accounting methods";
|
||||
|
||||
leaf-list accounting-method {
|
||||
type union {
|
||||
type identityref {
|
||||
base oc-aaa-types:AAA_METHOD_TYPE;
|
||||
}
|
||||
type string;
|
||||
//TODO: in YANG 1.1 this should be converted to a leafref to
|
||||
//point to the server group name.
|
||||
}
|
||||
ordered-by user;
|
||||
description
|
||||
"An ordered list of methods used for AAA accounting for this
|
||||
event type. The method is defined by the destination for
|
||||
accounting data, which may be specified as the group of
|
||||
all TACACS+/RADIUS servers, a defined server group, or
|
||||
the local system.";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
grouping aaa-accounting-events-config {
|
||||
description
|
||||
"Configuration data for AAA accounting events";
|
||||
|
||||
leaf event-type {
|
||||
type identityref {
|
||||
base oc-aaa-types:AAA_ACCOUNTING_EVENT_TYPE;
|
||||
}
|
||||
description
|
||||
"The type of activity to record at the AAA accounting
|
||||
server";
|
||||
}
|
||||
|
||||
leaf record {
|
||||
type enumeration {
|
||||
enum START_STOP {
|
||||
description
|
||||
"Send START record to the accounting server at the
|
||||
beginning of the activity, and STOP record at the
|
||||
end of the activity.";
|
||||
}
|
||||
enum STOP {
|
||||
description
|
||||
"Send STOP record to the accounting server when the
|
||||
user activity completes";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Type of record to send to the accounting server for this
|
||||
activity type";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-accounting-events-state {
|
||||
description
|
||||
"Operational state data for accounting events";
|
||||
}
|
||||
|
||||
grouping aaa-accounting-events-top {
|
||||
description
|
||||
"Top-level grouping for accounting events";
|
||||
|
||||
container events {
|
||||
description
|
||||
"Enclosing container for defining handling of events
|
||||
for accounting";
|
||||
|
||||
list event {
|
||||
key "event-type";
|
||||
description
|
||||
"List of events subject to accounting";
|
||||
|
||||
leaf event-type {
|
||||
type leafref {
|
||||
path "../config/event-type";
|
||||
}
|
||||
description
|
||||
"Reference to the event-type being logged at the
|
||||
accounting server";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for accounting events";
|
||||
|
||||
uses aaa-accounting-events-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for accounting events";
|
||||
|
||||
uses aaa-accounting-events-config;
|
||||
uses aaa-accounting-events-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-accounting-config {
|
||||
description
|
||||
"Configuration data for event accounting";
|
||||
|
||||
uses aaa-accounting-methods-common;
|
||||
|
||||
}
|
||||
|
||||
grouping aaa-accounting-state {
|
||||
description
|
||||
"Operational state data for event accounting services";
|
||||
}
|
||||
|
||||
grouping aaa-accounting-top {
|
||||
description
|
||||
"Top-level grouping for user activity accounting";
|
||||
|
||||
container accounting {
|
||||
description
|
||||
"Top-level container for AAA accounting";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for user activity accounting.";
|
||||
|
||||
uses aaa-accounting-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for user accounting.";
|
||||
|
||||
uses aaa-accounting-config;
|
||||
uses aaa-accounting-state;
|
||||
}
|
||||
|
||||
uses aaa-accounting-events-top;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-authorization-methods-config {
|
||||
description
|
||||
"Common definitions for authorization methods for global
|
||||
and per-event type";
|
||||
|
||||
leaf-list authorization-method {
|
||||
type union {
|
||||
type identityref {
|
||||
base oc-aaa-types:AAA_METHOD_TYPE;
|
||||
}
|
||||
type string;
|
||||
}
|
||||
ordered-by user;
|
||||
description
|
||||
"Ordered list of methods for authorizing commands. The first
|
||||
method that provides a response (positive or negative) should
|
||||
be used. The list may contain a well-defined method such
|
||||
as the set of all TACACS or RADIUS servers, or the name of
|
||||
a defined AAA server group. The system must validate
|
||||
that the named server group exists.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-authorization-events-config {
|
||||
description
|
||||
"Configuration data for AAA authorization events";
|
||||
|
||||
leaf event-type {
|
||||
type identityref {
|
||||
base oc-aaa-types:AAA_AUTHORIZATION_EVENT_TYPE;
|
||||
}
|
||||
description
|
||||
"The type of event to record at the AAA authorization
|
||||
server";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-authorization-events-state {
|
||||
description
|
||||
"Operational state data for AAA authorization events";
|
||||
}
|
||||
|
||||
grouping aaa-authorization-events-top {
|
||||
description
|
||||
"Top-level grouping for authorization events";
|
||||
|
||||
container events {
|
||||
description
|
||||
"Enclosing container for the set of events subject
|
||||
to authorization";
|
||||
|
||||
list event {
|
||||
key "event-type";
|
||||
description
|
||||
"List of events subject to AAA authorization";
|
||||
|
||||
leaf event-type {
|
||||
type leafref {
|
||||
path "../config/event-type";
|
||||
}
|
||||
description
|
||||
"Reference to the event-type list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for each authorized event";
|
||||
|
||||
uses aaa-authorization-events-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for each authorized activity";
|
||||
|
||||
uses aaa-authorization-events-config;
|
||||
uses aaa-authorization-events-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-authorization-config {
|
||||
description
|
||||
"Configuration data for AAA authorization";
|
||||
|
||||
uses aaa-authorization-methods-config;
|
||||
}
|
||||
|
||||
grouping aaa-authorization-state {
|
||||
description
|
||||
"Operational state data for AAA authorization";
|
||||
}
|
||||
|
||||
grouping aaa-authorization-top {
|
||||
description
|
||||
"Top-level grouping for AAA authorization";
|
||||
|
||||
container authorization {
|
||||
description
|
||||
"Top-level container for AAA authorization configuration
|
||||
and operational state data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for authorization based on AAA
|
||||
methods";
|
||||
|
||||
uses aaa-authorization-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for authorization based on AAA";
|
||||
|
||||
uses aaa-authorization-config;
|
||||
uses aaa-authorization-state;
|
||||
}
|
||||
|
||||
uses aaa-authorization-events-top;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-authentication-config {
|
||||
description
|
||||
"Configuration data for global authentication";
|
||||
|
||||
leaf-list authentication-method {
|
||||
type union {
|
||||
type identityref {
|
||||
base oc-aaa-types:AAA_METHOD_TYPE;
|
||||
}
|
||||
type string;
|
||||
//TODO: string should be a leafref to a defined
|
||||
//server group. this will be possible in YANG 1.1
|
||||
//type leafref {
|
||||
//path "/aaa/server-groups/server-group/config/name";
|
||||
//}
|
||||
}
|
||||
ordered-by user;
|
||||
description
|
||||
"Ordered list of authentication methods for users. This
|
||||
can be either a reference to a server group, or a well-
|
||||
defined designation in the AAA_METHOD_TYPE identity. If
|
||||
authentication fails with one method, the next defined
|
||||
method is tried -- failure of all methods results in the
|
||||
user being denied access.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-authentication-state {
|
||||
description
|
||||
"Operational state data for global authentication";
|
||||
}
|
||||
|
||||
grouping aaa-authentication-top {
|
||||
description
|
||||
"Top-level grouping for top-level authentication";
|
||||
|
||||
container authentication {
|
||||
description
|
||||
"Top-level container for global authentication data";
|
||||
|
||||
container glome {
|
||||
description
|
||||
"GLOME (Generic Low Overhead Message Exchange) authentication parameters for console access.";
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters for GLOME.";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for global authentication services";
|
||||
|
||||
uses aaa-authentication-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for global authentication
|
||||
services";
|
||||
|
||||
uses aaa-authentication-config;
|
||||
uses aaa-authentication-state;
|
||||
}
|
||||
|
||||
uses aaa-authentication-admin-top;
|
||||
uses aaa-authentication-user-top;
|
||||
}
|
||||
}
|
||||
|
||||
grouping aaa-config {
|
||||
description
|
||||
"Configuration data for top level AAA";
|
||||
}
|
||||
|
||||
grouping aaa-state {
|
||||
description
|
||||
"Operational state data for top level AAA";
|
||||
}
|
||||
|
||||
grouping aaa-top {
|
||||
description
|
||||
"Top-level grouping for AAA services";
|
||||
|
||||
container aaa {
|
||||
description
|
||||
"Top-level container for AAA services";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for top level AAA services";
|
||||
|
||||
uses aaa-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for top level AAA services ";
|
||||
|
||||
uses aaa-config;
|
||||
uses aaa-state;
|
||||
}
|
||||
|
||||
uses aaa-authentication-top;
|
||||
uses aaa-authorization-top;
|
||||
uses aaa-accounting-top;
|
||||
uses aaa-servergroup-common-top;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
// data definition statements
|
||||
|
||||
|
||||
}
|
||||
935
Parseurs_logs_Switch/src/modèles/openconfig-acl.yang
Normal file
935
Parseurs_logs_Switch/src/modèles/openconfig-acl.yang
Normal file
@@ -0,0 +1,935 @@
|
||||
module openconfig-acl {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/acl";
|
||||
|
||||
prefix "oc-acl";
|
||||
|
||||
import openconfig-packet-match { prefix oc-match; }
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import openconfig-yang-types { prefix oc-yang; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines configuration and operational state
|
||||
data for network access control lists (i.e., filters, rules,
|
||||
etc.). ACLs are organized into ACL sets, with each set
|
||||
containing one or more ACL entries. ACL sets are identified
|
||||
by a unique name, while each entry within a set is assigned
|
||||
a sequence-id that determines the order in which the ACL
|
||||
rules are applied to a packet. Note that ACLs are evaluated
|
||||
in ascending order based on the sequence-id (low to high).
|
||||
|
||||
Individual ACL rules specify match criteria based on fields in
|
||||
the packet, along with an action that defines how matching
|
||||
packets should be handled. Entries have a type that indicates
|
||||
the type of match criteria, e.g., MAC layer, IPv4, IPv6, etc.";
|
||||
|
||||
oc-ext:openconfig-version "1.3.3";
|
||||
|
||||
revision "2023-02-06" {
|
||||
description
|
||||
"Add clarifying comments on use of interface-ref.";
|
||||
reference "1.3.3";
|
||||
}
|
||||
|
||||
revision "2023-01-29" {
|
||||
description
|
||||
"Update sequence-id reference to allow model to be re-used
|
||||
outside of ACL context.";
|
||||
reference "1.3.2";
|
||||
}
|
||||
|
||||
revision "2022-12-20" {
|
||||
description
|
||||
"Remove unused openconfig-inet-types import";
|
||||
reference "1.3.1";
|
||||
}
|
||||
|
||||
revision "2022-06-01" {
|
||||
description
|
||||
"Add the management of prefix lists
|
||||
that can be used in matches";
|
||||
reference "1.3.0";
|
||||
}
|
||||
|
||||
revision "2022-01-14" {
|
||||
description
|
||||
"Fix when statements for MIXED mode ACLs";
|
||||
reference "1.2.2";
|
||||
}
|
||||
|
||||
revision "2021-06-16" {
|
||||
description
|
||||
"Remove trailing whitespace";
|
||||
reference "1.2.1";
|
||||
}
|
||||
|
||||
revision "2021-03-17" {
|
||||
description
|
||||
"Add MPLS filter Support.";
|
||||
reference "1.2.0";
|
||||
}
|
||||
|
||||
revision "2019-11-27" {
|
||||
description
|
||||
"Fix xpaths in when statements.";
|
||||
reference "1.1.1";
|
||||
}
|
||||
|
||||
revision "2019-10-25" {
|
||||
description
|
||||
"Update when statements.";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "1.0.2";
|
||||
}
|
||||
|
||||
revision "2018-04-24" {
|
||||
description
|
||||
"Clarified order of ACL evaluation";
|
||||
reference "1.0.1";
|
||||
}
|
||||
|
||||
revision "2017-05-26" {
|
||||
description
|
||||
"Separated ACL entries by type";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
revision "2016-08-08" {
|
||||
description
|
||||
"OpenConfig public release";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2016-01-22" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "TBD";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
identity ACL_TYPE {
|
||||
description
|
||||
"Base identity for types of ACL sets";
|
||||
}
|
||||
|
||||
identity ACL_IPV4 {
|
||||
base ACL_TYPE;
|
||||
description
|
||||
"IP-layer ACLs with IPv4 addresses";
|
||||
}
|
||||
|
||||
identity ACL_IPV6 {
|
||||
base ACL_TYPE;
|
||||
description
|
||||
"IP-layer ACLs with IPv6 addresses";
|
||||
}
|
||||
|
||||
identity ACL_L2 {
|
||||
base ACL_TYPE;
|
||||
description
|
||||
"MAC-layer ACLs";
|
||||
}
|
||||
|
||||
identity ACL_MIXED {
|
||||
base ACL_TYPE;
|
||||
description
|
||||
"Mixed-mode ACL that specifies L2 and L3 protocol
|
||||
fields. This ACL type is not implemented by many
|
||||
routing/switching devices.";
|
||||
}
|
||||
|
||||
identity ACL_MPLS {
|
||||
base ACL_TYPE;
|
||||
description
|
||||
"An ACL that matches on fields from the MPLS header.";
|
||||
}
|
||||
|
||||
// ACL action type
|
||||
|
||||
identity FORWARDING_ACTION {
|
||||
description
|
||||
"Base identity for actions in the forwarding category";
|
||||
}
|
||||
|
||||
identity ACCEPT {
|
||||
base FORWARDING_ACTION;
|
||||
description
|
||||
"Accept the packet";
|
||||
}
|
||||
|
||||
identity DROP {
|
||||
base FORWARDING_ACTION;
|
||||
description
|
||||
"Drop packet without sending any ICMP error message";
|
||||
}
|
||||
|
||||
identity REJECT {
|
||||
base FORWARDING_ACTION;
|
||||
description
|
||||
"Drop the packet and send an ICMP error message to the source";
|
||||
}
|
||||
|
||||
identity LOG_ACTION {
|
||||
description
|
||||
"Base identity for defining the destination for logging
|
||||
actions";
|
||||
}
|
||||
|
||||
identity LOG_SYSLOG {
|
||||
base LOG_ACTION;
|
||||
description
|
||||
"Log the packet in Syslog";
|
||||
}
|
||||
|
||||
identity LOG_NONE {
|
||||
base LOG_ACTION;
|
||||
description
|
||||
"No logging";
|
||||
}
|
||||
|
||||
identity ACL_COUNTER_CAPABILITY {
|
||||
description
|
||||
"Base identity for system to indicate how it is able to report
|
||||
counters";
|
||||
}
|
||||
|
||||
identity INTERFACE_ONLY {
|
||||
base ACL_COUNTER_CAPABILITY;
|
||||
description
|
||||
"ACL counters are available and reported only per interface";
|
||||
}
|
||||
|
||||
identity AGGREGATE_ONLY {
|
||||
base ACL_COUNTER_CAPABILITY;
|
||||
description
|
||||
"ACL counters are aggregated over all interfaces, and reported
|
||||
only per ACL entry";
|
||||
}
|
||||
|
||||
identity INTERFACE_AGGREGATE {
|
||||
base ACL_COUNTER_CAPABILITY;
|
||||
description
|
||||
"ACL counters are reported per interface, and also aggregated
|
||||
and reported per ACL entry.";
|
||||
}
|
||||
|
||||
// grouping statements
|
||||
|
||||
// input interface
|
||||
grouping input-interface-config {
|
||||
description
|
||||
"Config of interface";
|
||||
|
||||
}
|
||||
|
||||
grouping input-interface-state {
|
||||
description
|
||||
"State information of interface";
|
||||
}
|
||||
|
||||
grouping input-interface-top {
|
||||
description
|
||||
"Input interface top level container";
|
||||
|
||||
container input-interface {
|
||||
description
|
||||
"Input interface container. The interface is resolved based
|
||||
on the interface and subinterface leaves of the interface-ref
|
||||
container, which are references to entries in the /interfaces
|
||||
list.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Config data";
|
||||
uses input-interface-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"State information";
|
||||
uses input-interface-config;
|
||||
uses input-interface-state;
|
||||
}
|
||||
|
||||
uses oc-if:interface-ref;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
// Action Type
|
||||
grouping action-config {
|
||||
description
|
||||
"Config of action type";
|
||||
|
||||
|
||||
leaf forwarding-action {
|
||||
type identityref {
|
||||
base FORWARDING_ACTION;
|
||||
}
|
||||
mandatory true;
|
||||
description
|
||||
"Specifies the forwarding action. One forwarding action
|
||||
must be specified for each ACL entry";
|
||||
}
|
||||
|
||||
leaf log-action {
|
||||
type identityref {
|
||||
base LOG_ACTION;
|
||||
}
|
||||
default LOG_NONE;
|
||||
description
|
||||
"Specifies the log action and destination for
|
||||
matched packets. The default is not to log the
|
||||
packet.";
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
grouping action-state {
|
||||
description
|
||||
"State information of action type";
|
||||
|
||||
}
|
||||
|
||||
grouping action-top {
|
||||
description
|
||||
"ACL action type top level container";
|
||||
|
||||
container actions {
|
||||
description
|
||||
"Enclosing container for list of ACL actions associated
|
||||
with an entry";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Config data for ACL actions";
|
||||
uses action-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"State information for ACL actions";
|
||||
uses action-config;
|
||||
uses action-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping acl-counters-state {
|
||||
description
|
||||
"Common grouping for ACL counters";
|
||||
|
||||
leaf matched-packets {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Count of the number of packets matching the current ACL
|
||||
entry.
|
||||
|
||||
An implementation should provide this counter on a
|
||||
per-interface per-ACL-entry if possible.
|
||||
|
||||
If an implementation only supports ACL counters per entry
|
||||
(i.e., not broken out per interface), then the value
|
||||
should be equal to the aggregate count across all interfaces.
|
||||
|
||||
An implementation that provides counters per entry per
|
||||
interface is not required to also provide an aggregate count,
|
||||
e.g., per entry -- the user is expected to be able implement
|
||||
the required aggregation if such a count is needed.";
|
||||
}
|
||||
|
||||
leaf matched-octets {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Count of the number of octets (bytes) matching the current
|
||||
ACL entry.
|
||||
|
||||
An implementation should provide this counter on a
|
||||
per-interface per-ACL-entry if possible.
|
||||
|
||||
If an implementation only supports ACL counters per entry
|
||||
(i.e., not broken out per interface), then the value
|
||||
should be equal to the aggregate count across all interfaces.
|
||||
|
||||
An implementation that provides counters per entry per
|
||||
interface is not required to also provide an aggregate count,
|
||||
e.g., per entry -- the user is expected to be able implement
|
||||
the required aggregation if such a count is needed.";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Access List Entries
|
||||
|
||||
grouping access-list-entries-config {
|
||||
description
|
||||
"Access List Entries (ACE) config.";
|
||||
|
||||
leaf sequence-id {
|
||||
type uint32;
|
||||
description
|
||||
"The sequence id determines the order in which ACL entries
|
||||
are applied. The sequence id must be unique for each entry
|
||||
in an ACL set. Target devices should apply the ACL entry
|
||||
rules in ascending order determined by sequence id (low to
|
||||
high), rather than the relying only on order in the list.";
|
||||
}
|
||||
|
||||
leaf description {
|
||||
type string;
|
||||
description
|
||||
"A user-defined description, or comment, for this Access List
|
||||
Entry.";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
grouping access-list-entries-state {
|
||||
description
|
||||
"Access List Entries state.";
|
||||
|
||||
uses acl-counters-state;
|
||||
|
||||
}
|
||||
|
||||
grouping access-list-entries-top {
|
||||
description
|
||||
"Access list entries to level container";
|
||||
|
||||
container acl-entries {
|
||||
description
|
||||
"Access list entries container";
|
||||
|
||||
list acl-entry {
|
||||
key "sequence-id";
|
||||
description
|
||||
"List of ACL entries comprising an ACL set";
|
||||
|
||||
leaf sequence-id {
|
||||
type leafref {
|
||||
path "../config/sequence-id";
|
||||
}
|
||||
description
|
||||
"references the list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Access list entries config";
|
||||
uses access-list-entries-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"State information for ACL entries";
|
||||
uses access-list-entries-config;
|
||||
uses access-list-entries-state;
|
||||
}
|
||||
|
||||
uses oc-match:ethernet-header-top {
|
||||
when "../../config/type='ACL_L2' or " +
|
||||
"../../config/type='ACL_MIXED'" {
|
||||
description
|
||||
"MAC-layer fields are valid when the ACL type is L2 or
|
||||
MIXED";
|
||||
}
|
||||
}
|
||||
|
||||
uses oc-match:ipv4-protocol-fields-top {
|
||||
when "../../config/type='ACL_IPV4' or " +
|
||||
"../../config/type='ACL_MIXED'" {
|
||||
description
|
||||
"IPv4-layer fields are valid when the ACL type is
|
||||
IPv4 or MIXED";
|
||||
}
|
||||
}
|
||||
|
||||
uses oc-match:mpls-header-top {
|
||||
when "../../config/type='ACL_MPLS' or " +
|
||||
"../../config/type='ACL_MIXED'" {
|
||||
description
|
||||
"MPLS-layer fields are valid when the ACL type is
|
||||
MPLS or MIXED";
|
||||
}
|
||||
}
|
||||
|
||||
uses oc-match:ipv6-protocol-fields-top {
|
||||
when "../../config/type='ACL_IPV6' or " +
|
||||
"../../config/type='ACL_MIXED'" {
|
||||
description
|
||||
"IPv6-layer fields are valid when the ACL type is
|
||||
IPv6 or MIXED";
|
||||
}
|
||||
}
|
||||
|
||||
uses oc-match:transport-fields-top {
|
||||
when "../../config/type='ACL_IPV6' or " +
|
||||
"../../config/type='ACL_IPV4' or " +
|
||||
"../../config/type='ACL_MIXED'" {
|
||||
description
|
||||
"Transport-layer fields are valid when specifying
|
||||
L3 or MIXED ACL types";
|
||||
}
|
||||
}
|
||||
|
||||
uses input-interface-top;
|
||||
uses action-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping acl-set-config {
|
||||
description
|
||||
"Access Control List config";
|
||||
|
||||
leaf name {
|
||||
type string;
|
||||
description
|
||||
"The name of the access-list set";
|
||||
}
|
||||
|
||||
leaf type {
|
||||
type identityref {
|
||||
base ACL_TYPE;
|
||||
}
|
||||
description
|
||||
"The type determines the fields allowed in the ACL entries
|
||||
belonging to the ACL set (e.g., IPv4, IPv6, etc.)";
|
||||
}
|
||||
|
||||
leaf description {
|
||||
type string;
|
||||
description
|
||||
"Description, or comment, for the ACL set";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
grouping acl-set-state {
|
||||
description
|
||||
"Access Control List state";
|
||||
}
|
||||
|
||||
grouping acl-set-top {
|
||||
description
|
||||
"Access list entries variables top level container";
|
||||
|
||||
container acl-sets {
|
||||
description
|
||||
"Access list entries variables enclosing container";
|
||||
|
||||
list acl-set {
|
||||
key "name type";
|
||||
description
|
||||
"List of ACL sets, each comprising of a list of ACL
|
||||
entries";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "../config/name";
|
||||
}
|
||||
description
|
||||
"Reference to the name list key";
|
||||
}
|
||||
|
||||
leaf type {
|
||||
type leafref {
|
||||
path "../config/type";
|
||||
}
|
||||
description
|
||||
"Reference to the type list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Access list config";
|
||||
uses acl-set-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Access list state information";
|
||||
uses acl-set-config;
|
||||
uses acl-set-state;
|
||||
}
|
||||
uses access-list-entries-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping interface-acl-entries-config {
|
||||
description
|
||||
"Configuration data for per-interface ACLs";
|
||||
|
||||
}
|
||||
|
||||
grouping interface-acl-entries-state {
|
||||
description
|
||||
"Operational state data for per-interface ACL entries";
|
||||
|
||||
leaf sequence-id {
|
||||
type leafref {
|
||||
path "/oc-acl:acl/oc-acl:acl-sets/" +
|
||||
"oc-acl:acl-set[oc-acl:name=current()/../../../../set-name]" +
|
||||
"[oc-acl:type=current()/../../../../type]/" +
|
||||
"oc-acl:acl-entries/oc-acl:acl-entry/oc-acl:sequence-id";
|
||||
}
|
||||
description
|
||||
"Reference to an entry in the ACL set applied to an
|
||||
interface";
|
||||
}
|
||||
|
||||
uses acl-counters-state;
|
||||
|
||||
}
|
||||
|
||||
grouping interface-acl-entries-top {
|
||||
description
|
||||
"Top-level grouping for per-interface ACL entries";
|
||||
|
||||
container acl-entries {
|
||||
config false;
|
||||
description
|
||||
"Enclosing container for list of references to ACLs";
|
||||
|
||||
list acl-entry {
|
||||
key "sequence-id";
|
||||
description
|
||||
"List of ACL entries assigned to an interface";
|
||||
|
||||
leaf sequence-id {
|
||||
type leafref {
|
||||
path "../state/sequence-id";
|
||||
}
|
||||
description
|
||||
"Reference to per-interface acl entry key";
|
||||
}
|
||||
|
||||
// no config container since the enclosing container is
|
||||
// read-only
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for per-interface ACL entries";
|
||||
|
||||
uses interface-acl-entries-config;
|
||||
uses interface-acl-entries-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping interface-ingress-acl-config {
|
||||
description
|
||||
"Configuration data for per-interface ingress ACLs";
|
||||
|
||||
leaf set-name {
|
||||
type leafref {
|
||||
path "../../../../../../acl-sets/acl-set/config/name";
|
||||
}
|
||||
description
|
||||
"Reference to the ACL set name applied on ingress";
|
||||
}
|
||||
|
||||
leaf type {
|
||||
type leafref {
|
||||
path "../../../../../../acl-sets/acl-set[name=current()/../set-name]" +
|
||||
"/config/type";
|
||||
}
|
||||
description
|
||||
"Reference to the ACL set type applied on ingress";
|
||||
}
|
||||
}
|
||||
|
||||
grouping interface-ingress-acl-state {
|
||||
description
|
||||
"Operational state data for the per-interface ingress ACL";
|
||||
}
|
||||
|
||||
grouping interface-ingress-acl-top {
|
||||
description
|
||||
"Top-level grouping for per-interface ingress ACL data";
|
||||
|
||||
container ingress-acl-sets {
|
||||
description
|
||||
"Enclosing container the list of ingress ACLs on the
|
||||
interface";
|
||||
|
||||
list ingress-acl-set {
|
||||
key "set-name type";
|
||||
description
|
||||
"List of ingress ACLs on the interface";
|
||||
|
||||
leaf set-name {
|
||||
type leafref {
|
||||
path "../config/set-name";
|
||||
}
|
||||
description
|
||||
"Reference to set name list key";
|
||||
}
|
||||
|
||||
leaf type {
|
||||
type leafref {
|
||||
path "../config/type";
|
||||
}
|
||||
description
|
||||
"Reference to type list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data ";
|
||||
|
||||
uses interface-ingress-acl-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for interface ingress ACLs";
|
||||
|
||||
uses interface-ingress-acl-config;
|
||||
uses interface-ingress-acl-state;
|
||||
}
|
||||
|
||||
uses interface-acl-entries-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping interface-egress-acl-config {
|
||||
description
|
||||
"Configuration data for per-interface egress ACLs";
|
||||
|
||||
leaf set-name {
|
||||
type leafref {
|
||||
path "../../../../../../acl-sets/acl-set/config/name";
|
||||
}
|
||||
description
|
||||
"Reference to the ACL set name applied on egress";
|
||||
}
|
||||
|
||||
leaf type {
|
||||
type leafref {
|
||||
path "../../../../../../acl-sets/acl-set[name=current()/../set-name]" +
|
||||
"/config/type";
|
||||
}
|
||||
description
|
||||
"Reference to the ACL set type applied on egress.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping interface-egress-acl-state {
|
||||
description
|
||||
"Operational state data for the per-interface egress ACL";
|
||||
}
|
||||
|
||||
grouping interface-egress-acl-top {
|
||||
description
|
||||
"Top-level grouping for per-interface egress ACL data";
|
||||
|
||||
container egress-acl-sets {
|
||||
description
|
||||
"Enclosing container the list of egress ACLs on the
|
||||
interface";
|
||||
|
||||
list egress-acl-set {
|
||||
key "set-name type";
|
||||
description
|
||||
"List of egress ACLs on the interface";
|
||||
|
||||
leaf set-name {
|
||||
type leafref {
|
||||
path "../config/set-name";
|
||||
}
|
||||
description
|
||||
"Reference to set name list key";
|
||||
}
|
||||
|
||||
leaf type {
|
||||
type leafref {
|
||||
path "../config/type";
|
||||
}
|
||||
description
|
||||
"Reference to type list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data ";
|
||||
|
||||
uses interface-egress-acl-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for interface egress ACLs";
|
||||
|
||||
uses interface-egress-acl-config;
|
||||
uses interface-egress-acl-state;
|
||||
}
|
||||
|
||||
uses interface-acl-entries-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping acl-interfaces-config {
|
||||
description
|
||||
"Configuration data for interface references";
|
||||
|
||||
leaf id {
|
||||
type oc-if:interface-id;
|
||||
description
|
||||
"User-defined identifier for the interface -- a common
|
||||
convention could be '<if name>.<subif index>'";
|
||||
}
|
||||
}
|
||||
|
||||
grouping acl-interfaces-state {
|
||||
description
|
||||
"Operational state data for interface references";
|
||||
}
|
||||
|
||||
grouping acl-interfaces-top {
|
||||
description
|
||||
"Top-level grouping for interface-specific ACL data";
|
||||
|
||||
container interfaces {
|
||||
description
|
||||
"Enclosing container for the list of interfaces on which
|
||||
ACLs are set";
|
||||
|
||||
list interface {
|
||||
key "id";
|
||||
description
|
||||
"List of interfaces on which ACLs are set. The interface is resolved
|
||||
based on the interface and subinterface leaves of the interface-ref
|
||||
container, which are references to entries in the /interfaces
|
||||
list. The key of the list is an arbitrary value that the
|
||||
implementation should not use to resolve an interface name.";
|
||||
|
||||
leaf id {
|
||||
type leafref {
|
||||
path "../config/id";
|
||||
}
|
||||
description
|
||||
"Reference to the interface id list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration for ACL per-interface data";
|
||||
|
||||
uses acl-interfaces-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state for ACL per-interface data";
|
||||
|
||||
uses acl-interfaces-config;
|
||||
uses acl-interfaces-state;
|
||||
}
|
||||
|
||||
uses oc-if:interface-ref;
|
||||
uses interface-ingress-acl-top;
|
||||
uses interface-egress-acl-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
grouping acl-config {
|
||||
description
|
||||
"Global configuration data for ACLs";
|
||||
}
|
||||
|
||||
grouping acl-state {
|
||||
description
|
||||
"Global operational state data for ACLs";
|
||||
|
||||
leaf counter-capability {
|
||||
type identityref {
|
||||
base ACL_COUNTER_CAPABILITY;
|
||||
}
|
||||
description
|
||||
"System reported indication of how ACL counters are reported
|
||||
by the target";
|
||||
}
|
||||
}
|
||||
grouping acl-top {
|
||||
description
|
||||
"Top level grouping for ACL data and structure";
|
||||
|
||||
container acl {
|
||||
description
|
||||
"Top level enclosing container for ACL model config
|
||||
and operational state data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Global config data for ACLs";
|
||||
|
||||
uses acl-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Global operational state data for ACLs";
|
||||
|
||||
uses acl-config;
|
||||
uses acl-state;
|
||||
}
|
||||
|
||||
uses acl-set-top;
|
||||
uses acl-interfaces-top;
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
uses acl-top;
|
||||
|
||||
// augment statements
|
||||
|
||||
|
||||
}
|
||||
855
Parseurs_logs_Switch/src/modèles/openconfig-bfd.yang
Normal file
855
Parseurs_logs_Switch/src/modèles/openconfig-bfd.yang
Normal file
@@ -0,0 +1,855 @@
|
||||
module openconfig-bfd {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/bfd";
|
||||
|
||||
prefix "oc-bfd";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix "oc-ext"; }
|
||||
import openconfig-types { prefix "oc-types"; }
|
||||
import openconfig-interfaces { prefix "oc-if"; }
|
||||
import openconfig-inet-types { prefix "oc-inet"; }
|
||||
import openconfig-policy-types { prefix "oc-pol-types"; }
|
||||
import ietf-inet-types { prefix "ietf-if"; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"An OpenConfig model of Bi-Directional Forwarding Detection (BFD)
|
||||
configuration and operational state.";
|
||||
|
||||
oc-ext:openconfig-version "0.5.0";
|
||||
|
||||
revision "2025-09-03" {
|
||||
description
|
||||
"Add desired-min-echo-tx-interval and required-min-echo-rx-interval
|
||||
leaves in bfd-interface-config to allow RFC 9127-compliant BFD echo
|
||||
mode configuration per interface.";
|
||||
reference "0.5.0";
|
||||
}
|
||||
|
||||
revision "2025-03-18" {
|
||||
description
|
||||
"Clarify BFD session failure as a transition
|
||||
from the UP state to the DOWN state. This does not include
|
||||
UP to ADMIN_DOWN transitions, since when the BFD session is
|
||||
administratively disabled it is not a session failure.";
|
||||
reference "0.4.1";
|
||||
}
|
||||
|
||||
revision "2025-02-05" {
|
||||
description
|
||||
"Move the up-transitions leaf from the async and echo
|
||||
sub-containers into the state container.";
|
||||
reference "0.4.0";
|
||||
}
|
||||
|
||||
revision "2024-12-16" {
|
||||
description
|
||||
"Add Bfd diagnostic code for when
|
||||
neighbor signaled session down. Specified in RFC5880.";
|
||||
reference "0.3.1";
|
||||
}
|
||||
|
||||
revision "2024-03-05" {
|
||||
description
|
||||
"Add configuration of min interval, multiplier when
|
||||
BFD is enabled at protocol level";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2023-08-09" {
|
||||
description
|
||||
"Update interface key to use interface-id type";
|
||||
reference "0.2.6";
|
||||
}
|
||||
|
||||
revision "2023-02-06" {
|
||||
description
|
||||
"Clarify interface references.";
|
||||
reference "0.2.5";
|
||||
}
|
||||
|
||||
revision "2022-06-28" {
|
||||
description
|
||||
"Remove reference to invalid oc-ift type check";
|
||||
reference "0.2.4";
|
||||
}
|
||||
|
||||
revision "2021-06-16" {
|
||||
description
|
||||
"Remove trailing whitespace";
|
||||
reference "0.2.3";
|
||||
}
|
||||
|
||||
revision "2021-03-17" {
|
||||
description
|
||||
"Remove augments from bfd module.
|
||||
Add bfd support directly on the protocols";
|
||||
reference "0.2.2";
|
||||
}
|
||||
|
||||
revision "2020-05-08" {
|
||||
description
|
||||
"Ensure that when statements reference only read-write leaves
|
||||
from read-write contexts.
|
||||
Add ietf-inet-types LAG type to conditions for micro-bfd.";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2019-10-25" {
|
||||
description
|
||||
"Correct when statements.";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2019-06-02" {
|
||||
description
|
||||
"Fix detection multiplier to be 8-bit value";
|
||||
reference "0.1.1";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
revision "2017-10-19" {
|
||||
description
|
||||
"Adopt OpenConfig types models, type corrections";
|
||||
reference "0.0.2";
|
||||
}
|
||||
|
||||
revision "2016-06-24" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.0.1";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
typedef bfd-session-state {
|
||||
type enumeration {
|
||||
enum UP {
|
||||
description
|
||||
"The BFD session is perceived to be up by the system.";
|
||||
}
|
||||
enum DOWN {
|
||||
description
|
||||
"The BFD session is perceived to be down by the system.";
|
||||
}
|
||||
enum ADMIN_DOWN {
|
||||
description
|
||||
"The BFD session is administratively disabled.";
|
||||
}
|
||||
enum INIT {
|
||||
description
|
||||
"The BFD session is perceived to be initialising by the
|
||||
system.";
|
||||
}
|
||||
}
|
||||
description
|
||||
"The state of the BFD session according to the system referred
|
||||
to by the context of the leaf.";
|
||||
reference
|
||||
"RFC5880 - Bidirectional Forwarding Detection, Section
|
||||
4.1";
|
||||
}
|
||||
|
||||
typedef bfd-diagnostic-code {
|
||||
type enumeration {
|
||||
enum NO_DIAGNOSTIC {
|
||||
value 0;
|
||||
description
|
||||
"No diagnostic code was specified, or the session has not
|
||||
changed state.";
|
||||
}
|
||||
enum DETECTION_TIMEOUT {
|
||||
value 1;
|
||||
description
|
||||
"The control detection time expired: no BFD packet was
|
||||
received within the required period.";
|
||||
}
|
||||
enum ECHO_FAILED {
|
||||
value 2;
|
||||
description
|
||||
"The BFD echo function failed - echo packets have not been
|
||||
received for the required period of time.";
|
||||
}
|
||||
enum FORWARDING_RESET {
|
||||
value 3;
|
||||
description
|
||||
"The forwarding plane in the local system was reset - such
|
||||
that the remote system cannot rely on the forwarding state of
|
||||
the device specifying this error code.";
|
||||
}
|
||||
enum PATH_DOWN {
|
||||
value 4;
|
||||
description
|
||||
"Signalling outside of BFD specified that the path underlying
|
||||
this session has failed.";
|
||||
}
|
||||
enum CONCATENATED_PATH_DOWN {
|
||||
value 5;
|
||||
description
|
||||
"When a BFD session runs over a series of path segments, this
|
||||
error code indicates that a subsequent path segment (i.e.,
|
||||
one in the transmit path between the source and destination
|
||||
of the session) has failed.";
|
||||
}
|
||||
enum ADMIN_DOWN {
|
||||
value 6;
|
||||
description
|
||||
"The BFD session has been administratively disabled by the
|
||||
peer.";
|
||||
}
|
||||
enum REVERSE_CONCATENATED_PATH_DOWN {
|
||||
value 7;
|
||||
description
|
||||
"In the case that a BFD session is running over a series of
|
||||
path segments, this error code indicates that a path segment
|
||||
on the reverse path (i.e., in the transmit direction from the
|
||||
destination to the source of the session) has failed.";
|
||||
}
|
||||
enum NEIGHBOR_DOWN {
|
||||
value 8;
|
||||
description
|
||||
"The Bfd neighbor signaled session down - Bfd packet was received with
|
||||
neighbor state down.";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Diagnostic codes defined by BFD. These typically indicate the
|
||||
reason for a change of session state. The NEIGHBOR_DOWN diagnostic
|
||||
was added to the enum at value 8 to avoid making a breaking change.
|
||||
This deviates from RFC5880 where the enum is value 3. This also
|
||||
shifts the following values by 1, in relation to RFC5880:
|
||||
FORWARDING_RESET, PATH_DOWN, CONCATENATED_PATH_DOWN,
|
||||
ADMIN_DOWN, REVERSE_CONCATENATED_PATH_DOWN.";
|
||||
reference
|
||||
"RFC5880 - Bidirectional Forwarding Detection, Section
|
||||
4.1";
|
||||
}
|
||||
|
||||
|
||||
grouping bfd-interface-config {
|
||||
description
|
||||
"Top-level per-interface configuration parameters for BFD.";
|
||||
|
||||
leaf id {
|
||||
type oc-if:interface-id;
|
||||
description
|
||||
"A unique identifier for the interface.";
|
||||
}
|
||||
|
||||
leaf enabled {
|
||||
type boolean;
|
||||
description
|
||||
"When this leaf is set to true then the BFD session is enabled
|
||||
on the specified interface - if it is set to false, it is
|
||||
administratively disabled.";
|
||||
}
|
||||
|
||||
leaf local-address {
|
||||
type oc-inet:ip-address;
|
||||
description
|
||||
"The source IP address to be used for BFD sessions over this
|
||||
interface.";
|
||||
}
|
||||
|
||||
uses bfd-configuration;
|
||||
|
||||
leaf enable-per-member-link {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"When this leaf is set to true - BFD will be enabled on
|
||||
each member interface of the aggregated Ethernet bundle.";
|
||||
}
|
||||
|
||||
leaf desired-min-echo-tx-interval {
|
||||
type uint32;
|
||||
units microseconds;
|
||||
description
|
||||
"The minimum interval between transmission of BFD echo
|
||||
packets that the operator desires. This value controls the
|
||||
transmission rate of echo packets sent by the local system.
|
||||
Setting this value to 0 disables BFD echo mode on this
|
||||
interface. This value is specified as an integer number
|
||||
of microseconds.";
|
||||
reference "RFC 9127, Appendix A.1";
|
||||
}
|
||||
|
||||
leaf required-min-echo-rx-interval {
|
||||
type uint32;
|
||||
units microseconds;
|
||||
description
|
||||
"The minimum interval between received BFD echo packets that
|
||||
this system should support. This value is advertised to the
|
||||
remote peer and allows the peer to opt-out of echo mode or
|
||||
specify receive capabilities. Setting this value to 0 indicates
|
||||
that the local system does not support receiving echo packets.
|
||||
This value is specified as an integer number of microseconds.";
|
||||
reference "RFC 9127, Appendix A.1";
|
||||
}
|
||||
}
|
||||
|
||||
grouping bfd-interface-state {
|
||||
// placeholder
|
||||
description
|
||||
"Operational state parameters relating to BFD running on an
|
||||
interface.";
|
||||
}
|
||||
|
||||
grouping bfd-session-state-mode-timers-common {
|
||||
description
|
||||
"Common operational state parameters that are re-used across
|
||||
both asynchronous and echo modes of BFD.";
|
||||
|
||||
leaf last-packet-transmitted {
|
||||
type uint64;
|
||||
description
|
||||
"The date and time at which the last BFD packet
|
||||
was transmitted for this session, expressed as the number
|
||||
of nanoseconds since the Unix Epoch (January 1, 1970,
|
||||
00:00 UTC).";
|
||||
}
|
||||
|
||||
leaf last-packet-received {
|
||||
type uint64;
|
||||
description
|
||||
"The date and time at which the last BFD packet
|
||||
was received for this session, expressed as the number
|
||||
of nanoseconds since the Unix Epoch (January 1, 1970,
|
||||
00:00 UTC).";
|
||||
}
|
||||
|
||||
leaf transmitted-packets {
|
||||
type uint64;
|
||||
description
|
||||
"The number of packets that have been transmitted
|
||||
by the local system.";
|
||||
}
|
||||
|
||||
leaf received-packets {
|
||||
// TODO: looks to be unsupported on JUNOS
|
||||
type uint64;
|
||||
description
|
||||
"The number of packets that have been received by the
|
||||
local system from the remote neighbour.";
|
||||
}
|
||||
|
||||
leaf up-transitions {
|
||||
status deprecated;
|
||||
type uint64;
|
||||
description
|
||||
"The number of times that the adjacency with the neighbor
|
||||
has transitioned into the up state.
|
||||
|
||||
This leaf is deprecated and will be replaced by a single
|
||||
up-transitions leaf in state container. New path:
|
||||
/bfd/interfaces/interface/peers/peer/state/up-transitions.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping bfd-session-state-sessiondetails-common {
|
||||
description
|
||||
"Common session details for a BFD session.";
|
||||
|
||||
leaf session-state {
|
||||
type bfd-session-state;
|
||||
description
|
||||
"The state of the BFD session perceived by the local system.";
|
||||
|
||||
}
|
||||
|
||||
leaf remote-session-state {
|
||||
type bfd-session-state;
|
||||
description
|
||||
"The reported state of the BFD session according to the remote
|
||||
system. This state reflects the last state reported in a BFD
|
||||
control packet.";
|
||||
}
|
||||
|
||||
leaf last-failure-time {
|
||||
type oc-types:timeticks64;
|
||||
description
|
||||
"The time of the last transition of the BFD session from the UP state
|
||||
to the DOWN state, expressed as the number of nanoseconds since
|
||||
the Unix epoch. This does not include UP to ADMIN_DOWN transitions";
|
||||
}
|
||||
|
||||
leaf failure-transitions {
|
||||
type uint64;
|
||||
description
|
||||
"The number of times that the BFD session has transitioned
|
||||
from the UP state to the DOWN state. This does not include
|
||||
UP to ADMIN_DOWN transitions";
|
||||
}
|
||||
|
||||
leaf up-transitions {
|
||||
// TODO: looks to only be supported in SROS
|
||||
type uint64;
|
||||
description
|
||||
"The number of times that the adjacency with the neighbor
|
||||
has transitioned into the up state.";
|
||||
}
|
||||
|
||||
leaf local-discriminator {
|
||||
type string;
|
||||
description
|
||||
"A unique identifier used by the local system to identify this
|
||||
BFD session.";
|
||||
}
|
||||
|
||||
leaf remote-discriminator {
|
||||
type string;
|
||||
description
|
||||
"A unique identified used by the remote system to identify this
|
||||
BFD session.";
|
||||
}
|
||||
|
||||
leaf local-diagnostic-code {
|
||||
type bfd-diagnostic-code;
|
||||
description
|
||||
"The local BFD diagnostic code indicating the most recent
|
||||
reason for failure of this BFD session.";
|
||||
}
|
||||
|
||||
leaf remote-diagnostic-code {
|
||||
type bfd-diagnostic-code;
|
||||
description
|
||||
"The remote BFD diagnostic code indicating the remote system's
|
||||
reason for failure of the BFD session";
|
||||
}
|
||||
|
||||
leaf remote-minimum-receive-interval {
|
||||
type uint32;
|
||||
description
|
||||
"The value of the minimum receive interval that was specified
|
||||
in the most recent BFD control packet received from the peer.";
|
||||
}
|
||||
|
||||
leaf demand-mode-requested {
|
||||
type boolean;
|
||||
description
|
||||
"This leaf is set to true when the remote system has requested
|
||||
demand mode be run for this session.";
|
||||
}
|
||||
|
||||
leaf remote-authentication-enabled {
|
||||
type boolean;
|
||||
description
|
||||
"This leaf is set to true when the remote system has specified
|
||||
that authentication is present for the BFD session.";
|
||||
}
|
||||
|
||||
leaf remote-control-plane-independent {
|
||||
type boolean;
|
||||
description
|
||||
"This leaf is set to true when the remote system has specified
|
||||
that the hardware implementing this BFD session is independent
|
||||
of the control plane's liveliness.";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
grouping bfd-session-state-async-common {
|
||||
description
|
||||
"Common parameters for asynchronous BFD sessions";
|
||||
|
||||
container async {
|
||||
description
|
||||
"Operational state parameters specifically relating to
|
||||
asynchronous mode of BFD.";
|
||||
|
||||
uses bfd-session-state-mode-timers-common;
|
||||
}
|
||||
}
|
||||
|
||||
grouping bfd-session-state-echo-common {
|
||||
description
|
||||
"Common parameters for echo-mode BFD sessions.";
|
||||
|
||||
container echo {
|
||||
description
|
||||
"Operational state parameters specifically relating to the
|
||||
echo mode of BFD.";
|
||||
|
||||
leaf active {
|
||||
type boolean;
|
||||
description
|
||||
"This leaf is set to true when echo mode is running between
|
||||
the local and remote system. When it is set to false, solely
|
||||
asynchronous mode is active.";
|
||||
}
|
||||
|
||||
uses bfd-session-state-mode-timers-common;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
grouping bfd-session-state-common {
|
||||
description
|
||||
"Common operational state parameters that may be re-used across
|
||||
multiple BFD session contexts.";
|
||||
|
||||
leaf local-address {
|
||||
type oc-inet:ip-address;
|
||||
description
|
||||
"The IP address used by the local system for this BFD session.";
|
||||
}
|
||||
|
||||
leaf remote-address {
|
||||
type oc-inet:ip-address;
|
||||
description
|
||||
"The IP address used by the remote system for this BFD session.";
|
||||
}
|
||||
|
||||
leaf-list subscribed-protocols {
|
||||
type identityref {
|
||||
base "oc-pol-types:INSTALL_PROTOCOL_TYPE";
|
||||
}
|
||||
description
|
||||
"Indicates the set of protocols that currently use
|
||||
this BFD session for liveliness detection.";
|
||||
}
|
||||
|
||||
uses bfd-session-state-sessiondetails-common;
|
||||
uses bfd-session-state-echo-common;
|
||||
uses bfd-session-state-async-common;
|
||||
}
|
||||
|
||||
grouping bfd-session-microbfd-common {
|
||||
description
|
||||
"BFD session parameters utilised only for micro-BFD sessions.";
|
||||
|
||||
uses bfd-session-state-sessiondetails-common;
|
||||
uses bfd-session-state-async-common;
|
||||
}
|
||||
|
||||
grouping bfd-interface-peer-state {
|
||||
description
|
||||
"Per-peer, per-interface operational state parameters for BFD.";
|
||||
|
||||
uses bfd-session-state-common;
|
||||
}
|
||||
|
||||
grouping bfd-interface-microbfd-config {
|
||||
description
|
||||
"Configuration parameters for a microBFD session on an
|
||||
interface.";
|
||||
|
||||
leaf local-address {
|
||||
type oc-inet:ip-address;
|
||||
description
|
||||
"The local IP address used by the system for the micro-BFD session
|
||||
specified.";
|
||||
}
|
||||
|
||||
leaf remote-address {
|
||||
type oc-inet:ip-address;
|
||||
description
|
||||
"The remote IP destination that should be used by the system for
|
||||
the micro-BFD session specified.";
|
||||
}
|
||||
|
||||
leaf member-interface {
|
||||
type leafref {
|
||||
path "/oc-if:interfaces/" +
|
||||
"oc-if:interface/oc-if:config/oc-if:name";
|
||||
}
|
||||
// rjs: Note that this does not restrict to only interfaces that
|
||||
// are part of the current LAG. An implementation should return
|
||||
// NOK if such an interface is specified.
|
||||
description
|
||||
"Reference to a member link of the aggregate interface being
|
||||
described.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping bfd-interface-microbfd-state {
|
||||
description
|
||||
"Operational state parameters relating to a micro-BFD session on
|
||||
an interface.";
|
||||
|
||||
uses bfd-session-microbfd-common;
|
||||
}
|
||||
|
||||
grouping bfd-interface-microbfd-structural {
|
||||
description
|
||||
"Structural grouping for micro-bfd configuration and state
|
||||
parameters.";
|
||||
|
||||
container micro-bfd-sessions {
|
||||
when "/oc-if:interfaces/oc-if:interface" +
|
||||
"[oc-if:name=current()/../interface-ref/config/interface]/" +
|
||||
"oc-if:config/oc-if:type = 'ietf-if:ieee8023adLag'" {
|
||||
description
|
||||
"Include per-member link BFD only when the type of
|
||||
interface is a link aggregate.";
|
||||
}
|
||||
|
||||
description
|
||||
"Parameters relating to micro-BFD sessions associated
|
||||
with the interface.";
|
||||
|
||||
list micro-bfd-session {
|
||||
key "member-interface";
|
||||
|
||||
description
|
||||
"This list contains configuration and state parameters
|
||||
relating to micro-BFD session.";
|
||||
reference
|
||||
"RFC7130 - Bidirectional Forwarding Detection (BFD)
|
||||
on Link Aggregation Group (LAG) Interfaces.";
|
||||
|
||||
|
||||
leaf member-interface {
|
||||
type leafref {
|
||||
path "../config/member-interface";
|
||||
}
|
||||
description
|
||||
"A reference to the member interface of the link
|
||||
aggregate.";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters for the micro-BFD session.";
|
||||
uses bfd-interface-microbfd-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters for the micro-BFD session.";
|
||||
uses bfd-interface-microbfd-config;
|
||||
uses bfd-interface-microbfd-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping bfd-interface-peer-structural {
|
||||
description
|
||||
"Structural grouping for BFD peers (in the context of an interface).";
|
||||
|
||||
container peers {
|
||||
description
|
||||
"Parameters relating to the BFD peers which are seen
|
||||
over this interface.";
|
||||
|
||||
list peer {
|
||||
key "local-discriminator";
|
||||
config false;
|
||||
|
||||
description
|
||||
"Parameters relating to the BFD peer specified by the
|
||||
remote address.";
|
||||
|
||||
leaf local-discriminator {
|
||||
type leafref {
|
||||
path "../state/local-discriminator";
|
||||
}
|
||||
description
|
||||
"The local discriminator, which is unique for the
|
||||
session on the system.";
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters for the BFD session.";
|
||||
|
||||
uses bfd-interface-peer-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping bfd-top {
|
||||
description
|
||||
"Structural grouping for Bidirectional Forwarding Detection (BFD).";
|
||||
|
||||
container bfd {
|
||||
description
|
||||
"Configuration and operational state parameters for BFD.";
|
||||
reference "RFC5880, RFC5881";
|
||||
|
||||
container interfaces {
|
||||
description
|
||||
"Interfaces on which BFD sessions are to be enabled.";
|
||||
|
||||
list interface {
|
||||
key "id";
|
||||
|
||||
description
|
||||
"Per-interface configuration and state parameters for BFD.
|
||||
The interface referenced is based on the interface and
|
||||
subinterface leaves within the interface-ref container -
|
||||
which reference an entry in the /interfaces/interface list -
|
||||
and should not rely on the value of the list key.";
|
||||
|
||||
leaf id {
|
||||
type leafref {
|
||||
path "../config/id";
|
||||
}
|
||||
description
|
||||
"A reference to an identifier for the interface on which
|
||||
BFD is enabled.";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters for BFD on the specified
|
||||
interface.";
|
||||
uses bfd-interface-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters for BFD on the specified
|
||||
interface.";
|
||||
uses bfd-interface-config;
|
||||
uses bfd-interface-state;
|
||||
}
|
||||
|
||||
uses oc-if:interface-ref;
|
||||
|
||||
uses bfd-interface-microbfd-structural;
|
||||
uses bfd-interface-peer-structural;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping enable-bfd-config {
|
||||
description
|
||||
"Configuration parameters relating to enabling BFD.";
|
||||
|
||||
leaf enabled {
|
||||
type boolean;
|
||||
description
|
||||
"When this leaf is set to true, BFD is used to detect the
|
||||
liveliness of the remote peer or next-hop.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping bfd-configuration {
|
||||
description
|
||||
"Configuration parameters of BFD when it is enabled in protocols.";
|
||||
leaf desired-minimum-tx-interval {
|
||||
type uint32;
|
||||
units microseconds;
|
||||
description
|
||||
"The minimum interval between transmission of BFD control
|
||||
packets that the operator desires. This value is advertised to
|
||||
the peer, however the actual interval used is specified by
|
||||
taking the maximum of desired-minimum-tx-interval and the
|
||||
value of the remote required-minimum-receive interval value.
|
||||
This value is specified as an integer number of microseconds.
|
||||
The value 0 is reserved and cannot be used.";
|
||||
reference "section 4.1 of RFC 5880";
|
||||
}
|
||||
|
||||
leaf required-minimum-receive {
|
||||
type uint32;
|
||||
units microseconds;
|
||||
description
|
||||
"The minimum interval between received BFD control packets that
|
||||
this system should support. This value is advertised to the
|
||||
remote peer to indicate the maximum frequency (i.e., minimum
|
||||
inter-packet interval) between BFD control packets that is
|
||||
acceptable to the local system.";
|
||||
reference "section 4.1 of RFC 5880";
|
||||
}
|
||||
|
||||
leaf detection-multiplier {
|
||||
type uint8 {
|
||||
range "1..max";
|
||||
}
|
||||
description
|
||||
"The number of packets that must be missed to declare this
|
||||
session as down. The detection interval for the BFD session
|
||||
is calculated by multiplying the value of the negotiated
|
||||
transmission interval by this value.";
|
||||
reference "section 4.1 of RFC 5880";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
grouping enable-bfd-state {
|
||||
description
|
||||
"Operational state parameters relating to enabling BFD.";
|
||||
|
||||
leaf associated-session {
|
||||
// TODO: this is a leafref to something unique, but seems
|
||||
// like it might be expensive for the NMS to find out since
|
||||
// it will need to cycle through all interfaces looking for
|
||||
// the associated local-discriminator.
|
||||
type leafref {
|
||||
path "/bfd/interfaces/interface/peers/peer/local-discriminator";
|
||||
}
|
||||
description
|
||||
"A reference to the BFD session that is tracking the liveliness
|
||||
of the remote entity.";
|
||||
}
|
||||
|
||||
//
|
||||
// A fix to the above is to have the following leaf to show which
|
||||
// interface is associated.
|
||||
//
|
||||
// leaf associated-interface {
|
||||
// type leafref {
|
||||
// path "/bfd/interfaces/interface/config/id";
|
||||
// }
|
||||
// }
|
||||
}
|
||||
|
||||
grouping bfd-enable {
|
||||
description
|
||||
"Grouping which can be included in a protocol wishing to enable
|
||||
BFD.";
|
||||
|
||||
container enable-bfd {
|
||||
description
|
||||
"Enable BFD for liveliness detection to the next-hop or
|
||||
neighbour.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to enabling BFD.";
|
||||
|
||||
uses enable-bfd-config;
|
||||
uses bfd-configuration;
|
||||
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters relating to enabing BFD.";
|
||||
|
||||
uses enable-bfd-config;
|
||||
uses bfd-configuration;
|
||||
//uses enable-bfd-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
uses bfd-top;
|
||||
}
|
||||
318
Parseurs_logs_Switch/src/modèles/openconfig-if-8021x.yang
Normal file
318
Parseurs_logs_Switch/src/modèles/openconfig-if-8021x.yang
Normal file
@@ -0,0 +1,318 @@
|
||||
module openconfig-if-8021x {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/interfaces/8021x";
|
||||
|
||||
prefix "oc-1x";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-yang-types { prefix oc-yang; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import openconfig-if-ethernet { prefix oc-eth; }
|
||||
import openconfig-vlan { prefix oc-vlan; }
|
||||
import openconfig-vlan-types { prefix oc-vlan-types; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
netopenconfig@googlegroups.com";
|
||||
|
||||
description
|
||||
"Model for managing 8021X. Augments the OpenConfig models for
|
||||
wired interfaces and wireless SSIDs for configuration and state.";
|
||||
|
||||
oc-ext:openconfig-version "0.0.1";
|
||||
|
||||
revision "2020-01-28" {
|
||||
description
|
||||
"Initial draft of model, including only the most common 802.1X
|
||||
configuration and state use-cases.";
|
||||
reference "0.0.1";
|
||||
}
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping vlan-map-config {
|
||||
description
|
||||
"Configuration data for mapping from VLAN name to VLAN id.";
|
||||
|
||||
leaf vlan-name {
|
||||
type string;
|
||||
mandatory true;
|
||||
description
|
||||
"The VLAN name to be mapped to the VLAN id.";
|
||||
}
|
||||
|
||||
leaf id {
|
||||
type oc-vlan-types:vlan-id;
|
||||
mandatory true;
|
||||
description
|
||||
"The VLAN id to be mapped to the VLAN name.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping dot1x-port-config {
|
||||
description
|
||||
"802.1X port-based configuration.";
|
||||
|
||||
leaf authenticate-port {
|
||||
type boolean;
|
||||
description
|
||||
"Enable 802.1X port control on an interface.";
|
||||
}
|
||||
|
||||
leaf host-mode {
|
||||
type enumeration {
|
||||
enum SINGLE_HOST {
|
||||
description
|
||||
"Only single supplicant can communicate through the port.
|
||||
If the supplicant logs off or the port state is changed,
|
||||
the port becomes unauthenticated.";
|
||||
}
|
||||
enum MULTI_HOST {
|
||||
description
|
||||
"Multiple hosts can communicate over a single port.
|
||||
Only the first supplicant is authenticated while
|
||||
subsequent hosts have network access without having to
|
||||
authenticate.";
|
||||
}
|
||||
enum MULTI_DOMAIN {
|
||||
description
|
||||
"Allows for authentication of multiple clients
|
||||
individually on one authenticator port.";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Allow for single or multiple hosts to communicate through
|
||||
an 802.1X controlled port.";
|
||||
}
|
||||
|
||||
leaf reauthenticate-interval {
|
||||
type uint16;
|
||||
units seconds;
|
||||
description
|
||||
"Enable periodic re-authentication of the device connected
|
||||
to this port. Setting a value of 0 disabled reauthentication
|
||||
on this port.";
|
||||
}
|
||||
|
||||
leaf retransmit-interval {
|
||||
type uint16;
|
||||
units seconds;
|
||||
description
|
||||
"How long the interface waits for a response from an
|
||||
EAPoL Start before restarting 802.1X authentication on the
|
||||
port.";
|
||||
}
|
||||
|
||||
leaf supplicant-timeout {
|
||||
type uint16;
|
||||
units seconds;
|
||||
description
|
||||
"Time to wait for a response from the supplicant before
|
||||
restarting the 802.1X authentication process.";
|
||||
}
|
||||
|
||||
leaf max-requests {
|
||||
type uint16;
|
||||
description
|
||||
"Maximum number of times an EAPoL request packet is retransmitted
|
||||
to the supplicant before the authentication session fails.";
|
||||
}
|
||||
|
||||
leaf server-fail-vlan {
|
||||
type union {
|
||||
type string;
|
||||
type oc-vlan-types:vlan-id;
|
||||
}
|
||||
description
|
||||
"If RADIUS is unresponsive, the supplicant shall be placed in
|
||||
this VLAN. If this VLAN is configured as a VLAN name, the
|
||||
vlan-map must be populated for the Authenticator to map this
|
||||
VLAN name to a VLAN id.";
|
||||
}
|
||||
|
||||
leaf auth-fail-vlan {
|
||||
type union {
|
||||
type string;
|
||||
type oc-vlan-types:vlan-id;
|
||||
}
|
||||
description
|
||||
"Upon failure to authenticate, the port is set to this VLAN.
|
||||
If this VLAN is a configured as a VLAN name, the vlan-map must
|
||||
be populated for the Authenticator to map this VLAN name to a
|
||||
VLAN id.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping vlan-map-top {
|
||||
description
|
||||
"Top-level grouping for vlan-map configuration and Operational
|
||||
state data.";
|
||||
|
||||
container dot1x-vlan-map {
|
||||
description
|
||||
"Enclosing container for mapping a VLAN name to VLAN id";
|
||||
|
||||
list vlan-name {
|
||||
key "vlan-name";
|
||||
description
|
||||
"A list of mappings from VLAN name to VLAN id.
|
||||
Entries in this list are utilized for DVA using a VLAN
|
||||
name; eg when RADIUS returns a VLAN name as the
|
||||
tunnel-private-group-id.";
|
||||
reference
|
||||
"RFC 2868: RADIUS Attributes for Tunnel Protocol Support";
|
||||
|
||||
leaf vlan-name {
|
||||
type leafref {
|
||||
path "../config/vlan-name";
|
||||
}
|
||||
description "References the configured VLAN name";
|
||||
}
|
||||
|
||||
container config {
|
||||
description "Configuration data for each configured VLAN
|
||||
name in the VLAN ID to VLAN name mapping";
|
||||
|
||||
uses vlan-map-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state data for each VLAN id
|
||||
to VLAN name mapping.";
|
||||
|
||||
uses vlan-map-config;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping dot1x-sessions-top {
|
||||
description
|
||||
"Top-level grouping for 802.1X sessions.";
|
||||
container authenticated-sessions {
|
||||
description
|
||||
"Top level container for authenticated sessions state data.";
|
||||
|
||||
list authenticated-session {
|
||||
key "mac";
|
||||
config false;
|
||||
description
|
||||
"The list of authenticated sessions on this device.";
|
||||
|
||||
leaf mac {
|
||||
type leafref {
|
||||
path "../state/mac";
|
||||
}
|
||||
description
|
||||
"Device MAC address.";
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Top level state container for 802.1X.";
|
||||
|
||||
leaf mac {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"Device MAC address.";
|
||||
}
|
||||
uses dot1x-sessions-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping dot1x-sessions-state {
|
||||
description
|
||||
"Grouping for 802.1X sessions State data.";
|
||||
|
||||
leaf session-id {
|
||||
type string;
|
||||
description
|
||||
"The locally-significant session id which this authenticated
|
||||
session applies to. Typically used for RADIUS accounting or
|
||||
other system level telemetry.";
|
||||
}
|
||||
|
||||
leaf status {
|
||||
type enumeration {
|
||||
enum AUTHENTICATED {
|
||||
description
|
||||
"The session has succesfully completed one of the authentication
|
||||
methods allowed on the port.";
|
||||
}
|
||||
enum AUTHENTICATING {
|
||||
description
|
||||
"The session is in the process of authenticating.";
|
||||
}
|
||||
enum FAILED_AUTHENTICATION {
|
||||
description
|
||||
"An authentication has been attempted for this session,
|
||||
and has failed.";
|
||||
}
|
||||
enum SUPPLICANT_TIMEOUT {
|
||||
description
|
||||
"An authentication has been attempted for this session,
|
||||
however the supplicant has not responded. This is likely
|
||||
due to the attached devices lack of 802.1X support.";
|
||||
}
|
||||
}
|
||||
description
|
||||
"The status of the 802.1X session for a device.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping dot1x-top {
|
||||
description
|
||||
"Top-level grouping for 802.1X configuration and operational
|
||||
state data.";
|
||||
|
||||
container dot1x {
|
||||
description
|
||||
"Top level container for 802.1X configuration and
|
||||
state data.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Top level configuration container for 802.1X.";
|
||||
|
||||
uses dot1x-port-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Top level state container for 802.1X.";
|
||||
|
||||
uses dot1x-port-config;
|
||||
}
|
||||
}
|
||||
uses dot1x-sessions-top;
|
||||
}
|
||||
|
||||
// Augment statements
|
||||
augment "/oc-if:interfaces/oc-if:interface/oc-eth:ethernet" {
|
||||
description
|
||||
"Adds 802.1X settings to individual Ethernet interfaces";
|
||||
|
||||
uses dot1x-top;
|
||||
}
|
||||
|
||||
augment "/oc-if:interfaces/oc-if:interface/oc-eth:ethernet/" +
|
||||
"oc-vlan:switched-vlan" {
|
||||
description
|
||||
"Adds vlan-map to switched-vlans.";
|
||||
|
||||
uses vlan-map-top;
|
||||
}
|
||||
}
|
||||
263
Parseurs_logs_Switch/src/modèles/openconfig-if-aggregate.yang
Normal file
263
Parseurs_logs_Switch/src/modèles/openconfig-if-aggregate.yang
Normal file
@@ -0,0 +1,263 @@
|
||||
module openconfig-if-aggregate {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/interfaces/aggregate";
|
||||
|
||||
prefix "oc-lag";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import openconfig-if-ethernet { prefix oc-eth; }
|
||||
import iana-if-type { prefix ianaift; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
netopenconfig@googlegroups.com";
|
||||
|
||||
description
|
||||
"Model for managing aggregated (aka bundle, LAG) interfaces.";
|
||||
|
||||
oc-ext:openconfig-version "2.4.6";
|
||||
|
||||
revision "2026-01-06" {
|
||||
description
|
||||
"Fix typo in description for min-links leaf.";
|
||||
reference "2.4.6";
|
||||
}
|
||||
|
||||
revision "2025-04-22" {
|
||||
description
|
||||
"Updated the definition of lag-speed leaf";
|
||||
reference "2.4.5";
|
||||
}
|
||||
|
||||
revision "2022-06-28" {
|
||||
description
|
||||
"Remove reference to invalid oc-ift type check";
|
||||
reference "2.4.4";
|
||||
}
|
||||
|
||||
revision "2020-05-01" {
|
||||
description
|
||||
"Update when statements to reference config nodes
|
||||
from config true elements.";
|
||||
reference "2.4.3";
|
||||
}
|
||||
|
||||
revision "2019-04-16" {
|
||||
description
|
||||
"Update import prefix for iana-if-type module";
|
||||
reference "2.4.2";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "2.3.2";
|
||||
}
|
||||
|
||||
revision "2018-03-23" {
|
||||
description
|
||||
"Fix/cleanup when statements in aggregates model.";
|
||||
reference "2.3.1";
|
||||
}
|
||||
|
||||
revision "2018-01-05" {
|
||||
description
|
||||
"Add logical loopback to interface.";
|
||||
reference "2.3.0";
|
||||
}
|
||||
|
||||
revision "2017-12-22" {
|
||||
description
|
||||
"Add IPv4 proxy ARP configuration.";
|
||||
reference "2.2.0";
|
||||
}
|
||||
|
||||
revision "2017-12-21" {
|
||||
description
|
||||
"Added IPv6 router advertisement configuration.";
|
||||
reference "2.1.0";
|
||||
}
|
||||
|
||||
revision "2017-07-14" {
|
||||
description
|
||||
"Added Ethernet/IP state data; Add dhcp-client;
|
||||
migrate to OpenConfig types modules; Removed or
|
||||
renamed opstate values";
|
||||
reference "2.0.0";
|
||||
}
|
||||
|
||||
revision "2016-12-22" {
|
||||
description
|
||||
"Fixes to Ethernet interfaces model";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// extension statements
|
||||
|
||||
// feature statements
|
||||
|
||||
// identity statements
|
||||
|
||||
// typedef statements
|
||||
|
||||
typedef aggregation-type {
|
||||
type enumeration {
|
||||
enum LACP {
|
||||
description "LAG managed by LACP";
|
||||
}
|
||||
enum STATIC {
|
||||
description "Statically configured bundle / LAG";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Type to define the lag-type, i.e., how the LAG is
|
||||
defined and managed";
|
||||
}
|
||||
|
||||
// grouping statements
|
||||
|
||||
|
||||
grouping aggregation-logical-config {
|
||||
description
|
||||
"Configuration data for aggregate interfaces";
|
||||
|
||||
|
||||
leaf lag-type {
|
||||
type aggregation-type;
|
||||
description
|
||||
"Sets the type of LAG, i.e., how it is
|
||||
configured / maintained";
|
||||
}
|
||||
|
||||
leaf min-links {
|
||||
type uint16;
|
||||
description
|
||||
"Specifies the minimum number of member
|
||||
interfaces that must be active for the aggregate interface
|
||||
to be available";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aggregation-logical-state {
|
||||
description
|
||||
"Operational state data for aggregate interfaces";
|
||||
|
||||
leaf lag-speed {
|
||||
type uint32;
|
||||
units Mbps;
|
||||
description
|
||||
"Reports the effective speed of the aggregate interface, calculated
|
||||
as the sum of the speeds of member interfaces that are
|
||||
active (operationally up), forwarding-viable and selected by the
|
||||
aggregation protocol (e.g., LACP) for active traffic distribution";
|
||||
}
|
||||
|
||||
leaf-list member {
|
||||
when "../../config/lag-type = 'STATIC'" {
|
||||
description
|
||||
"The simple list of member interfaces is active
|
||||
when the aggregate is statically configured";
|
||||
}
|
||||
type oc-if:base-interface-ref;
|
||||
description
|
||||
"List of current member interfaces for the aggregate,
|
||||
expressed as references to existing interfaces";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aggregation-logical-top {
|
||||
description "Top-level data definitions for LAGs";
|
||||
|
||||
container aggregation {
|
||||
|
||||
description
|
||||
"Options for logical interfaces representing
|
||||
aggregates";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration variables for logical aggregate /
|
||||
LAG interfaces";
|
||||
|
||||
uses aggregation-logical-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
description
|
||||
"Operational state variables for logical
|
||||
aggregate / LAG interfaces";
|
||||
|
||||
uses aggregation-logical-config;
|
||||
uses aggregation-logical-state;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping ethernet-if-aggregation-config {
|
||||
description
|
||||
"Adds configuration items for Ethernet interfaces
|
||||
belonging to a logical aggregate / LAG";
|
||||
|
||||
leaf aggregate-id {
|
||||
type leafref {
|
||||
path "/oc-if:interfaces/oc-if:interface/oc-if:name";
|
||||
}
|
||||
description
|
||||
"Specify the logical aggregate interface to which
|
||||
this interface belongs";
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
augment "/oc-if:interfaces/oc-if:interface" {
|
||||
|
||||
description "Adds LAG configuration to the interface module";
|
||||
|
||||
uses aggregation-logical-top {
|
||||
when "oc-if:config/oc-if:type = 'ianaift:ieee8023adLag'" {
|
||||
description
|
||||
"active when the interface is set to type LAG";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
augment "/oc-if:interfaces/oc-if:interface/oc-eth:ethernet/" +
|
||||
"oc-eth:config" {
|
||||
description
|
||||
"Adds LAG settings to individual Ethernet interfaces";
|
||||
|
||||
uses ethernet-if-aggregation-config;
|
||||
}
|
||||
|
||||
augment "/oc-if:interfaces/oc-if:interface/oc-eth:ethernet/" +
|
||||
"oc-eth:state" {
|
||||
description
|
||||
"Adds LAG settings to individual Ethernet interfaces";
|
||||
|
||||
uses ethernet-if-aggregation-config;
|
||||
}
|
||||
|
||||
// rpc statements
|
||||
|
||||
// notification statements
|
||||
|
||||
}
|
||||
117
Parseurs_logs_Switch/src/modèles/openconfig-if-ethernet-ext.yang
Normal file
117
Parseurs_logs_Switch/src/modèles/openconfig-if-ethernet-ext.yang
Normal file
@@ -0,0 +1,117 @@
|
||||
module openconfig-if-ethernet-ext {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/interfaces/ethernet-ext";
|
||||
|
||||
prefix "oc-eth-ext";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import openconfig-if-ethernet { prefix oc-eth; }
|
||||
import openconfig-yang-types { prefix oc-yang; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module adds extensions to the base ethernet configuration
|
||||
and operational state model to support additional use cases.";
|
||||
|
||||
oc-ext:openconfig-version "0.1.1";
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.1.1";
|
||||
}
|
||||
|
||||
revision "2018-07-10" {
|
||||
description
|
||||
"Initial version of Ethernet extensions module to add frame
|
||||
size distribution stats";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
grouping ethernet-in-frames-size-dist {
|
||||
description
|
||||
"Grouping for defining the size distribution of the frames
|
||||
received";
|
||||
|
||||
container in-distribution {
|
||||
description
|
||||
"The size distribution of the received frames.";
|
||||
|
||||
leaf in-frames-64-octets {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of packets (including bad packets) received that
|
||||
were 64 bytes in length (excluding framing bits but
|
||||
including FCS bytes).";
|
||||
}
|
||||
|
||||
leaf in-frames-65-127-octets {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of good and bad packets received that were
|
||||
between 65 and 127 bytes in length (excluding framing bits
|
||||
but including FCS bytes).";
|
||||
}
|
||||
|
||||
leaf in-frames-128-255-octets {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of good and bad packets received that were
|
||||
between 128 and 255 bytes in length inclusive
|
||||
(excluding framing bits but including FCS bytes).";
|
||||
}
|
||||
|
||||
leaf in-frames-256-511-octets {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of good and bad packets received that were
|
||||
between 256 and 511 bytes in length inclusive
|
||||
(excluding framing bits but including FCS bytes).";
|
||||
}
|
||||
|
||||
leaf in-frames-512-1023-octets {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of good and bad packets received that were
|
||||
between 512 and 1023 bytes in length inclusive
|
||||
(excluding framing bits but including FCS bytes).";
|
||||
}
|
||||
|
||||
leaf in-frames-1024-1518-octets {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of good and bad packets received that were
|
||||
between 1024 and 1518 bytes in length inclusive
|
||||
(excluding framing bits but including FCS bytes).";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// augment statements
|
||||
|
||||
augment "/oc-if:interfaces/oc-if:interface/oc-eth:ethernet/" +
|
||||
"oc-eth:state/oc-eth:counters" {
|
||||
description
|
||||
"Adds size distribution to the ethernet counters";
|
||||
|
||||
uses ethernet-in-frames-size-dist;
|
||||
}
|
||||
|
||||
}
|
||||
825
Parseurs_logs_Switch/src/modèles/openconfig-if-ethernet.yang
Normal file
825
Parseurs_logs_Switch/src/modèles/openconfig-if-ethernet.yang
Normal file
@@ -0,0 +1,825 @@
|
||||
module openconfig-if-ethernet {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/interfaces/ethernet";
|
||||
|
||||
prefix "oc-eth";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import iana-if-type { prefix ianaift; }
|
||||
import openconfig-yang-types { prefix oc-yang; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-transport-types { prefix oc-opt-types; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
netopenconfig@googlegroups.com";
|
||||
|
||||
description
|
||||
"Model for managing Ethernet interfaces -- augments the OpenConfig
|
||||
model for interface configuration and state.";
|
||||
|
||||
oc-ext:openconfig-version "2.17.0";
|
||||
|
||||
revision "2026-03-12" {
|
||||
description
|
||||
"Add ethernet FEC modes for 200g serdes";
|
||||
reference "2.17.0";
|
||||
}
|
||||
|
||||
revision "2025-11-20" {
|
||||
description
|
||||
"Add ethernet FEC statistics - fec-uncorrectable-blocks,
|
||||
fec-corrected-blocks and per-/post-FEC BER statics.
|
||||
Deprecate in-block-errors as it is ambigous.";
|
||||
reference "2.16.0";
|
||||
}
|
||||
|
||||
revision "2025-11-14" {
|
||||
description
|
||||
"Add SPEED_1600GB to list of speeds.";
|
||||
reference "2.15.0";
|
||||
}
|
||||
|
||||
revision "2024-09-17" {
|
||||
description
|
||||
"Refactor config/state nodes to account for physical ethernet vs.
|
||||
aggregate interface characteristics along with description updates
|
||||
to indicate applicability.";
|
||||
reference "2.14.0";
|
||||
}
|
||||
|
||||
revision "2023-03-10" {
|
||||
description
|
||||
"Allow Ethernet configuration parameters to be
|
||||
used for aggregate (LAG) interfaces.";
|
||||
reference "2.13.0";
|
||||
}
|
||||
|
||||
revision "2022-04-20" {
|
||||
description
|
||||
"Remove unused import";
|
||||
reference "2.12.2";
|
||||
}
|
||||
|
||||
revision "2021-07-20" {
|
||||
description
|
||||
"Fix typo in hardware MAC address description.";
|
||||
reference "2.12.1";
|
||||
}
|
||||
|
||||
revision "2021-07-07" {
|
||||
description
|
||||
"Add support for configuring fec-mode per interface.";
|
||||
reference "2.12.0";
|
||||
}
|
||||
|
||||
revision "2021-06-16" {
|
||||
description
|
||||
"Remove trailing whitespace.";
|
||||
reference "2.11.1";
|
||||
}
|
||||
|
||||
revision "2021-06-09" {
|
||||
description
|
||||
"Add support for standalone link training.";
|
||||
reference "2.11.0";
|
||||
}
|
||||
|
||||
revision "2021-05-17" {
|
||||
description
|
||||
"Add ethernet counters: in-carrier-errors,
|
||||
in-interrupted-tx, in-late-collision, in-mac-errors-rx,
|
||||
in-single-collision, in-symbol-error and out-mac-errors-tx";
|
||||
reference "2.10.0";
|
||||
}
|
||||
|
||||
revision "2021-03-30" {
|
||||
description
|
||||
"Add counter for drops due to oversized frames.";
|
||||
reference "2.9.0";
|
||||
}
|
||||
|
||||
revision "2020-05-06" {
|
||||
description
|
||||
"Minor formatting fix.";
|
||||
reference "2.8.1";
|
||||
}
|
||||
|
||||
revision "2020-05-06" {
|
||||
description
|
||||
"Add 200G, 400G, 600G and 800G Ethernet speeds.";
|
||||
reference "2.8.0";
|
||||
}
|
||||
|
||||
revision "2020-05-05" {
|
||||
description
|
||||
"Fix when statement checks to use rw paths when
|
||||
from a rw context.";
|
||||
reference "2.7.3";
|
||||
}
|
||||
|
||||
revision "2019-04-16" {
|
||||
description
|
||||
"Update import prefix for iana-if-type module";
|
||||
reference "2.7.2";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "2.6.2";
|
||||
}
|
||||
|
||||
revision "2018-09-04" {
|
||||
description
|
||||
"Remove in-crc-align-errors as it is a duplicate of
|
||||
in-crc-errors";
|
||||
reference "2.6.1";
|
||||
}
|
||||
|
||||
revision "2018-08-28" {
|
||||
description
|
||||
"Add Ethernet counter in-block-errors";
|
||||
reference "2.6.0";
|
||||
}
|
||||
|
||||
revision "2018-07-02" {
|
||||
description
|
||||
"Add new ethernet counters of in-undersize-frames,
|
||||
in-crc-align-errors and the distribution container";
|
||||
reference "2.5.0";
|
||||
}
|
||||
|
||||
revision "2018-04-10" {
|
||||
description
|
||||
"Add identities for 2.5 and 5 Gbps.";
|
||||
reference "2.4.0";
|
||||
}
|
||||
|
||||
revision "2018-01-05" {
|
||||
description
|
||||
"Add logical loopback to interface.";
|
||||
reference "2.3.0";
|
||||
}
|
||||
|
||||
revision "2017-12-21" {
|
||||
description
|
||||
"Added IPv6 router advertisement configuration.";
|
||||
reference "2.1.0";
|
||||
}
|
||||
|
||||
revision "2017-07-14" {
|
||||
description
|
||||
"Added Ethernet/IP state data; Add dhcp-client;
|
||||
migrate to OpenConfig types modules; Removed or
|
||||
renamed opstate values";
|
||||
reference "2.0.0";
|
||||
}
|
||||
|
||||
revision "2016-12-22" {
|
||||
description
|
||||
"Fixes to Ethernet interfaces model";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
identity INTERFACE_FEC {
|
||||
description
|
||||
"Base type to specify FEC modes that can be configured on the interface.
|
||||
These are FEC modes defined for applying to logical interfaces and their
|
||||
underlying electrical channels.";
|
||||
}
|
||||
|
||||
identity FEC_FC {
|
||||
base INTERFACE_FEC;
|
||||
description
|
||||
"Firecode is used for channels with NRZ modulation and speeds less than 100G.
|
||||
This FEC is designed to comply with the IEEE 802.3, Clause 74.";
|
||||
}
|
||||
|
||||
identity FEC_RS528 {
|
||||
base INTERFACE_FEC;
|
||||
description
|
||||
"RS528 is used for channels with NRZ modulation. This FEC is designed to
|
||||
comply with IEEE 802.3, Clause 91.";
|
||||
}
|
||||
|
||||
identity FEC_RS544 {
|
||||
base INTERFACE_FEC;
|
||||
description
|
||||
"RS544 is used for channels with PAM4 modulation.";
|
||||
}
|
||||
|
||||
identity FEC_RS544_LOW_LATENCY {
|
||||
base INTERFACE_FEC;
|
||||
description
|
||||
"RS544-low-latency is used for channels with PAM4 modulation for low latency.";
|
||||
}
|
||||
|
||||
identity FEC_RS544_2X_INTERLEAVE {
|
||||
base INTERFACE_FEC;
|
||||
description
|
||||
"RS544-2x-interleave is used for channels with PAM4 modulation.";
|
||||
}
|
||||
|
||||
identity FEC_RS544_2X_INTERLEAVE_CL172 {
|
||||
base INTERFACE_FEC;
|
||||
description
|
||||
"RS544-2x-interleave-cl172 is used for channels with PAM4 modulation with the IEEE 802.3df variant.";
|
||||
}
|
||||
|
||||
identity FEC_RS544_2X_INTERLEAVE_ETC {
|
||||
base INTERFACE_FEC;
|
||||
description
|
||||
"RS544-2x-interleave-etc is used for channels with PAM4 modulation with the ETC variant.";
|
||||
}
|
||||
|
||||
identity FEC_DISABLED {
|
||||
base INTERFACE_FEC;
|
||||
description
|
||||
"FEC is administratively disabled.";
|
||||
}
|
||||
|
||||
identity ETHERNET_SPEED {
|
||||
description "base type to specify available Ethernet link
|
||||
speeds";
|
||||
}
|
||||
|
||||
identity SPEED_10MB {
|
||||
base ETHERNET_SPEED;
|
||||
description "10 Mbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_100MB {
|
||||
base ETHERNET_SPEED;
|
||||
description "100 Mbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_1GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "1 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_2500MB {
|
||||
base ETHERNET_SPEED;
|
||||
description "2.5 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_5GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "5 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_10GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "10 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_25GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "25 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_40GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "40 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_50GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "50 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_100GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "100 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_200GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "200 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_400GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "400 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_600GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "600 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_800GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "800 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_1600GB {
|
||||
base ETHERNET_SPEED;
|
||||
description "1600 Gbps Ethernet";
|
||||
}
|
||||
|
||||
identity SPEED_UNKNOWN {
|
||||
base ETHERNET_SPEED;
|
||||
description
|
||||
"Interface speed is unknown. Systems may report
|
||||
speed UNKNOWN when an interface is down or unpopuplated (e.g.,
|
||||
pluggable not present).";
|
||||
}
|
||||
|
||||
// typedef statements
|
||||
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping ethernet-interface-config {
|
||||
description
|
||||
"Common interface configuration for physical ethernet + logical
|
||||
aggregate interfaces";
|
||||
|
||||
leaf mac-address {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"Assigns a MAC address to the Ethernet interface. If not
|
||||
specified, the corresponding operational state leaf is
|
||||
expected to show the system-assigned MAC address.";
|
||||
}
|
||||
|
||||
leaf enable-flow-control {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"Enable or disable flow control for this interface.
|
||||
Ethernet flow control is a mechanism by which a receiver
|
||||
may send PAUSE frames to a sender to stop transmission for
|
||||
a specified time.
|
||||
|
||||
This setting should override auto-negotiated flow control
|
||||
settings. If left unspecified, and auto-negotiate is TRUE,
|
||||
flow control mode is negotiated with the peer interface.";
|
||||
reference
|
||||
"IEEE 802.3x";
|
||||
}
|
||||
}
|
||||
|
||||
grouping physical-interface-config {
|
||||
description
|
||||
"Configuration specific to physical ethernet interfaces. Note
|
||||
that this grouping is to only apply when the interface `type` is
|
||||
set to 'ianaift:ethernetCsmacd'. This is not currently restricted
|
||||
by YANG language statements (must/when) due to uses of this module
|
||||
within other domains (e.g. wifi).";
|
||||
|
||||
leaf auto-negotiate {
|
||||
type boolean;
|
||||
default true;
|
||||
description
|
||||
"Set to TRUE to request the interface to auto-negotiate
|
||||
transmission parameters with its peer interface. When
|
||||
set to FALSE, the transmission parameters are specified
|
||||
manually.";
|
||||
reference
|
||||
"IEEE 802.3-2012 auto-negotiation transmission parameters";
|
||||
}
|
||||
|
||||
leaf standalone-link-training {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"Link training is automatic tuning of the SerDes transmit and
|
||||
receive parameters to ensure an optimal connection over copper
|
||||
links. It is normally run as part of the auto negotiation
|
||||
sequence as specified in IEEE 802.3 Clause 73.
|
||||
|
||||
Standalone link training is used when full auto negotiation is
|
||||
not desired on an Ethernet link but link training is needed.
|
||||
It is configured by setting the standalone-link-training leaf
|
||||
to TRUE and augo-negotiate leaf to FALSE.
|
||||
|
||||
Note: If auto-negotiate is true, then the value of standalone
|
||||
link training leaf will be ignored.";
|
||||
}
|
||||
|
||||
leaf duplex-mode {
|
||||
type enumeration {
|
||||
enum FULL {
|
||||
description "Full duplex mode";
|
||||
}
|
||||
enum HALF {
|
||||
description "Half duplex mode";
|
||||
}
|
||||
}
|
||||
description
|
||||
"When auto-negotiate is TRUE, this optionally sets the
|
||||
duplex mode that will be advertised to the peer. If
|
||||
unspecified, the interface should negotiate the duplex mode
|
||||
directly (typically full-duplex). When auto-negotiate is
|
||||
FALSE, this sets the duplex mode on the interface directly.";
|
||||
}
|
||||
|
||||
leaf port-speed {
|
||||
type identityref {
|
||||
base ETHERNET_SPEED;
|
||||
}
|
||||
description
|
||||
"When auto-negotiate is TRUE, this optionally sets the
|
||||
port-speed mode that will be advertised to the peer for
|
||||
negotiation. If unspecified, it is expected that the
|
||||
interface will select the highest speed available based on
|
||||
negotiation. When auto-negotiate is set to FALSE, sets the
|
||||
link speed to a fixed value -- supported values are defined
|
||||
by ETHERNET_SPEED identities";
|
||||
}
|
||||
|
||||
leaf fec-mode {
|
||||
type identityref {
|
||||
base INTERFACE_FEC;
|
||||
}
|
||||
description
|
||||
"The FEC mode applied to the physical channels associated with
|
||||
the interface.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping ethernet-interface-state-counters {
|
||||
description
|
||||
"Ethernet-specific counters and statistics";
|
||||
|
||||
// ingress counters
|
||||
|
||||
leaf fec-uncorrectable-blocks {
|
||||
type oc-yang:counter64;
|
||||
when "../../../config/fec-mode != 'FEC_DISABLED'" {
|
||||
description
|
||||
"Applicable if FEC is enabled.";
|
||||
}
|
||||
description
|
||||
"The number of block/codeword that were uncorrectable by
|
||||
the FEC;
|
||||
This is IEEE802.3 clause 119.3.3 (also IEEE802.3df clause
|
||||
172.3.3 for 800GE) FEC_uncorrected_cw_counter.";
|
||||
}
|
||||
|
||||
leaf fec-corrected-blocks {
|
||||
type oc-yang:counter64;
|
||||
when "../../../config/fec-mode != 'FEC_DISABLED'" {
|
||||
description
|
||||
"Applicable if FEC is enabled.";
|
||||
}
|
||||
description
|
||||
"The number of words/symbols that were corrected by
|
||||
the FEC;
|
||||
Applicable if fec-mode is not NONE.
|
||||
This is IEEE802.3 clause 119.3.2 (also IEEE802.3df clause
|
||||
172.3.2 for 800GE) FEC_corrected_cw_counter";
|
||||
}
|
||||
|
||||
leaf in-mac-control-frames {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"MAC layer control frames received on the interface";
|
||||
}
|
||||
|
||||
leaf in-mac-pause-frames {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"MAC layer PAUSE frames received on the interface";
|
||||
}
|
||||
|
||||
leaf in-oversize-frames {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The total number of frames received that were
|
||||
longer than 1518 octets (excluding framing bits,
|
||||
but including FCS octets) and were otherwise
|
||||
well formed.";
|
||||
}
|
||||
|
||||
leaf in-undersize-frames {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The total number of frames received that were
|
||||
less than 64 octets long (excluding framing bits,
|
||||
but including FCS octets) and were otherwise well
|
||||
formed.";
|
||||
reference
|
||||
"RFC 2819: Remote Network Monitoring MIB -
|
||||
etherStatsUndersizePkts";
|
||||
}
|
||||
|
||||
leaf in-jabber-frames {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of jabber frames received on the
|
||||
interface. Jabber frames are typically defined as oversize
|
||||
frames which also have a bad CRC. Implementations may use
|
||||
slightly different definitions of what constitutes a jabber
|
||||
frame. Often indicative of a NIC hardware problem.";
|
||||
}
|
||||
|
||||
leaf in-fragment-frames {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The total number of frames received that were less than
|
||||
64 octets in length (excluding framing bits but including
|
||||
FCS octets) and had either a bad Frame Check Sequence
|
||||
(FCS) with an integral number of octets (FCS Error) or a
|
||||
bad FCS with a non-integral number of octets (Alignment
|
||||
Error).";
|
||||
}
|
||||
|
||||
leaf in-8021q-frames {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of 802.1q tagged frames received on the interface";
|
||||
}
|
||||
|
||||
leaf in-crc-errors {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The total number of frames received that
|
||||
had a length (excluding framing bits, but
|
||||
including FCS octets) of between 64 and 1518
|
||||
octets, inclusive, but had either a bad
|
||||
Frame Check Sequence (FCS) with an integral
|
||||
number of octets (FCS Error) or a bad FCS with
|
||||
a non-integral number of octets (Alignment Error)";
|
||||
reference
|
||||
"RFC 2819: Remote Network Monitoring MIB -
|
||||
etherStatsCRCAlignErrors";
|
||||
}
|
||||
|
||||
leaf in-block-errors {
|
||||
status deprecated;
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of received errored blocks. Error detection codes
|
||||
are capable of detecting whether one or more errors have
|
||||
occurred in a given sequence of bits – the block. It is
|
||||
normally not possible to determine the exact number of errored
|
||||
bits within the block";
|
||||
}
|
||||
|
||||
leaf in-carrier-errors {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of received errored frames due to a carrier issue.
|
||||
The value refers to MIB counter for
|
||||
dot3StatsCarrierSenseErrors
|
||||
oid=1.3.6.1.2.1.10.7.2.1.11";
|
||||
reference
|
||||
"RFC 1643 Definitions of Managed
|
||||
Objects for the Ethernet-like Interface Types.";
|
||||
}
|
||||
|
||||
leaf in-interrupted-tx {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of received errored frames due to interrupted
|
||||
transmission issue. The value refers to MIB counter for
|
||||
dot3StatsDeferredTransmissions
|
||||
oid=1.3.6.1.2.1.10.7.2.1.7";
|
||||
reference
|
||||
"RFC 1643 Definitions of Managed
|
||||
Objects for the Ethernet-like Interface Types.";
|
||||
}
|
||||
|
||||
leaf in-late-collision {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of received errored frames due to late collision
|
||||
issue. The value refers to MIB counter for
|
||||
dot3StatsLateCollisions
|
||||
oid=1.3.6.1.2.1.10.7.2.1.8";
|
||||
reference
|
||||
"RFC 1643 Definitions of Managed
|
||||
Objects for the Ethernet-like Interface Types.";
|
||||
}
|
||||
|
||||
leaf in-mac-errors-rx {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of received errored frames due to MAC errors
|
||||
received. The value refers to MIB counter for
|
||||
dot3StatsInternalMacReceiveErrors
|
||||
oid=1.3.6.1.2.1.10.7.2.1.16";
|
||||
reference
|
||||
"RFC 1643 Definitions of Managed
|
||||
Objects for the Ethernet-like Interface Types.";
|
||||
}
|
||||
|
||||
leaf in-single-collision {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of received errored frames due to single collision
|
||||
issue. The value refers to MIB counter for
|
||||
dot3StatsSingleCollisionFrames
|
||||
oid=1.3.6.1.2.1.10.7.2.1.4";
|
||||
reference
|
||||
"RFC 1643 Definitions of Managed
|
||||
Objects for the Ethernet-like Interface Types.";
|
||||
}
|
||||
|
||||
leaf in-symbol-error {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of received errored frames due to symbol error.
|
||||
The value refers to MIB counter for
|
||||
in-symbol-error
|
||||
oid=1.3.6.1.2.1.10.7.2.1.18";
|
||||
reference
|
||||
"RFC 1643 Definitions of Managed
|
||||
Objects for the Ethernet-like Interface Types.";
|
||||
}
|
||||
|
||||
leaf in-maxsize-exceeded {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The total number frames received that are well-formed but
|
||||
dropped due to exceeding the maximum frame size on the interface
|
||||
(e.g., MTU or MRU)";
|
||||
}
|
||||
|
||||
// egress counters
|
||||
|
||||
leaf out-mac-control-frames {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"MAC layer control frames sent on the interface";
|
||||
}
|
||||
|
||||
leaf out-mac-pause-frames {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"MAC layer PAUSE frames sent on the interface";
|
||||
}
|
||||
|
||||
leaf out-8021q-frames {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of 802.1q tagged frames sent on the interface";
|
||||
}
|
||||
|
||||
leaf out-mac-errors-tx {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of sent errored frames due to MAC errors
|
||||
transmitted. The value refers to MIB counter for
|
||||
dot3StatsInternalMacTransmitErrors
|
||||
oid=1.3.6.1.2.1.10.7.2.1.10";
|
||||
reference
|
||||
"RFC 1643 Definitions of Managed
|
||||
Objects for the Ethernet-like Interface Types.";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
grouping physical-interface-state {
|
||||
description
|
||||
"Grouping for operational state specific to physical ethernet
|
||||
interfaces. Note that this grouping is to only apply when the
|
||||
interface `type` is set to 'ianaift:ethernetCsmacd'. This is not
|
||||
currently restricted by YANG language statements (must/when) due
|
||||
to uses of this module within other domains (e.g. wifi).";
|
||||
|
||||
leaf hw-mac-address {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"Represents the 'burned-in', or system-assigned, MAC
|
||||
address for the Ethernet interface.";
|
||||
}
|
||||
|
||||
leaf negotiated-duplex-mode {
|
||||
type enumeration {
|
||||
enum FULL {
|
||||
description "Full duplex mode";
|
||||
}
|
||||
enum HALF {
|
||||
description "Half duplex mode";
|
||||
}
|
||||
}
|
||||
description
|
||||
"When auto-negotiate is set to TRUE, and the interface has
|
||||
completed auto-negotiation with the remote peer, this value
|
||||
shows the duplex mode that has been negotiated.";
|
||||
}
|
||||
|
||||
leaf negotiated-port-speed {
|
||||
type identityref {
|
||||
base ETHERNET_SPEED;
|
||||
}
|
||||
description
|
||||
"When auto-negotiate is set to TRUE, and the interface has
|
||||
completed auto-negotiation with the remote peer, this value
|
||||
shows the interface speed that has been negotiated.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping ethernet-interface-state {
|
||||
description
|
||||
"Common state for physical ethernet and aggregate interfaces";
|
||||
|
||||
container counters {
|
||||
description "Ethernet interface counters";
|
||||
|
||||
uses ethernet-interface-state-counters;
|
||||
}
|
||||
container pre-fec-ber {
|
||||
description
|
||||
"Bit error rate before forward error correction -- computed
|
||||
value with 18 decimal precision. Note that decimal64
|
||||
supports values as small as i x 10^-18 where i is an
|
||||
integer. Values smaller than this should be reported as 0
|
||||
to inidicate error free or near error free performance.
|
||||
Values include the instantaneous, average, minimum, and
|
||||
maximum statistics. If avg/min/max statistics are not
|
||||
supported, the target is expected to just supply the
|
||||
instant value. Applicable id gec-mode is not NONE.";
|
||||
|
||||
uses oc-opt-types:avg-min-max-instant-stats-precision18-ber;
|
||||
}
|
||||
|
||||
container post-fec-ber {
|
||||
description
|
||||
"Bit error rate after forward error correction -- computed
|
||||
value with 18 decimal precision. Note that decimal64
|
||||
supports values as small as i x 10^-18 where i is an
|
||||
integer. Values smaller than this should be reported as 0
|
||||
to inidicate error free or near error free performance.
|
||||
Values include the instantaneous, average, minimum, and
|
||||
maximum statistics. If avg/min/max statistics are not
|
||||
supported, the target is expected to just supply the
|
||||
instant value. Applicable id gec-mode is not NONE.";
|
||||
|
||||
uses oc-opt-types:avg-min-max-instant-stats-precision18-ber;
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
grouping ethernet-top {
|
||||
description "top-level Ethernet config and state containers";
|
||||
|
||||
container ethernet {
|
||||
description
|
||||
"Top-level container for ethernet configuration
|
||||
and state";
|
||||
|
||||
container config {
|
||||
description "Configuration data for ethernet interfaces";
|
||||
|
||||
uses ethernet-interface-config;
|
||||
uses physical-interface-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
description "State variables for Ethernet interfaces";
|
||||
|
||||
uses ethernet-interface-config;
|
||||
uses physical-interface-config;
|
||||
uses physical-interface-state;
|
||||
uses ethernet-interface-state;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
// augment statements
|
||||
|
||||
augment "/oc-if:interfaces/oc-if:interface" {
|
||||
description "Adds addtional Ethernet-specific configuration to
|
||||
interfaces model";
|
||||
|
||||
uses ethernet-top {
|
||||
when "oc-if:config/oc-if:type = 'ianaift:ethernetCsmacd' or " +
|
||||
"oc-if:config/oc-if:type = 'ianaift:ieee8023adLag'" {
|
||||
description
|
||||
"Additional interface configuration parameters when
|
||||
the interface type is Ethernet, or the interface is an aggregate
|
||||
interface.";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// rpc statements
|
||||
|
||||
// notification statements
|
||||
|
||||
}
|
||||
179
Parseurs_logs_Switch/src/modèles/openconfig-if-ip-ext.yang
Normal file
179
Parseurs_logs_Switch/src/modèles/openconfig-if-ip-ext.yang
Normal file
@@ -0,0 +1,179 @@
|
||||
module openconfig-if-ip-ext {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/interfaces/ip-ext";
|
||||
|
||||
prefix "oc-ip-ext";
|
||||
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import openconfig-if-ip { prefix oc-ip; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module adds extensions to the base IP configuration and
|
||||
operational state model to support additional use cases.";
|
||||
|
||||
oc-ext:openconfig-version "2.3.1";
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "2.3.1";
|
||||
}
|
||||
|
||||
revision "2018-01-05" {
|
||||
description
|
||||
"Add logical loopback to interface.";
|
||||
reference "2.3.0";
|
||||
}
|
||||
|
||||
revision "2017-12-21" {
|
||||
description
|
||||
"Added IPv6 router advertisement configuration.";
|
||||
reference "2.1.0";
|
||||
}
|
||||
|
||||
revision "2017-07-14" {
|
||||
description
|
||||
"Added Ethernet/IP state data; Add dhcp-client;
|
||||
migrate to OpenConfig types modules; Removed or
|
||||
renamed opstate values";
|
||||
reference "2.0.0";
|
||||
}
|
||||
|
||||
revision "2016-12-22" {
|
||||
description
|
||||
"Fixes to Ethernet interfaces model";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping ipv6-autoconf-config {
|
||||
description
|
||||
"Configuration data for IPv6 address autoconfiguration";
|
||||
|
||||
leaf create-global-addresses {
|
||||
type boolean;
|
||||
default true;
|
||||
description
|
||||
"[adapted from IETF IP model RFC 7277]
|
||||
|
||||
If enabled, the host creates global addresses as
|
||||
described in RFC 4862.";
|
||||
reference
|
||||
"RFC 4862: IPv6 Stateless Address Autoconfiguration
|
||||
Section 5.5";
|
||||
}
|
||||
leaf create-temporary-addresses {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"[adapted from IETF IP model RFC 7277]
|
||||
|
||||
If enabled, the host creates temporary addresses as
|
||||
described in RFC 4941.";
|
||||
reference
|
||||
"RFC 4941: Privacy Extensions for Stateless Address
|
||||
Autoconfiguration in IPv6";
|
||||
}
|
||||
|
||||
leaf temporary-valid-lifetime {
|
||||
type uint32;
|
||||
units "seconds";
|
||||
default 604800;
|
||||
description
|
||||
"[adapted from IETF IP model RFC 7277]
|
||||
|
||||
The time period during which the temporary address
|
||||
is valid.";
|
||||
reference
|
||||
"RFC 4941: Privacy Extensions for Stateless Address
|
||||
Autoconfiguration in IPv6
|
||||
- TEMP_VALID_LIFETIME";
|
||||
}
|
||||
|
||||
leaf temporary-preferred-lifetime {
|
||||
type uint32;
|
||||
units "seconds";
|
||||
default 86400;
|
||||
description
|
||||
"[adapted from IETF IP model RFC 7277]
|
||||
|
||||
The time period during which the temporary address is
|
||||
preferred.";
|
||||
reference
|
||||
"RFC 4941: Privacy Extensions for Stateless Address
|
||||
Autoconfiguration in IPv6
|
||||
- TEMP_PREFERRED_LIFETIME";
|
||||
}
|
||||
}
|
||||
|
||||
grouping ipv6-autoconf-state {
|
||||
description
|
||||
"Operational state data for IPv6 address autoconfiguration";
|
||||
|
||||
//TODO: placeholder for additional opstate for IPv6 autoconf
|
||||
}
|
||||
|
||||
grouping ipv6-autoconf-top {
|
||||
description
|
||||
"Top-level grouping for IPv6 address autoconfiguration";
|
||||
|
||||
container autoconf {
|
||||
description
|
||||
"Top-level container for IPv6 autoconf";
|
||||
|
||||
container config {
|
||||
description
|
||||
"[adapted from IETF IP model RFC 7277]
|
||||
|
||||
Parameters to control the autoconfiguration of IPv6
|
||||
addresses, as described in RFC 4862.";
|
||||
reference
|
||||
"RFC 4862: IPv6 Stateless Address Autoconfiguration";
|
||||
|
||||
uses ipv6-autoconf-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data ";
|
||||
|
||||
uses ipv6-autoconf-config;
|
||||
uses ipv6-autoconf-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
augment "/oc-if:interfaces/oc-if:interface/oc-if:subinterfaces/" +
|
||||
"oc-if:subinterface/oc-ip:ipv6" {
|
||||
description
|
||||
"Adds address autoconfiguration to the base IP model";
|
||||
|
||||
uses ipv6-autoconf-top;
|
||||
}
|
||||
|
||||
}
|
||||
1874
Parseurs_logs_Switch/src/modèles/openconfig-if-ip.yang
Normal file
1874
Parseurs_logs_Switch/src/modèles/openconfig-if-ip.yang
Normal file
File diff suppressed because it is too large
Load Diff
1389
Parseurs_logs_Switch/src/modèles/openconfig-interfaces.yang
Normal file
1389
Parseurs_logs_Switch/src/modèles/openconfig-interfaces.yang
Normal file
File diff suppressed because it is too large
Load Diff
549
Parseurs_logs_Switch/src/modèles/openconfig-lacp.yang
Normal file
549
Parseurs_logs_Switch/src/modèles/openconfig-lacp.yang
Normal file
@@ -0,0 +1,549 @@
|
||||
module openconfig-lacp {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/lacp";
|
||||
|
||||
prefix "oc-lacp";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import openconfig-yang-types { prefix oc-yang; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-types { prefix oc-types; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module describes configuration and operational state
|
||||
data for Link Aggregation Control Protocol (LACP) for
|
||||
managing aggregate interfaces. It works in conjunction with
|
||||
the OpenConfig interfaces and aggregate interfaces models.";
|
||||
|
||||
oc-ext:openconfig-version "2.2.0";
|
||||
|
||||
revision "2026-04-09" {
|
||||
description
|
||||
"Add LACP fallback timeout leaf.";
|
||||
reference "2.2.0";
|
||||
}
|
||||
|
||||
|
||||
revision "2024-09-24" {
|
||||
description
|
||||
"Add LACP fallback leaf under both config and state.";
|
||||
reference "2.1.0";
|
||||
}
|
||||
|
||||
revision "2023-12-11" {
|
||||
description
|
||||
"Add config container for aggregation member and port-priority leaf under
|
||||
both config and state";
|
||||
reference "2.0.0";
|
||||
}
|
||||
|
||||
revision "2021-07-20" {
|
||||
description
|
||||
"Add count of number of timeouts and time of the last timeout.";
|
||||
reference "1.2.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "1.1.1";
|
||||
}
|
||||
|
||||
revision "2017-05-05" {
|
||||
description
|
||||
"Add member local and remote port num";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
revision "2016-05-26" {
|
||||
description
|
||||
"OpenConfig public release";
|
||||
reference "1.0.2";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// typedef statements
|
||||
|
||||
typedef lacp-activity-type {
|
||||
type enumeration {
|
||||
enum ACTIVE {
|
||||
description
|
||||
"Interface is an active member, i.e., will detect and
|
||||
maintain aggregates";
|
||||
}
|
||||
enum PASSIVE {
|
||||
description
|
||||
"Interface is a passive member, i.e., it participates
|
||||
with an active partner";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Describes the LACP membership type, active or passive, of the
|
||||
interface in the aggregate";
|
||||
reference "IEEE 802.1AX-2008";
|
||||
}
|
||||
|
||||
typedef lacp-timeout-type {
|
||||
type enumeration {
|
||||
enum LONG {
|
||||
description
|
||||
"Participant wishes to use long timeouts to detect
|
||||
status of the aggregate, i.e., will expect less frequent
|
||||
transmissions. Long timeout is 90 seconds.";
|
||||
}
|
||||
enum SHORT {
|
||||
description
|
||||
"Participant wishes to use short timeouts, i.e., expects
|
||||
frequent transmissions to aggressively detect status
|
||||
changes. Short timeout is 3 seconds.";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Type of timeout used, short or long, by LACP participants";
|
||||
reference "IEEE 802.1AX-2008";
|
||||
}
|
||||
|
||||
typedef lacp-synchronization-type {
|
||||
type enumeration {
|
||||
enum IN_SYNC {
|
||||
description
|
||||
"Participant is in sync with the system id and key
|
||||
transmitted";
|
||||
}
|
||||
enum OUT_SYNC {
|
||||
description
|
||||
"Participant is not in sync with the system id and key
|
||||
transmitted";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Indicates LACP synchronization state of participant";
|
||||
reference "IEEE 802.1AX-2008";
|
||||
}
|
||||
|
||||
typedef lacp-period-type {
|
||||
type enumeration {
|
||||
enum FAST {
|
||||
description "Send LACP packets every second";
|
||||
}
|
||||
enum SLOW {
|
||||
description "Send LACP packets every 30 seconds";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Defines the period options for the time between sending
|
||||
LACP messages";
|
||||
reference "IEEE 802.3ad";
|
||||
}
|
||||
|
||||
// grouping statements
|
||||
|
||||
|
||||
grouping aggregation-lacp-members-config {
|
||||
description
|
||||
"Configuration data for lacp member interfaces";
|
||||
|
||||
leaf interface {
|
||||
type oc-if:base-interface-ref;
|
||||
description
|
||||
"Reference to interface member of the LACP aggregate";
|
||||
}
|
||||
|
||||
leaf port-priority {
|
||||
type uint16;
|
||||
description
|
||||
"Member interface's priority in its aggregate interface.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aggregation-lacp-members-state {
|
||||
description
|
||||
"Operational status data for the member interfaces";
|
||||
|
||||
leaf activity {
|
||||
type lacp-activity-type;
|
||||
description "Indicates participant is active or passive";
|
||||
}
|
||||
|
||||
leaf timeout {
|
||||
type lacp-timeout-type;
|
||||
description
|
||||
"The timeout type (short or long) used by the
|
||||
participant";
|
||||
}
|
||||
|
||||
leaf synchronization {
|
||||
type lacp-synchronization-type;
|
||||
description
|
||||
"Indicates whether the participant is in-sync or
|
||||
out-of-sync";
|
||||
}
|
||||
|
||||
leaf aggregatable {
|
||||
type boolean;
|
||||
description
|
||||
"A true value indicates that the participant will allow
|
||||
the link to be used as part of the aggregate. A false
|
||||
value indicates the link should be used as an individual
|
||||
link";
|
||||
}
|
||||
|
||||
leaf collecting {
|
||||
type boolean;
|
||||
description
|
||||
"If true, the participant is collecting incoming frames
|
||||
on the link, otherwise false";
|
||||
}
|
||||
|
||||
leaf distributing {
|
||||
type boolean;
|
||||
description
|
||||
"When true, the participant is distributing outgoing
|
||||
frames; when false, distribution is disabled";
|
||||
}
|
||||
|
||||
leaf system-id {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"MAC address that defines the local system ID for the
|
||||
aggregate interface";
|
||||
}
|
||||
|
||||
leaf oper-key {
|
||||
type uint16;
|
||||
description
|
||||
"Current operational value of the key for the aggregate
|
||||
interface";
|
||||
}
|
||||
|
||||
leaf partner-id {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"MAC address representing the protocol partner's interface
|
||||
system ID";
|
||||
}
|
||||
|
||||
leaf partner-key {
|
||||
type uint16;
|
||||
description
|
||||
"Operational value of the protocol partner's key";
|
||||
}
|
||||
|
||||
leaf port-num {
|
||||
type uint16;
|
||||
description
|
||||
"Port number of the local (actor) aggregation member";
|
||||
}
|
||||
|
||||
leaf partner-port-num {
|
||||
type uint16;
|
||||
description
|
||||
"Port number of the partner (remote) port for this member
|
||||
port";
|
||||
}
|
||||
|
||||
leaf partner-port-priority {
|
||||
type uint16;
|
||||
description
|
||||
"Member interface partner's priority in its aggregate interface.";
|
||||
}
|
||||
|
||||
leaf last-change {
|
||||
type oc-types:timeticks64;
|
||||
description
|
||||
"The timestamp indicates the absolute time of the last state
|
||||
change of a LACP timeout. The last state change of the LACP
|
||||
timeout is defined as what is reported as the operating state
|
||||
to the system. The state change is both a timeout event and
|
||||
when the timeout event is no longer active. The value is the
|
||||
timestamp in nanoseconds relative to the Unix Epoch
|
||||
(Jan 1, 1970 00:00:00 UTC).";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aggregation-lacp-members-statistics {
|
||||
description
|
||||
"LACP packet statistics for the member interfaces";
|
||||
|
||||
container counters {
|
||||
description
|
||||
"LACP protocol counters";
|
||||
|
||||
leaf lacp-in-pkts {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of LACPDUs received";
|
||||
}
|
||||
|
||||
leaf lacp-out-pkts {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of LACPDUs transmitted";
|
||||
}
|
||||
|
||||
leaf lacp-rx-errors {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of LACPDU receive packet errors";
|
||||
}
|
||||
|
||||
leaf lacp-tx-errors {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of LACPDU transmit packet errors";
|
||||
}
|
||||
|
||||
leaf lacp-unknown-errors {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of LACPDU unknown packet errors";
|
||||
}
|
||||
|
||||
leaf lacp-errors {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of LACPDU illegal packet errors";
|
||||
}
|
||||
|
||||
leaf lacp-timeout-transitions {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"Number of times the LACP state has transitioned
|
||||
with a timeout since the time the device restarted
|
||||
or the interface was brought up, whichever is most
|
||||
recent. The last state change of the LACP timeout
|
||||
is defined as what is reported as the operating state
|
||||
to the system. The state change is both a timeout
|
||||
event and when the timeout event is no longer active.";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping aggregation-lacp-members-top {
|
||||
description
|
||||
"Top-level grouping for aggregate members list";
|
||||
|
||||
container members {
|
||||
description
|
||||
"Configuration and operational state of the aggregate member
|
||||
interfaces";
|
||||
|
||||
list member {
|
||||
key "interface";
|
||||
description
|
||||
"List of member interfaces and their associated status for
|
||||
a LACP-controlled aggregate interface";
|
||||
|
||||
leaf interface {
|
||||
type leafref {
|
||||
path "../config/interface";
|
||||
}
|
||||
description
|
||||
"Reference to aggregate member interface";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Operational state data for aggregate members";
|
||||
|
||||
uses aggregation-lacp-members-config;
|
||||
}
|
||||
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for aggregate members";
|
||||
|
||||
uses aggregation-lacp-members-config;
|
||||
uses aggregation-lacp-members-state;
|
||||
uses aggregation-lacp-members-statistics;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping lacp-interfaces-config {
|
||||
description
|
||||
"Configuration data for each LACP-enabled interface";
|
||||
|
||||
leaf name {
|
||||
type oc-if:base-interface-ref;
|
||||
description
|
||||
"Reference to the interface on which LACP should be
|
||||
configured. The type of the target interface must be
|
||||
ieee8023adLag";
|
||||
}
|
||||
|
||||
leaf interval {
|
||||
type lacp-period-type;
|
||||
default SLOW;
|
||||
description
|
||||
"Set the period between LACP messages -- uses
|
||||
the lacp-period-type enumeration.";
|
||||
}
|
||||
|
||||
leaf lacp-mode {
|
||||
type lacp-activity-type;
|
||||
default ACTIVE;
|
||||
description
|
||||
"ACTIVE is to initiate the transmission of LACP packets.
|
||||
PASSIVE is to wait for peer to initiate the transmission of
|
||||
LACP packets.";
|
||||
//TODO:some implementations configure the LACP mode on each
|
||||
//member interface rather than on the LAG interface. There
|
||||
//may be use cases for this identified at a later time.
|
||||
}
|
||||
|
||||
leaf system-id-mac {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"The MAC address portion of the node's System ID. This is
|
||||
combined with the system priority to construct the 8-octet
|
||||
system-id";
|
||||
}
|
||||
|
||||
leaf fallback {
|
||||
type boolean;
|
||||
description
|
||||
"If the fallback is set to true, current LACP interface is
|
||||
able to establish a Link Aggregation (LAG) before it receives
|
||||
LACP PDUs from its peer, and fallback to a single port active
|
||||
after the expiry of the timeout period.";
|
||||
}
|
||||
|
||||
leaf fallback-timeout {
|
||||
type uint16;
|
||||
units "seconds";
|
||||
description
|
||||
"The timeout in seconds to wait for LACP PDUs before falling back to a single port.";
|
||||
}
|
||||
|
||||
uses aggregation-lacp-global-config;
|
||||
}
|
||||
|
||||
grouping lacp-interfaces-state {
|
||||
description
|
||||
"Operational state data for each LACP-enabled interface";
|
||||
}
|
||||
|
||||
grouping lacp-interfaces-top {
|
||||
description
|
||||
"Top-level grouping for LACP-enabled interfaces";
|
||||
|
||||
container interfaces {
|
||||
description
|
||||
"Enclosing container for the list of LACP-enabled
|
||||
interfaces";
|
||||
|
||||
list interface {
|
||||
key "name";
|
||||
description
|
||||
"List of aggregate interfaces managed by LACP";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "../config/name";
|
||||
}
|
||||
description
|
||||
"Reference to the list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for each LACP aggregate interface";
|
||||
|
||||
uses lacp-interfaces-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for each LACP aggregate
|
||||
interface";
|
||||
|
||||
uses lacp-interfaces-config;
|
||||
uses lacp-interfaces-state;
|
||||
}
|
||||
|
||||
uses aggregation-lacp-members-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping aggregation-lacp-global-config {
|
||||
description
|
||||
"Configuration data for LACP aggregate interfaces";
|
||||
|
||||
|
||||
leaf system-priority {
|
||||
type uint16;
|
||||
description
|
||||
"Sytem priority used by the node on this LAG interface.
|
||||
Lower value is higher priority for determining which node
|
||||
is the controlling system.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping aggregation-lacp-global-state {
|
||||
description
|
||||
"Operational data for LACP aggregate interfaces";
|
||||
|
||||
}
|
||||
|
||||
grouping aggregation-lacp-top {
|
||||
description
|
||||
"Top level configuration and state variable containers for
|
||||
LACP data";
|
||||
|
||||
container lacp {
|
||||
description
|
||||
"Configuration and operational state data for LACP protocol
|
||||
operation on the aggregate interface";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for LACP";
|
||||
|
||||
uses aggregation-lacp-global-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
description
|
||||
"Operational state data for LACP";
|
||||
|
||||
uses aggregation-lacp-global-config;
|
||||
uses aggregation-lacp-global-state;
|
||||
}
|
||||
uses lacp-interfaces-top;
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
uses aggregation-lacp-top;
|
||||
|
||||
// augment statements
|
||||
|
||||
|
||||
}
|
||||
340
Parseurs_logs_Switch/src/modèles/openconfig-lldp-types.yang
Normal file
340
Parseurs_logs_Switch/src/modèles/openconfig-lldp-types.yang
Normal file
@@ -0,0 +1,340 @@
|
||||
module openconfig-lldp-types {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/lldp/types";
|
||||
|
||||
prefix "oc-lldp-types";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines types related to the LLDP protocol model.";
|
||||
|
||||
oc-ext:openconfig-version "0.2.0";
|
||||
|
||||
revision "2025-12-09" {
|
||||
description
|
||||
"Add Management interface numbering subtype typedef.";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.1.1";
|
||||
}
|
||||
|
||||
revision "2016-05-16" {
|
||||
description
|
||||
"Initial public revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
identity LLDP_SYSTEM_CAPABILITY {
|
||||
description
|
||||
"Base identity for standard LLDP system capabilities.
|
||||
The system capabilities field contains a bit-map of the
|
||||
capabilities that define the primary function(s) of
|
||||
the system. A system may advertise more than one capability.";
|
||||
reference
|
||||
"Table 8-4 System Capabilities, IEEE 802.1AB-2009";
|
||||
}
|
||||
|
||||
identity OTHER {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"Other capability not specified; bit position 1";
|
||||
}
|
||||
|
||||
identity REPEATER {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"Repeater capability; bit position 2";
|
||||
reference
|
||||
"IETF RFC 2108";
|
||||
}
|
||||
|
||||
identity MAC_BRIDGE {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"MAC bridge capability; bit position 3";
|
||||
reference
|
||||
"IEEE Std 802.1D";
|
||||
}
|
||||
|
||||
identity WLAN_ACCESS_POINT {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"WLAN access point capability; bit position 4";
|
||||
reference
|
||||
"IEEE Std 802.11 MIB";
|
||||
}
|
||||
|
||||
identity ROUTER {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"Router; bit position 5";
|
||||
reference
|
||||
"IETF RFC 1812";
|
||||
}
|
||||
|
||||
identity TELEPHONE {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"Telephone capability; bit position 6";
|
||||
reference
|
||||
"IETF RFC 4293";
|
||||
}
|
||||
|
||||
identity DOCSIS_CABLE_DEVICE {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"DOCSIS cable device; bit position 7";
|
||||
reference
|
||||
"IETF RFC 4639 and IETF RFC 4546";
|
||||
}
|
||||
|
||||
identity STATION_ONLY {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"Station only capability, for devices that implement only an
|
||||
end station capability, and for which none of the other
|
||||
capabilities apply; bit position 8";
|
||||
reference
|
||||
"IETF RFC 4293";
|
||||
}
|
||||
|
||||
identity C_VLAN {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"C-VLAN component of a VLAN Bridge; bit position 9";
|
||||
reference
|
||||
"IEEE Std 802.1Q";
|
||||
}
|
||||
|
||||
identity S_VLAN {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"S-VLAN component of a VLAN Bridge; bit position 10";
|
||||
reference
|
||||
"IEEE Std 802.1Q";
|
||||
}
|
||||
|
||||
identity TWO_PORT_MAC_RELAY {
|
||||
base LLDP_SYSTEM_CAPABILITY;
|
||||
description
|
||||
"Two-port MAC Relay (TPMR) capability; bit position 11";
|
||||
reference
|
||||
"IEEE Std 802.1Q";
|
||||
}
|
||||
|
||||
identity LLDP_TLV {
|
||||
description
|
||||
"A base identity which describes the TLVs in LLDP";
|
||||
}
|
||||
|
||||
identity CHASSIS_ID {
|
||||
base LLDP_TLV;
|
||||
description
|
||||
"The chassis identifier of the device associated with
|
||||
the transmitting LLDP agent";
|
||||
reference "IEEE Std 802.1AB";
|
||||
}
|
||||
|
||||
identity PORT_ID {
|
||||
base LLDP_TLV;
|
||||
description
|
||||
"The port identifier associated with the interface
|
||||
on with the LLDP agent is transmitting";
|
||||
reference "IEEE Std 802.1AB";
|
||||
}
|
||||
|
||||
identity PORT_DESCRIPTION {
|
||||
base LLDP_TLV;
|
||||
description
|
||||
"The description of the port that is associated with
|
||||
the interface on which the LLDP agent is transmitting";
|
||||
reference "IEEE Std 802.1AB";
|
||||
}
|
||||
|
||||
identity SYSTEM_NAME {
|
||||
base LLDP_TLV;
|
||||
description
|
||||
"The assigned name (sysName or hostname) of the device
|
||||
which is transmitting the LLDP PDU";
|
||||
reference "IEEE Std 802.1AB";
|
||||
}
|
||||
|
||||
identity SYSTEM_DESCRIPTION {
|
||||
base LLDP_TLV;
|
||||
description
|
||||
"The description (sysDescr) of the device which is
|
||||
transmitting the LLDP PDU";
|
||||
reference "IEEE Std 802.1AB";
|
||||
}
|
||||
|
||||
identity SYSTEM_CAPABILITIES {
|
||||
base LLDP_TLV;
|
||||
description
|
||||
"The primary functions of the device transmitting the
|
||||
LLDP PDU and their administrative status";
|
||||
reference "IEEE Std 802.1AB";
|
||||
}
|
||||
|
||||
identity MANAGEMENT_ADDRESS {
|
||||
base LLDP_TLV;
|
||||
description
|
||||
"The address associated with the device transmitting the
|
||||
LLDP PDU which can be used for higher-layer network
|
||||
management";
|
||||
reference "IEEE Std 802.1AB";
|
||||
}
|
||||
|
||||
// typedef statements
|
||||
|
||||
typedef chassis-id-type {
|
||||
type enumeration {
|
||||
enum CHASSIS_COMPONENT {
|
||||
description
|
||||
"Chassis identifier based on the value of entPhysicalAlias
|
||||
object defined in IETF RFC 2737";
|
||||
}
|
||||
enum INTERFACE_ALIAS {
|
||||
description
|
||||
"Chassis identifier based on the value of ifAlias object
|
||||
defined in IETF RFC 2863";
|
||||
}
|
||||
enum PORT_COMPONENT {
|
||||
description
|
||||
"Chassis identifier based on the value of entPhysicalAlias
|
||||
object defined in IETF RFC 2737 for a port or backplane
|
||||
component";
|
||||
}
|
||||
enum MAC_ADDRESS {
|
||||
description
|
||||
"Chassis identifier based on the value of a unicast source
|
||||
address (encoded in network byte order and IEEE 802.3
|
||||
canonical bit order), of a port on the containing chassis
|
||||
as defined in IEEE Std 802-2001";
|
||||
}
|
||||
enum NETWORK_ADDRESS {
|
||||
description
|
||||
"Chassis identifier based on a network address,
|
||||
associated with a particular chassis. The encoded address
|
||||
is composed of two fields. The first field is a single
|
||||
octet, representing the IANA AddressFamilyNumbers value
|
||||
for the specific address type, and the second field is the
|
||||
network address value";
|
||||
}
|
||||
enum INTERFACE_NAME {
|
||||
description
|
||||
"Chassis identifier based on the name of the interface,
|
||||
e.g., the value of ifName object defined in IETF RFC 2863";
|
||||
}
|
||||
enum LOCAL {
|
||||
description
|
||||
"Chassis identifier based on a locally defined value";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Type definition with enumerations describing the source of
|
||||
the chassis identifier";
|
||||
reference
|
||||
"IEEE 802.1AB LLDP MIB";
|
||||
}
|
||||
|
||||
typedef port-id-type {
|
||||
type enumeration {
|
||||
enum INTERFACE_ALIAS {
|
||||
description
|
||||
"Chassis identifier based on the value of ifAlias object
|
||||
defined in IETF RFC 2863";
|
||||
}
|
||||
enum PORT_COMPONENT {
|
||||
description
|
||||
"Port identifier based on the value of entPhysicalAlias
|
||||
object defined in IETF RFC 2737 for a port component";
|
||||
}
|
||||
enum MAC_ADDRESS {
|
||||
description
|
||||
"Port identifier based on the value of a unicast source
|
||||
address (encoded in network byte order and IEEE 802.3
|
||||
canonical bit order) associated with a port";
|
||||
}
|
||||
enum NETWORK_ADDRESS {
|
||||
description
|
||||
"Port identifier based on a network address,
|
||||
associated with a particular port";
|
||||
}
|
||||
enum INTERFACE_NAME {
|
||||
description
|
||||
"Port identifier based on the name of the interface,
|
||||
e.g., the value of ifName object defined in IETF RFC 2863";
|
||||
}
|
||||
enum AGENT_CIRCUIT_ID {
|
||||
description
|
||||
"Port identifer based on the circuit id in the DHCP
|
||||
relay agent information option as defined in IETF
|
||||
RFC 3046";
|
||||
}
|
||||
enum LOCAL {
|
||||
description
|
||||
"Port identifier based on a locally defined alphanumeric
|
||||
string";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Type definition with enumerations describing the basis of
|
||||
the port identifier";
|
||||
reference
|
||||
"IEEE 802.1AB LLDP MIB";
|
||||
}
|
||||
|
||||
typedef mgmt-interface-number-subtype {
|
||||
type enumeration {
|
||||
enum UNKNOWN {
|
||||
value 1;
|
||||
description
|
||||
"Represents the case where the interface is not known. In this
|
||||
case, the corresponding interface number is of zero length.";
|
||||
}
|
||||
enum IFINDEX {
|
||||
value 2;
|
||||
description
|
||||
"Represents interface identifier based on the ifIndex MIB
|
||||
object.";
|
||||
}
|
||||
enum SYSTEM_PORT_NUMBER {
|
||||
value 3;
|
||||
description
|
||||
"Represents interface identifier based on the system port
|
||||
numbering convention.";
|
||||
}
|
||||
}
|
||||
description
|
||||
"The Management address interface numbering subtype field
|
||||
indicating the numbering method used for defining the interface
|
||||
number.";
|
||||
reference
|
||||
"Sec 8.5.9.5 of IEEE Std 802.1AB-2016";
|
||||
}
|
||||
|
||||
}
|
||||
878
Parseurs_logs_Switch/src/modèles/openconfig-lldp.yang
Normal file
878
Parseurs_logs_Switch/src/modèles/openconfig-lldp.yang
Normal file
@@ -0,0 +1,878 @@
|
||||
module openconfig-lldp {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/lldp";
|
||||
|
||||
prefix "oc-lldp";
|
||||
|
||||
import openconfig-lldp-types { prefix oc-lldp-types; }
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import openconfig-yang-types { prefix oc-yang; }
|
||||
import openconfig-inet-types { prefix oc-inet; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-types { prefix oc-types; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines configuration and operational state data
|
||||
for the LLDP protocol.";
|
||||
|
||||
oc-ext:openconfig-version "1.1.0";
|
||||
|
||||
revision "2026-04-06" {
|
||||
description
|
||||
"Add global TTL configuration/state leaf, interface port-description and custom-tlv-names leaves, custom TLV name leaf, global custom-tlvs list, and add interface counter timestamps for LLDP.";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
revision "2026-01-14" {
|
||||
description
|
||||
"Refactor LLDP management addresses to accomodate 802.1AB defined
|
||||
TLV. Add configurable management interface. Switch from IETF to
|
||||
OC YANG types. Deprecate management-address-type and
|
||||
management-address leafs. Cleanup unused/empty groupings.";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2018-07-17" {
|
||||
description
|
||||
"Adds ttl to lldp-neighbor-state";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2016-05-16" {
|
||||
description
|
||||
"Initial public revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping lldp-common-counters {
|
||||
description
|
||||
"Definition of global and per-interface counters";
|
||||
|
||||
leaf frame-in {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of lldp frames received.";
|
||||
}
|
||||
|
||||
leaf frame-out {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of frames transmitted out.";
|
||||
}
|
||||
|
||||
leaf frame-error-in {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of LLDP frames received with errors.";
|
||||
}
|
||||
|
||||
leaf frame-discard {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of LLDP frames received and discarded.";
|
||||
}
|
||||
|
||||
leaf tlv-discard {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of TLV frames received and discarded.";
|
||||
}
|
||||
|
||||
leaf tlv-unknown {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of frames received with unknown TLV.";
|
||||
}
|
||||
|
||||
leaf last-clear {
|
||||
type oc-yang:date-and-time;
|
||||
description
|
||||
"Indicates the last time the counters were
|
||||
cleared.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-global-counters {
|
||||
description
|
||||
"Definition of global LLDP counters";
|
||||
|
||||
uses lldp-common-counters;
|
||||
|
||||
leaf tlv-accepted {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of valid TLVs received.";
|
||||
}
|
||||
|
||||
leaf entries-aged-out {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of entries aged out due to timeout.";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
grouping lldp-interface-counters {
|
||||
description
|
||||
"Definition of per-interface LLDP counters";
|
||||
|
||||
uses lldp-common-counters;
|
||||
|
||||
leaf frame-error-out {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of frame transmit errors on the
|
||||
interface.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-interface-packet-timestamps {
|
||||
description
|
||||
"Definition of per-interface LLDP packet timestamps";
|
||||
|
||||
leaf last-packet-transmitted {
|
||||
type oc-types:timeticks64;
|
||||
description
|
||||
"Timestamp of the last LLDP packet transmitted on this interface.";
|
||||
}
|
||||
|
||||
leaf last-good-packet-received {
|
||||
type oc-types:timeticks64;
|
||||
description
|
||||
"Timestamp of the last valid LLDP packet received on this interface.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-system-info-config {
|
||||
description
|
||||
"Configuration data for system-level local and remote
|
||||
LLDP information";
|
||||
|
||||
leaf system-name {
|
||||
type string {
|
||||
length 0..255;
|
||||
}
|
||||
description
|
||||
"The system name field shall contain an alpha-numeric string
|
||||
that indicates the system's administratively assigned name.
|
||||
The system name should be the system's fully qualified domain
|
||||
name. If implementations support IETF RFC 3418, the sysName
|
||||
object should be used for this field.";
|
||||
}
|
||||
|
||||
leaf system-description {
|
||||
type string {
|
||||
length 0..255;
|
||||
}
|
||||
description
|
||||
"The system description field shall contain an alpha-numeric
|
||||
string that is the textual description of the network entity.
|
||||
The system description should include the full name and
|
||||
version identification of the system's hardware type,
|
||||
software operating system, and networking software. If
|
||||
implementations support IETF RFC 3418, the sysDescr object
|
||||
should be used for this field.";
|
||||
}
|
||||
|
||||
leaf chassis-id {
|
||||
type string;
|
||||
description
|
||||
"The Chassis ID is a mandatory TLV which identifies the
|
||||
chassis component of the endpoint identifier associated with
|
||||
the transmitting LLDP agent";
|
||||
}
|
||||
|
||||
leaf chassis-id-type {
|
||||
type oc-lldp-types:chassis-id-type;
|
||||
description
|
||||
"This field identifies the format and source of the chassis
|
||||
identifier string. It is an enumerator defined by the
|
||||
LldpChassisIdSubtype object from IEEE 802.1AB MIB.";
|
||||
}
|
||||
|
||||
leaf management-interface {
|
||||
type oc-if:interface-id;
|
||||
description
|
||||
"The interface in which to derive the population of Management
|
||||
Address TLV parameters. If unspecified, the implementation may
|
||||
choose which interface is utilized.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-management-addresses {
|
||||
description
|
||||
"Operational state data to represent local or remote Management
|
||||
Address TLV parameters.";
|
||||
|
||||
container mgmt-addresses {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Encapsulating container for management addresses";
|
||||
|
||||
list mgmt-address {
|
||||
description
|
||||
"List of management addresses in use by the local/remote
|
||||
system";
|
||||
|
||||
key "address";
|
||||
|
||||
leaf address {
|
||||
type leafref {
|
||||
path "../state/address";
|
||||
}
|
||||
description
|
||||
"Reference to the management address key";
|
||||
}
|
||||
|
||||
container state {
|
||||
description
|
||||
"Operational state data for management addresses";
|
||||
|
||||
uses lldp-management-address-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-management-address-state {
|
||||
description
|
||||
"Local or remote management address state data.";
|
||||
|
||||
leaf address {
|
||||
type union {
|
||||
type oc-inet:ip-address;
|
||||
type oc-yang:mac-address;
|
||||
}
|
||||
description
|
||||
"Management address associated with the Management Address
|
||||
TLV.";
|
||||
reference
|
||||
"Sec 8.5.9.4 of IEEE Std 802.1AB-2016";
|
||||
}
|
||||
|
||||
leaf interface-number {
|
||||
type uint32;
|
||||
description
|
||||
"Interface number that identifies the specific interface
|
||||
associated with this management address.";
|
||||
reference
|
||||
"Sec 8.5.9.6 of IEEE Std 802.1AB-2016";
|
||||
}
|
||||
|
||||
leaf interface-number-subtype {
|
||||
type oc-lldp-types:mgmt-interface-number-subtype;
|
||||
description
|
||||
"The Management address interface numbering subtype field
|
||||
indicating the numbering method used for defining the
|
||||
interface-number.";
|
||||
reference
|
||||
"Sec 8.5.9.5 of IEEE Std 802.1AB-2016";
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-neighbor-state {
|
||||
description
|
||||
"Operational state data for LLDP neighbors";
|
||||
|
||||
leaf id {
|
||||
type string;
|
||||
description
|
||||
"System generated identifier for the neighbor on the
|
||||
interface.";
|
||||
}
|
||||
|
||||
leaf age {
|
||||
type uint64;
|
||||
units "seconds";
|
||||
description
|
||||
"Age since discovery";
|
||||
}
|
||||
|
||||
leaf last-update {
|
||||
type int64;
|
||||
description
|
||||
"Seconds since last update received.";
|
||||
}
|
||||
|
||||
leaf ttl {
|
||||
type uint16;
|
||||
units "seconds";
|
||||
description
|
||||
"The time-to-live (TTL) is a mandatory TLV which indicates
|
||||
how long information from the neighbor should be considered
|
||||
valid.";
|
||||
}
|
||||
|
||||
leaf port-id {
|
||||
type string;
|
||||
description
|
||||
"The Port ID is a mandatory TLV which identifies the port
|
||||
component of the endpoint identifier associated with the
|
||||
transmitting LLDP agent. If the specified port is an IEEE
|
||||
802.3 Repeater port, then this TLV is optional.";
|
||||
}
|
||||
|
||||
leaf port-id-type {
|
||||
type oc-lldp-types:port-id-type;
|
||||
description
|
||||
"This field identifies the format and source of the port
|
||||
identifier string. It is an enumerator defined by the
|
||||
PtopoPortIdType object from RFC2922.";
|
||||
}
|
||||
|
||||
leaf port-description {
|
||||
type string;
|
||||
description
|
||||
"The binary string containing the actual port identifier for
|
||||
the port which this LLDP PDU was transmitted. The source and
|
||||
format of this field is defined by PtopoPortId from
|
||||
RFC2922.";
|
||||
}
|
||||
|
||||
leaf management-address {
|
||||
type string;
|
||||
status deprecated;
|
||||
description
|
||||
"The Management Address is a mandatory TLV which identifies a
|
||||
network address associated with the local LLDP agent, which
|
||||
can be used to reach the agent on the port identified in the
|
||||
Port ID TLV.
|
||||
|
||||
This leaf has been deprecated in favor of the management-address
|
||||
list structure to accomodate multiple addresses and distinct
|
||||
typing to pair up with the 802.1AB Management Address TLV
|
||||
specification.";
|
||||
}
|
||||
|
||||
leaf management-address-type {
|
||||
type string;
|
||||
status deprecated;
|
||||
description
|
||||
"The enumerated value for the network address type
|
||||
identified in this TLV. This enumeration is defined in the
|
||||
'Assigned Numbers' RFC [RFC3232] and the
|
||||
ianaAddressFamilyNumbers object.
|
||||
|
||||
This leaf has been deprecated in favor of the management-address
|
||||
list structure to accomodate multiple addresses and distinct
|
||||
typing to pair up with the 802.1AB Management Address TLV
|
||||
specification.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-capabilities-config {
|
||||
description
|
||||
"Configuration data for LLDP capabilities";
|
||||
}
|
||||
|
||||
grouping lldp-capabilities-state {
|
||||
description
|
||||
"Operational state data for LLDP capabilities";
|
||||
|
||||
leaf name {
|
||||
type identityref {
|
||||
base oc-lldp-types:LLDP_SYSTEM_CAPABILITY;
|
||||
}
|
||||
description
|
||||
"Name of the system capability advertised by the neighbor.
|
||||
Capabilities are represented in a bitmap that defines the
|
||||
primary functions of the system. The capabilities are
|
||||
defined in IEEE 802.1AB.";
|
||||
}
|
||||
|
||||
leaf enabled {
|
||||
type boolean;
|
||||
description
|
||||
"Indicates whether the corresponding system capability is
|
||||
enabled on the neighbor.";
|
||||
reference
|
||||
"Sec 8.5.8.2 of IEEE 802.1AB-2009";
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-capabilities-top {
|
||||
description
|
||||
"Top-level grouping for LLDP capabilities";
|
||||
|
||||
container capabilities {
|
||||
config false;
|
||||
description
|
||||
"Enclosing container for list of LLDP capabilities";
|
||||
|
||||
list capability {
|
||||
key "name";
|
||||
description
|
||||
"List of LLDP system capabilities advertised by the
|
||||
neighbor";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "../state/name";
|
||||
}
|
||||
description
|
||||
"Reference to capabilities list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for LLDP capabilities";
|
||||
|
||||
uses lldp-capabilities-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for LLDP capabilities";
|
||||
|
||||
uses lldp-capabilities-config;
|
||||
uses lldp-capabilities-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-custom-tlv-config {
|
||||
description
|
||||
"Configuration data for custom LLDP TLVs";
|
||||
|
||||
uses lldp-custom-tlv-common;
|
||||
}
|
||||
|
||||
grouping lldp-custom-tlv-common {
|
||||
description
|
||||
"Common data for custom LLDP TLVs";
|
||||
|
||||
leaf name {
|
||||
type string;
|
||||
description
|
||||
"Administrative name of the custom TLV for human identification
|
||||
and reference purposes, allowing operators to define a template
|
||||
once at the global level and then reference it by name elsewhere
|
||||
rather than by their numeric type, OUI, and subtype values.";
|
||||
}
|
||||
|
||||
leaf type {
|
||||
type int32;
|
||||
description
|
||||
"The integer value identifying the type of information
|
||||
contained in the value field.";
|
||||
}
|
||||
|
||||
leaf oui {
|
||||
type string;
|
||||
description
|
||||
"The organizationally unique identifier field shall contain
|
||||
the organization's OUI as defined in Clause 9 of IEEE Std
|
||||
802. The high-order octet is 0 and the low-order 3 octets
|
||||
are the SMI Network Management Private Enterprise Code of
|
||||
the Vendor in network byte order, as defined in the
|
||||
'Assigned Numbers' RFC [RFC3232].";
|
||||
}
|
||||
|
||||
leaf oui-subtype {
|
||||
type string;
|
||||
description
|
||||
"The organizationally defined subtype field shall contain a
|
||||
unique subtype value assigned by the defining organization.";
|
||||
}
|
||||
|
||||
// TODO: consider making this string type
|
||||
leaf value {
|
||||
type binary;
|
||||
description
|
||||
"A variable-length octet-string containing the
|
||||
instance-specific information for this TLV.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-custom-tlv-state {
|
||||
description
|
||||
"Operational state data for custom LLDP TLVs";
|
||||
|
||||
uses lldp-custom-tlv-common;
|
||||
}
|
||||
|
||||
grouping lldp-custom-tlv-top {
|
||||
description
|
||||
"Top-level grouping for custom LLDP TLVs";
|
||||
|
||||
container custom-tlvs {
|
||||
config false;
|
||||
description
|
||||
"Enclosing container for list of custom TLVs from a
|
||||
neighbor";
|
||||
|
||||
list tlv {
|
||||
key "type oui oui-subtype";
|
||||
description
|
||||
"List of custom LLDP TLVs from a neighbor";
|
||||
|
||||
leaf type {
|
||||
type leafref {
|
||||
path "../state/type";
|
||||
}
|
||||
description
|
||||
"Reference to type list key";
|
||||
}
|
||||
|
||||
leaf oui {
|
||||
type leafref {
|
||||
path "../state/oui";
|
||||
}
|
||||
description
|
||||
"Reference to oui list key";
|
||||
}
|
||||
|
||||
leaf oui-subtype {
|
||||
type leafref {
|
||||
path "../state/oui-subtype";
|
||||
}
|
||||
description
|
||||
"Reference to oui-subtype list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for custom LLDP TLVs";
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data ";
|
||||
|
||||
uses lldp-custom-tlv-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-neighbor-top {
|
||||
description
|
||||
"Top-level grouping for the LLDP neighbor list";
|
||||
|
||||
container neighbors {
|
||||
config false;
|
||||
description
|
||||
"Enclosing container for list of LLDP neighbors on an
|
||||
interface";
|
||||
|
||||
list neighbor {
|
||||
key "id";
|
||||
description
|
||||
"List of LLDP neighbors";
|
||||
|
||||
leaf id {
|
||||
type leafref {
|
||||
path "../state/id";
|
||||
}
|
||||
description
|
||||
" ";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data ";
|
||||
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data ";
|
||||
|
||||
uses lldp-system-info-config;
|
||||
uses lldp-neighbor-state;
|
||||
}
|
||||
|
||||
uses lldp-management-addresses;
|
||||
uses lldp-custom-tlv-top;
|
||||
uses lldp-capabilities-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-interface-config {
|
||||
description
|
||||
"Configuration data for LLDP on each interface";
|
||||
|
||||
leaf name {
|
||||
type oc-if:base-interface-ref;
|
||||
description
|
||||
"Reference to the LLDP Ethernet interface";
|
||||
}
|
||||
|
||||
leaf enabled {
|
||||
type boolean;
|
||||
default "true";
|
||||
description
|
||||
"Enable or disable the LLDP protocol on the interface.";
|
||||
}
|
||||
|
||||
leaf port-description {
|
||||
type string;
|
||||
description
|
||||
"The binary string advertised in the 'Port Description' TLV
|
||||
(Type 3) of LLDP.
|
||||
When this leaf is populated, its value must be used as the
|
||||
advertised port description, overriding any system-generated
|
||||
strings or the generic interface description found in
|
||||
/interfaces/interface/config/description.
|
||||
|
||||
If this leaf is not populated, the implementation
|
||||
should default to advertising the value of
|
||||
/interfaces/interface/state/description.";
|
||||
reference
|
||||
"Sec 8.5.4 of IEEE Std 802.1AB-2016";
|
||||
}
|
||||
|
||||
leaf-list custom-tlv-names {
|
||||
type leafref {
|
||||
path "../../../../custom-tlvs/tlv/name";
|
||||
}
|
||||
description
|
||||
"References to global custom TLV names to be advertised on this
|
||||
interface. If a custom TLV name is present in this list, the
|
||||
corresponding custom TLV will be advertised in LLDP PDUs transmitted
|
||||
on this interface. If a custom TLV name is not present in this list,
|
||||
it will not be advertised on this interface.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-interface-state {
|
||||
description
|
||||
"Operational state data for LLDP on each interface";
|
||||
|
||||
container counters {
|
||||
description
|
||||
"LLDP counters on each interface";
|
||||
|
||||
uses lldp-interface-counters;
|
||||
}
|
||||
|
||||
uses lldp-interface-packet-timestamps;
|
||||
}
|
||||
|
||||
grouping lldp-interface-top {
|
||||
description
|
||||
"Top-level grouping ";
|
||||
|
||||
container interfaces {
|
||||
description
|
||||
"Enclosing container ";
|
||||
|
||||
list interface {
|
||||
key "name";
|
||||
description
|
||||
"List of interfaces on which LLDP is enabled / available";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "../config/name";
|
||||
}
|
||||
description
|
||||
"Reference to the list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for LLDP on each interface";
|
||||
|
||||
uses lldp-interface-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data ";
|
||||
|
||||
uses lldp-interface-config;
|
||||
uses lldp-interface-state;
|
||||
}
|
||||
|
||||
uses lldp-neighbor-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
grouping lldp-config {
|
||||
description
|
||||
"Configuration data for global LLDP parameters";
|
||||
|
||||
leaf enabled {
|
||||
type boolean;
|
||||
default "true";
|
||||
description
|
||||
"System level state of the LLDP protocol.";
|
||||
}
|
||||
|
||||
leaf hello-timer {
|
||||
type uint64;
|
||||
units "seconds";
|
||||
description
|
||||
"System level hello timer for the LLDP protocol.";
|
||||
}
|
||||
|
||||
leaf ttl {
|
||||
type uint16;
|
||||
units "seconds";
|
||||
description
|
||||
"Time-to-live value for LLDP PDUs transmitted by this system.
|
||||
This value is carried in the TTL TLV and indicates the time
|
||||
interval for which information contained in the LLDP PDU is
|
||||
valid at the receiving system.
|
||||
Note: The TTL value is independent from the hello-timer interval.
|
||||
The hello-timer controls how frequently LLDP PDUs are transmitted,
|
||||
while the TTL value indicates the validity duration of information
|
||||
contained in those PDUs at the receiving system.";
|
||||
reference
|
||||
"Sec 8.5.3 of IEEE Std 802.1AB-2016";
|
||||
}
|
||||
|
||||
leaf-list suppress-tlv-advertisement {
|
||||
type identityref {
|
||||
base oc-lldp-types:LLDP_TLV;
|
||||
}
|
||||
description
|
||||
"Indicates whether the local system should suppress the
|
||||
advertisement of particular TLVs with the LLDP PDUs that it
|
||||
transmits. Where a TLV type is specified within this list, it
|
||||
should not be included in any LLDP PDU transmitted by the
|
||||
local agent.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-state {
|
||||
description
|
||||
"Operational state data for global LLDP parameters";
|
||||
|
||||
container counters {
|
||||
description
|
||||
"Global LLDP counters";
|
||||
|
||||
uses lldp-global-counters;
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-global-custom-tlv-top {
|
||||
description
|
||||
"Top-level grouping for global custom LLDP TLVs";
|
||||
|
||||
container custom-tlvs {
|
||||
description
|
||||
"Enclosing container for list of global custom TLVs.
|
||||
Implementation Note: Custom TLV OUI/subtype combinations
|
||||
MUST NOT collide with standard LLDP TLVs. Configuration
|
||||
of conflicting OUI/subtype values is not permitted.";
|
||||
|
||||
list tlv {
|
||||
key "name";
|
||||
description
|
||||
"List of global custom LLDP TLVs";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "../config/name";
|
||||
}
|
||||
description
|
||||
"Reference to the list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for global custom TLVs";
|
||||
|
||||
uses lldp-custom-tlv-common;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for global custom TLVs";
|
||||
|
||||
uses lldp-custom-tlv-common;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping lldp-top {
|
||||
description
|
||||
"Top-level grouping for LLDP model";
|
||||
|
||||
container lldp {
|
||||
description
|
||||
"Top-level container for LLDP configuration and state data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data ";
|
||||
|
||||
uses lldp-config;
|
||||
uses lldp-system-info-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data ";
|
||||
|
||||
uses lldp-config;
|
||||
uses lldp-system-info-config;
|
||||
uses lldp-state;
|
||||
}
|
||||
|
||||
uses lldp-management-addresses;
|
||||
uses lldp-interface-top;
|
||||
uses lldp-global-custom-tlv-top;
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
uses lldp-top;
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,172 @@
|
||||
module openconfig-local-routing-network-instance {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/local-routing-netinst";
|
||||
|
||||
prefix "oc-loc-rt-netinst";
|
||||
|
||||
import openconfig-network-instance { prefix "oc-ni"; }
|
||||
import openconfig-extensions { prefix "oc-ext"; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module adds leaves that relate to network-instances
|
||||
to the local routing subtree.";
|
||||
|
||||
oc-ext:openconfig-version "1.1.0";
|
||||
|
||||
revision "2025-07-01" {
|
||||
description
|
||||
"Add reference to static next-hop-group and augment the local routing
|
||||
module.";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
revision "2025-06-30" {
|
||||
description
|
||||
"Add leaves that relate to network-instances to the
|
||||
local routing module.";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
grouping static-nexthop-networkinstance {
|
||||
description
|
||||
"This grouping define leaves that need references to the network-instance
|
||||
subtree within the local routing module. It is used to augment the
|
||||
/network-instances/network-instance/protocols/protocol/static-routes/ +
|
||||
static-route/next-hops/next-hop/{config,state} containers.";
|
||||
|
||||
leaf next-network-instance {
|
||||
description
|
||||
"Instead of finding the next-hop for a destination address in the current
|
||||
network-instance, look up the destination address in the routing table
|
||||
of the specified network-instance.
|
||||
|
||||
For example, let 'next-network-instance' = 'DEFAULT'. If a packet arrives
|
||||
in the 'BLUE' network-instance and the destination address matches this
|
||||
route, the destination address will be looked up again in the 'DEFAULT'
|
||||
network-instance to find the next-hop.
|
||||
This leaf is mutually exclusive with 'next-hop', 'nh-network-instance'
|
||||
leaves";
|
||||
|
||||
type leafref {
|
||||
path "/oc-ni:network-instances/oc-ni:network-instance/oc-ni:config/oc-ni:name";
|
||||
}
|
||||
}
|
||||
|
||||
leaf nh-network-instance {
|
||||
description
|
||||
"Network-instance in which IP address of next-hop should
|
||||
be looked up, to find egress interface. This attribute
|
||||
is only valid if next-hop is given as IP address.
|
||||
This attribute may be combined with recurse attribute of any
|
||||
value, in which case recurse setting applies to
|
||||
nh-network-instance.
|
||||
|
||||
For example, let 'nh-network-instance' = 'DEFAULT'. If a
|
||||
packet arrives on the 'BLUE' network-instance and the
|
||||
destination address matches this route, look up the IP
|
||||
configured as next-hop in the 'DEFAULT' network-instance.
|
||||
This leaf is mutually exclusive with next-network-instance
|
||||
leaf";
|
||||
|
||||
type leafref {
|
||||
path "/oc-ni:network-instances/oc-ni:network-instance/oc-ni:config/oc-ni:name";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping static-next-hop-group-networkinstance {
|
||||
description
|
||||
"Grouping of nodes for a reference to a static next-hop-group.";
|
||||
|
||||
container next-hop-group {
|
||||
description
|
||||
"Configuration and state parameters relating to the
|
||||
next-hop-group. In the future, this container will replace the container
|
||||
/network-instances/network-instance/protocols/protocol/static-routes/static/next-hops.
|
||||
If a statically configured next-hop-group is used for a static route
|
||||
prefix then the 'static-routes/static/next-hops' container must not
|
||||
be used.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to the next-hop-group.";
|
||||
|
||||
uses next-hop-group-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational parameters relating to the next-hop-group.";
|
||||
|
||||
uses next-hop-group-config;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping next-hop-group-config {
|
||||
description
|
||||
"Grouping of configuration parameters for a reference to a
|
||||
static next-hop-group.";
|
||||
|
||||
leaf name {
|
||||
description
|
||||
"A user defined name to reference a static next-hop-group.";
|
||||
// we are at /network-instances/network-instance/protocols/protocol/static-routes/static/next-hop-group/config/name
|
||||
type leafref {
|
||||
path "../../../../../../../oc-ni:static/oc-ni:next-hop-groups/oc-ni:next-hop-group/oc-ni:config/oc-ni:name";
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
augment "/oc-ni:network-instances/oc-ni:network-instance/oc-ni:protocols/oc-ni:protocol/oc-ni:static-routes/oc-ni:static" {
|
||||
description
|
||||
"Add network-instance leaves to static routing next-hop container.";
|
||||
|
||||
uses static-next-hop-group-networkinstance;
|
||||
}
|
||||
|
||||
augment "/oc-ni:network-instances/oc-ni:network-instance/oc-ni:protocols/oc-ni:protocol/oc-ni:static-routes/oc-ni:static/oc-ni:next-hops/oc-ni:next-hop/oc-ni:config" {
|
||||
description
|
||||
"Add network-instance leaves to static routing next-hop container.";
|
||||
|
||||
uses static-nexthop-networkinstance;
|
||||
}
|
||||
|
||||
augment "/oc-ni:network-instances/oc-ni:network-instance/oc-ni:protocols/oc-ni:protocol/oc-ni:static-routes/oc-ni:static/oc-ni:next-hops/oc-ni:next-hop/oc-ni:state" {
|
||||
description
|
||||
"Add network-instance leaves to static routing next-hop container.";
|
||||
|
||||
uses static-nexthop-networkinstance;
|
||||
}
|
||||
|
||||
augment "/oc-ni:network-instances/oc-ni:network-instance/oc-ni:static/oc-ni:next-hops/oc-ni:next-hop/oc-ni:config" {
|
||||
description
|
||||
"Add network-instance leaves to static next-hop container.";
|
||||
|
||||
uses static-nexthop-networkinstance;
|
||||
}
|
||||
|
||||
augment "/oc-ni:network-instances/oc-ni:network-instance/oc-ni:static/oc-ni:next-hops/oc-ni:next-hop/oc-ni:state" {
|
||||
description
|
||||
"Add network-instance leaves to static next-hop container.";
|
||||
|
||||
uses static-nexthop-networkinstance;
|
||||
}
|
||||
}
|
||||
516
Parseurs_logs_Switch/src/modèles/openconfig-local-routing.yang
Normal file
516
Parseurs_logs_Switch/src/modèles/openconfig-local-routing.yang
Normal file
@@ -0,0 +1,516 @@
|
||||
module openconfig-local-routing {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/local-routing";
|
||||
|
||||
prefix "oc-loc-rt";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-inet-types { prefix inet; }
|
||||
import openconfig-policy-types { prefix oc-pt; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import openconfig-bfd { prefix oc-bfd; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module describes configuration and operational state data
|
||||
for routes that are locally generated, i.e., not created by
|
||||
dynamic routing protocols. These include static routes, locally
|
||||
created aggregate routes for reducing the number of constituent
|
||||
routes that must be advertised, summary routes for IGPs, etc.
|
||||
|
||||
This model expresses locally generated routes as generically as
|
||||
possible, avoiding configuration of protocol-specific attributes
|
||||
at the time of route creation. This is primarily to avoid
|
||||
assumptions about how underlying router implementations handle
|
||||
route attributes in various routing table data structures they
|
||||
maintain. Hence, the definition of locally generated routes
|
||||
essentially creates 'bare' routes that do not have any protocol-
|
||||
specific attributes.
|
||||
|
||||
When protocol-specific attributes must be attached to a route
|
||||
(e.g., communities on a locally defined route meant to be
|
||||
advertised via BGP), the attributes should be attached via a
|
||||
protocol-specific policy after importing the route into the
|
||||
protocol for distribution (again via routing policy).";
|
||||
|
||||
oc-ext:openconfig-version "4.1.0";
|
||||
|
||||
revision "2025-07-29" {
|
||||
description
|
||||
"Add wecmp-weight leaf to support wECMP with static routes.";
|
||||
reference "4.1.0";
|
||||
}
|
||||
|
||||
revision "2025-07-01" {
|
||||
description
|
||||
"Move static next-hop-group to local-routing-network-instance and
|
||||
augment the local routing module.";
|
||||
reference "4.0.0";
|
||||
}
|
||||
|
||||
revision "2025-06-30" {
|
||||
description
|
||||
"Remove leaves that referenced network instances (see 2.2.0)
|
||||
and replace with augment";
|
||||
reference "3.0.0";
|
||||
}
|
||||
|
||||
revision "2025-03-31" {
|
||||
description
|
||||
"Add static routing to other network instance for destination
|
||||
lookup";
|
||||
reference "2.2.0";
|
||||
}
|
||||
|
||||
revision "2025-02-20" {
|
||||
description
|
||||
"Add static next-hop-groups and encapsulation headers.";
|
||||
reference "2.1.0";
|
||||
}
|
||||
|
||||
revision "2022-11-01" {
|
||||
description
|
||||
"Update static route nexthop index description.";
|
||||
reference "2.0.1";
|
||||
}
|
||||
|
||||
revision "2022-05-10" {
|
||||
description
|
||||
"Removal of top-level /local-routes, description update to
|
||||
static route metric, addition of static/aggregate route
|
||||
preference, addition of aggregate route metric.";
|
||||
reference "2.0.0";
|
||||
}
|
||||
|
||||
revision "2020-03-24" {
|
||||
description
|
||||
"Add bfd support without augmentation.";
|
||||
reference "1.2.0";
|
||||
}
|
||||
|
||||
revision "2020-03-24" {
|
||||
description
|
||||
"Add a description statement to static routes.";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "1.0.2";
|
||||
}
|
||||
|
||||
revision "2017-05-15" {
|
||||
description
|
||||
"Update to resolve style guide non-compliance.";
|
||||
reference "1.0.1";
|
||||
}
|
||||
|
||||
revision "2016-05-11" {
|
||||
description
|
||||
"OpenConfig public release";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
identity LOCAL_DEFINED_NEXT_HOP {
|
||||
description
|
||||
"A base identity type of local defined next-hops";
|
||||
}
|
||||
|
||||
identity DROP {
|
||||
base LOCAL_DEFINED_NEXT_HOP;
|
||||
description
|
||||
"Discard traffic for the corresponding destination";
|
||||
}
|
||||
|
||||
identity LOCAL_LINK {
|
||||
base LOCAL_DEFINED_NEXT_HOP;
|
||||
description
|
||||
"Treat traffic towards addresses within the specified
|
||||
next-hop prefix as though they are connected to a local
|
||||
link. When the LOCAL_LINK next-hop type is specified,
|
||||
an interface must also be specified such that
|
||||
the local system can determine which link to trigger
|
||||
link-layer address discovery against";
|
||||
}
|
||||
|
||||
identity LOCAL_DEFINED_WEIGHT {
|
||||
description
|
||||
"A base identity type of locally defined next-hop weight.";
|
||||
}
|
||||
|
||||
identity AUTO {
|
||||
base LOCAL_DEFINED_WEIGHT;
|
||||
description
|
||||
"The wecmp-weight leaf inherits value from egress interface
|
||||
bandwidth expressed in bps.";
|
||||
}
|
||||
|
||||
// typedef statements
|
||||
|
||||
typedef local-defined-next-hop {
|
||||
type identityref {
|
||||
base LOCAL_DEFINED_NEXT_HOP;
|
||||
}
|
||||
description
|
||||
"Pre-defined next-hop designation for locally generated
|
||||
routes";
|
||||
}
|
||||
|
||||
typedef local-defined-weight {
|
||||
type identityref {
|
||||
base LOCAL_DEFINED_WEIGHT;
|
||||
}
|
||||
description
|
||||
"Pre-defined wECMP weight for locally generated
|
||||
static route next-hops";
|
||||
}
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping local-generic-settings {
|
||||
description
|
||||
"Generic options that can be set on local routes when
|
||||
they are defined";
|
||||
|
||||
leaf set-tag {
|
||||
type oc-pt:tag-type;
|
||||
description
|
||||
"Set a generic tag value on the route. This tag can be
|
||||
used for filtering routes that are distributed to other
|
||||
routing protocols.";
|
||||
}
|
||||
|
||||
leaf description {
|
||||
type string;
|
||||
description
|
||||
"An optional textual description for the route.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping local-common-route-attributes {
|
||||
description
|
||||
"Common route attributes that can be set on static route next-hops
|
||||
as well as aggregate routes.";
|
||||
|
||||
leaf metric {
|
||||
type uint32;
|
||||
description
|
||||
"A metric (or cost) which is utilized to specify the order of
|
||||
selection of the next-hop entry. The lower the metric, the more
|
||||
preferable the prefix entry is. When this value is not
|
||||
specified, the metric is inherited from the default metric of
|
||||
the implementation for static route entries. When multiple
|
||||
next-hops are specified for a static route, the metric is
|
||||
utilized to determine which of the next-hops to be installed in
|
||||
the RIB. When multiple next-hops have the same metric (be it
|
||||
specified, or simply the default) then these next-hops should
|
||||
all be installed in the RIB.";
|
||||
}
|
||||
|
||||
leaf preference {
|
||||
type uint32;
|
||||
description
|
||||
"Administrative Distance (preference) of the entry. The
|
||||
preference defines the order of selection when multiple
|
||||
sources (protocols, static, etc.) contribute to the same
|
||||
prefix entry. The lower the preference, the more preferable the
|
||||
prefix is. When this value is not specified, the preference is
|
||||
inherited from the default preference of the implementation for
|
||||
static routes.";
|
||||
}
|
||||
|
||||
leaf wecmp-weight {
|
||||
type union {
|
||||
type uint64;
|
||||
type local-defined-weight;
|
||||
}
|
||||
description
|
||||
"The weight of next-hop used for WECMP (a.k.a. UCMP, WCMP). This
|
||||
leaf has significance only if multiple next-hops of given prefix
|
||||
form ECMP group, and all of this next-hops have ecmp-weight leaf
|
||||
specified. Else, wecmp-weight should be ignored.
|
||||
The value 'AUTO' sets value to be equal to egress interface
|
||||
bandwidth expressed in bps (not Bps as BGP link-bandwidth
|
||||
extended-community does).
|
||||
It is recommended to express explicit value in bps to be compatible
|
||||
if mixing next-hops with wecmp-weight = 'AUTO'.
|
||||
This leaf is valid only if recurse leaf is set to false, or
|
||||
if interface-ref is specified.";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
grouping local-static-config {
|
||||
description
|
||||
"Configuration data for static routes.";
|
||||
|
||||
leaf prefix {
|
||||
type inet:ip-prefix;
|
||||
description
|
||||
"Destination prefix for the static route, either IPv4 or
|
||||
IPv6.";
|
||||
}
|
||||
|
||||
uses local-generic-settings;
|
||||
}
|
||||
|
||||
grouping local-static-state {
|
||||
description
|
||||
"Operational state data for static routes";
|
||||
}
|
||||
|
||||
|
||||
grouping local-static-nexthop-config {
|
||||
description
|
||||
"Configuration parameters related to each next-hop entry
|
||||
specified for a static route";
|
||||
|
||||
leaf index {
|
||||
type string;
|
||||
description
|
||||
"An user-specified identifier utilised to uniquely reference
|
||||
the next-hop entry in the next-hop list. The value of this
|
||||
index has no semantic meaning other than for referencing
|
||||
the entry. It is observed that implementations typically
|
||||
only support a numeric value for this string. ";
|
||||
}
|
||||
|
||||
leaf next-hop {
|
||||
type union {
|
||||
type inet:ip-address;
|
||||
type local-defined-next-hop;
|
||||
}
|
||||
description
|
||||
"The next-hop that is to be used for the static route
|
||||
- this may be specified as:
|
||||
- an IP address or
|
||||
- a pre-defined next-hop type - for instance, DROP or
|
||||
LOCAL_LINK or
|
||||
When this leaf is not set, and the interface-ref
|
||||
value is specified for the next-hop, then the system should
|
||||
treat the prefix as though it is directly connected to the
|
||||
interface.
|
||||
This leaf is mutualy exclusive with next-network-instance
|
||||
leaf";
|
||||
}
|
||||
|
||||
leaf recurse {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"Determines whether the next-hop should be allowed to
|
||||
be looked up recursively - i.e., via a RIB entry which has
|
||||
been installed by a routing protocol, or another static route
|
||||
- rather than needing to be connected directly to an
|
||||
interface of the local system within the current network
|
||||
instance. When the interface reference specified within the
|
||||
next-hop entry is set (i.e., is not null) then forwarding is
|
||||
restricted to being via the interface specified - and
|
||||
recursion is hence disabled.
|
||||
This leaf is mutualy exclusive with next-network-instance
|
||||
leaf";
|
||||
}
|
||||
|
||||
uses local-common-route-attributes;
|
||||
}
|
||||
|
||||
grouping local-static-nexthop-state {
|
||||
description
|
||||
"Operational state parameters relating to a next-hop entry
|
||||
for a static route";
|
||||
}
|
||||
|
||||
|
||||
grouping local-static-top {
|
||||
description
|
||||
"Top-level grouping for the list of static route definitions";
|
||||
|
||||
container static-routes {
|
||||
description
|
||||
"Enclosing container for the list of static routes";
|
||||
|
||||
list static {
|
||||
key "prefix";
|
||||
description
|
||||
"List of locally configured static routes";
|
||||
|
||||
leaf prefix {
|
||||
type leafref {
|
||||
path "../config/prefix";
|
||||
}
|
||||
description
|
||||
"Reference to the destination prefix list key.";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for static routes";
|
||||
|
||||
uses local-static-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for static routes";
|
||||
|
||||
uses local-static-config;
|
||||
uses local-static-state;
|
||||
}
|
||||
|
||||
container next-hops {
|
||||
description
|
||||
"Configuration and state parameters relating
|
||||
to the next-hops that are to be utilised for the static
|
||||
route being specified.
|
||||
In the future, this container will be deprecated in favor of the
|
||||
/network-instances/network-instance/static/next-hop-groups
|
||||
container. If a statically configured next-hop-group is used
|
||||
for a static route prefix then the 'static-routes/static/next-hops'
|
||||
container must not be used.";
|
||||
|
||||
list next-hop {
|
||||
|
||||
key "index";
|
||||
|
||||
description
|
||||
"A list of next-hops to be utilised for the static
|
||||
route being specified. In the future, this list will be
|
||||
deprecated in favor of
|
||||
/network-instances/network-instance/static/next-hop-groups.";
|
||||
|
||||
leaf index {
|
||||
type leafref {
|
||||
path "../config/index";
|
||||
}
|
||||
description
|
||||
"A reference to the index of the current next-hop.
|
||||
The index is intended to be a user-specified value
|
||||
which can be used to reference the next-hop in
|
||||
question, without any other semantics being
|
||||
assigned to it.";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to the next-hop
|
||||
entry";
|
||||
|
||||
uses local-static-nexthop-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters relating to the
|
||||
next-hop entry";
|
||||
|
||||
uses local-static-nexthop-config;
|
||||
uses local-static-nexthop-state;
|
||||
}
|
||||
|
||||
uses oc-bfd:bfd-enable;
|
||||
uses oc-if:interface-ref;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping local-aggregate-config {
|
||||
description
|
||||
"Configuration data for aggregate routes";
|
||||
|
||||
leaf prefix {
|
||||
type inet:ip-prefix;
|
||||
description
|
||||
"Aggregate prefix to be advertised";
|
||||
}
|
||||
|
||||
leaf discard {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"When true, install the aggregate route with a discard
|
||||
next-hop -- traffic destined to the aggregate will be
|
||||
discarded with no ICMP message generated. When false,
|
||||
traffic destined to an aggregate address when no
|
||||
constituent routes are present will generate an ICMP
|
||||
unreachable message.";
|
||||
}
|
||||
|
||||
uses local-generic-settings;
|
||||
uses local-common-route-attributes;
|
||||
}
|
||||
|
||||
grouping local-aggregate-state {
|
||||
description
|
||||
"Operational state data for local aggregate advertisement
|
||||
definitions";
|
||||
}
|
||||
|
||||
grouping local-aggregate-top {
|
||||
description
|
||||
"Top-level grouping for local aggregates";
|
||||
|
||||
container local-aggregates {
|
||||
description
|
||||
"Enclosing container for locally-defined aggregate
|
||||
routes";
|
||||
|
||||
list aggregate {
|
||||
key "prefix";
|
||||
description
|
||||
"List of aggregates";
|
||||
|
||||
leaf prefix {
|
||||
type leafref {
|
||||
path "../config/prefix";
|
||||
}
|
||||
description
|
||||
"Reference to the configured prefix for this aggregate";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for aggregate advertisements";
|
||||
|
||||
uses local-aggregate-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for aggregate
|
||||
advertisements";
|
||||
|
||||
uses local-aggregate-config;
|
||||
uses local-aggregate-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
226
Parseurs_logs_Switch/src/modèles/openconfig-messages.yang
Normal file
226
Parseurs_logs_Switch/src/modèles/openconfig-messages.yang
Normal file
@@ -0,0 +1,226 @@
|
||||
module openconfig-messages {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/messages";
|
||||
|
||||
prefix "oc-messages";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix "oc-ext"; }
|
||||
import openconfig-system-logging { prefix "oc-log"; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines configuration and operational state data
|
||||
related to Syslog messages that a device may generate.
|
||||
|
||||
These messages are historically obtained through the Syslog
|
||||
transport, however this module allows for obtaining them through
|
||||
an alternative transport, such as a Subscribe operation over an
|
||||
RPC.
|
||||
|
||||
This module does not usurp traditional syslog servers, which may
|
||||
still be configured through the
|
||||
/yang/system/openconfig-system.yang model, rather it provies the
|
||||
Operator with an alternative method of consuming messages.";
|
||||
|
||||
oc-ext:openconfig-version "0.1.0";
|
||||
|
||||
revision 2024-07-15 {
|
||||
description
|
||||
"Remove unused top-level messages container.";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
revision "2018-08-13" {
|
||||
description
|
||||
"Initial draft.";
|
||||
reference "0.0.1";
|
||||
}
|
||||
|
||||
// identity statements
|
||||
|
||||
identity DEBUG_SERVICE {
|
||||
description
|
||||
"Base identity for debug services. Identities within this base
|
||||
identity are to be augmented in by vendors.";
|
||||
}
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping messages-config {
|
||||
description
|
||||
"Configuration data for defining Syslog message severity.";
|
||||
|
||||
leaf severity {
|
||||
type oc-log:syslog-severity;
|
||||
description
|
||||
"Specifies that only messages of the given severity (or
|
||||
greater severity) are sent over the RPC.
|
||||
|
||||
This is analogous to differentiating which severity is to be
|
||||
sent to legacy Syslog servers, as opposed to local buffer or
|
||||
files.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping messages-state {
|
||||
description
|
||||
"Operational state data for Syslog messages.";
|
||||
|
||||
container message {
|
||||
oc-ext:telemetry-atomic;
|
||||
config false;
|
||||
description
|
||||
"Syslog messages the client is Subscribing to. This is all
|
||||
messages currently configured to be sent according to
|
||||
syslog-severity.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
|
||||
// Decide if it is OK to include ALL in this leaf.
|
||||
leaf msg {
|
||||
type string;
|
||||
description
|
||||
"Message payload. If other leafs within this container not
|
||||
supported, this leaf MAY include the entire message,
|
||||
inclding pri, procid, app-name etc..";
|
||||
}
|
||||
|
||||
leaf priority {
|
||||
type uint8;
|
||||
description
|
||||
"The Priority value (PRIVAL) represents both the
|
||||
Facility and Severity.";
|
||||
reference
|
||||
"IETF RFC 5424, Section 6.2.1";
|
||||
}
|
||||
|
||||
leaf app-name {
|
||||
type string;
|
||||
description
|
||||
"The APP-NAME field SHOULD identify the device or
|
||||
application that originated the message.";
|
||||
reference
|
||||
"IETF RFC 5424, Section 6.2.5.";
|
||||
}
|
||||
|
||||
leaf procid {
|
||||
type string;
|
||||
description
|
||||
"PROCID is a value that is included in the message, having
|
||||
no interoperable meaning, except that a change in the value
|
||||
indicates there has been a discontinuity in syslog
|
||||
reporting.";
|
||||
reference
|
||||
"IETF RFC 5424, Section 6.2.6.";
|
||||
}
|
||||
|
||||
leaf msgid {
|
||||
type string;
|
||||
description
|
||||
"The MSGID SHOULD identify the type of message. For
|
||||
example, a firewall might use the MSGID 'TCPIN' for
|
||||
incoming TCP traffic and the MSGID 'TCPOUT' for outgoing
|
||||
TCP traffic.";
|
||||
reference
|
||||
"IETF RFC 5424, Section 6.2.7.";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping debug-messages-config {
|
||||
description
|
||||
"Configuration data for enabling debug messages.";
|
||||
|
||||
leaf service {
|
||||
type identityref {
|
||||
base DEBUG_SERVICE;
|
||||
}
|
||||
description
|
||||
"Enumeration of all services which can have debugging enabled.
|
||||
Vendors are to augment this base identity with their platform
|
||||
or OS specific debug options.";
|
||||
}
|
||||
|
||||
leaf enabled {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"Enable and disable debugging.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping debug-messages-top {
|
||||
description
|
||||
"Configuration data for enabling Syslog debug messages.";
|
||||
|
||||
container debug-entries {
|
||||
description
|
||||
"Enclosing container for list of debugs to enable.";
|
||||
|
||||
list debug-service {
|
||||
key "service";
|
||||
description
|
||||
"List of debugging entries.";
|
||||
|
||||
leaf service {
|
||||
type leafref {
|
||||
path "../config/service";
|
||||
}
|
||||
description
|
||||
"Reference to the debug-enable service key.";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for debug service entries.";
|
||||
|
||||
uses debug-messages-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state data for enabled debugs.";
|
||||
uses debug-messages-config;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping messages-top {
|
||||
description
|
||||
"Top-level grouping for Syslog messages.";
|
||||
|
||||
container messages {
|
||||
description
|
||||
"Top-level container for Syslog messages.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for Syslog messages.";
|
||||
|
||||
uses messages-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state data for a Syslog messages.";
|
||||
|
||||
uses messages-config;
|
||||
uses messages-state;
|
||||
}
|
||||
uses debug-messages-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,953 @@
|
||||
submodule openconfig-network-instance-l2 {
|
||||
|
||||
belongs-to openconfig-network-instance {
|
||||
prefix "oc-netinst";
|
||||
}
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix "oc-ext"; }
|
||||
import openconfig-interfaces { prefix "oc-if"; }
|
||||
import openconfig-yang-types { prefix "oc-yang"; }
|
||||
import openconfig-inet-types { prefix "oc-inet"; }
|
||||
import openconfig-evpn-types { prefix oc-evpn-types; }
|
||||
import openconfig-evpn { prefix "oc-evpn"; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module contains groupings which specifically relate to
|
||||
Layer 2 network instance configuration and operational state
|
||||
parameters.";
|
||||
|
||||
|
||||
oc-ext:openconfig-version "4.7.0";
|
||||
|
||||
revision "2026-03-17" {
|
||||
description
|
||||
"Add enable-aigp to BGP address families in neighbors and peer-groups.";
|
||||
reference "4.7.0";
|
||||
}
|
||||
|
||||
revision "2025-03-26" {
|
||||
description
|
||||
"Add OSPFv3 container";
|
||||
reference "4.6.0";
|
||||
}
|
||||
|
||||
revision "2025-02-20" {
|
||||
description
|
||||
"Add static next-hop-groups and encapsulation headers.";
|
||||
reference "4.5.0";
|
||||
}
|
||||
|
||||
revision "2024-02-27" {
|
||||
description
|
||||
"Clarify that tables are created only by the system and not
|
||||
users.";
|
||||
reference "4.4.1";
|
||||
}
|
||||
|
||||
revision "2024-02-27" {
|
||||
description
|
||||
"Clarify metric to be used for route redistribution when
|
||||
disable-metric-propagation is set to true.";
|
||||
reference "4.4.0";
|
||||
}
|
||||
|
||||
revision "2023-12-13" {
|
||||
description
|
||||
"Expand when statement for connection-points endpoints";
|
||||
reference "4.3.0";
|
||||
}
|
||||
|
||||
revision "2023-11-03" {
|
||||
description
|
||||
"Add reference URL for Route Redistribution rules";
|
||||
reference "4.2.2";
|
||||
}
|
||||
|
||||
revision "2023-11-01" {
|
||||
description
|
||||
"Refactor apply policy to separate default policy in it's own common
|
||||
set of groupings";
|
||||
reference "4.2.1";
|
||||
}
|
||||
|
||||
revision "2023-09-07" {
|
||||
description
|
||||
"Add L2RIB Per Producer Next-Hop Capability";
|
||||
reference "4.2.0";
|
||||
}
|
||||
|
||||
revision "2023-08-09" {
|
||||
description
|
||||
"Update interface key to use interface-id type";
|
||||
reference "4.1.1";
|
||||
}
|
||||
|
||||
revision "2023-07-12" {
|
||||
description
|
||||
"Moved ethernet-segments to top level
|
||||
container.";
|
||||
reference "4.1.0";
|
||||
}
|
||||
|
||||
revision "2023-04-25" {
|
||||
description
|
||||
"Clarify use of interface-ref.";
|
||||
reference "4.0.3";
|
||||
}
|
||||
|
||||
revision "2023-03-15" {
|
||||
description
|
||||
"Clarify that tables are to be deleted by the
|
||||
network operating system";
|
||||
reference "4.0.2";
|
||||
}
|
||||
|
||||
revision "2023-02-07" {
|
||||
description
|
||||
"Add prefixes to identity values in when statements";
|
||||
reference "4.0.1";
|
||||
}
|
||||
|
||||
revision "2022-12-21" {
|
||||
description
|
||||
"Removal of global per network-instance MTU";
|
||||
reference "4.0.0";
|
||||
}
|
||||
|
||||
revision "2022-12-21" {
|
||||
description
|
||||
"Removal of interface list unique statement";
|
||||
reference "3.1.0";
|
||||
}
|
||||
|
||||
revision "2022-12-20" {
|
||||
description
|
||||
"Removal of top-level enabled-address-families leaf-list";
|
||||
reference "3.0.0";
|
||||
}
|
||||
|
||||
revision "2022-11-18" {
|
||||
description
|
||||
"Enforce network-instance type as mandatory, removal of top-level
|
||||
enabled leaf, migrate IETF types to OpenConfig types";
|
||||
reference "2.0.0";
|
||||
}
|
||||
|
||||
revision "2022-09-15" {
|
||||
description
|
||||
"Add fallback-vrf option.";
|
||||
reference "1.4.0";
|
||||
}
|
||||
|
||||
revision "2022-07-04" {
|
||||
description
|
||||
"Add pcep protocol to network-instance";
|
||||
reference "1.3.0";
|
||||
}
|
||||
|
||||
revision "2022-06-21" {
|
||||
description
|
||||
"Add prefix to qualification netinst-ref.";
|
||||
reference "1.2.0";
|
||||
}
|
||||
|
||||
revision "2022-04-20" {
|
||||
description
|
||||
"Add support for l2rib state data";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
revision "2022-04-19" {
|
||||
description
|
||||
"Description updates for DEFAULT_INSTANCE implementation
|
||||
guidance and default value/guidance for protocol instances";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
revision "2022-04-19" {
|
||||
description
|
||||
"Fix some broken xpath references in when statements.";
|
||||
reference "0.16.3";
|
||||
|
||||
}
|
||||
|
||||
revision "2021-11-17" {
|
||||
description
|
||||
"Add prefix to qualification prefix to when statements
|
||||
at identifier level.";
|
||||
reference "0.16.2";
|
||||
}
|
||||
|
||||
revision "2021-07-22" {
|
||||
description
|
||||
"Remove unused imported models.";
|
||||
reference "0.16.1";
|
||||
}
|
||||
|
||||
revision "2021-06-11" {
|
||||
description
|
||||
"Structural update for arp-proxy and
|
||||
proxy-nd.";
|
||||
reference "0.16.0";
|
||||
}
|
||||
|
||||
revision "2021-01-25" {
|
||||
description
|
||||
"Add support for evpn";
|
||||
reference "0.15.0";
|
||||
}
|
||||
|
||||
revision "2020-06-20" {
|
||||
description
|
||||
"Add support for toggling metric propagation
|
||||
when using table-connections.";
|
||||
reference "0.14.0";
|
||||
}
|
||||
|
||||
revision "2019-11-28" {
|
||||
description
|
||||
"Revert fixes for paths in when statements";
|
||||
reference "0.13.2";
|
||||
}
|
||||
|
||||
revision "2019-04-16" {
|
||||
description
|
||||
"Move BGP RIB into the protocol/bgp container.";
|
||||
reference "0.12.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.11.1";
|
||||
}
|
||||
|
||||
revision "2018-08-11" {
|
||||
description
|
||||
"Add vlan id as additional key in MAC table";
|
||||
reference "0.11.0";
|
||||
}
|
||||
|
||||
revision "2018-06-22" {
|
||||
description
|
||||
"Fix typo in OSPF when statement";
|
||||
reference "0.10.2";
|
||||
}
|
||||
|
||||
revision "2018-06-05" {
|
||||
description
|
||||
"Fix bugs in when statements";
|
||||
reference "0.10.1";
|
||||
}
|
||||
|
||||
revision "2018-02-19" {
|
||||
description
|
||||
"Add PIM and IGMP to network instance";
|
||||
reference "0.10.0";
|
||||
}
|
||||
|
||||
revision "2017-12-13" {
|
||||
description
|
||||
"Fix incorrect constraint on SR and MPLS containers";
|
||||
reference "0.9.0";
|
||||
}
|
||||
|
||||
revision "2017-08-24" {
|
||||
description
|
||||
"Minor formatting fixes";
|
||||
reference "0.8.1";
|
||||
}
|
||||
|
||||
revision "2017-02-28" {
|
||||
description
|
||||
"Add OSPFv2 to network instance";
|
||||
reference "0.8.0";
|
||||
}
|
||||
|
||||
revision "2017-01-26" {
|
||||
description
|
||||
"Add policy forwarding to network instance";
|
||||
reference "0.7.0";
|
||||
}
|
||||
|
||||
revision "2017-01-13" {
|
||||
description
|
||||
"Add AFT to the network instance";
|
||||
reference "0.6.0";
|
||||
}
|
||||
|
||||
revision "2016-12-15" {
|
||||
description
|
||||
"Add segment routing to network instance";
|
||||
reference "0.5.0";
|
||||
}
|
||||
|
||||
revision "2016-11-10" {
|
||||
description
|
||||
"Update model to include IS-IS.";
|
||||
reference "0.4.1";
|
||||
}
|
||||
|
||||
revision "2016-10-12" {
|
||||
description
|
||||
"Update table connections";
|
||||
reference "0.4.0";
|
||||
}
|
||||
|
||||
revision "2016-09-28" {
|
||||
description
|
||||
"Change L2 instance to submodule; add MAC table";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2016-08-11" {
|
||||
description
|
||||
"Resolve repeated container names in routing protocols";
|
||||
reference "0.2.3";
|
||||
}
|
||||
|
||||
revision "2016-07-08" {
|
||||
description
|
||||
"Updated with refactored routing protocol models";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2016-03-29" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2015-11-20" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
grouping l2ni-instance {
|
||||
description
|
||||
"Configuration and operational state parameters relating
|
||||
to a Layer 2 network instance";
|
||||
|
||||
container fdb {
|
||||
description
|
||||
"Operational state and configuration parameters relating to
|
||||
the forwarding database of the network instance";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to the FDB";
|
||||
uses l2ni-fdb-mac-config;
|
||||
}
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters relating to the FDB";
|
||||
uses l2ni-fdb-mac-config;
|
||||
}
|
||||
|
||||
uses l2ni-mac-table-top;
|
||||
uses oc-evpn:evpn-mac-mobility-top;
|
||||
uses oc-evpn:evpn-arp-proxy-top;
|
||||
uses oc-evpn:evpn-nd-proxy-top;
|
||||
uses l2ni-l2rib-top;
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-fdb-mac-config {
|
||||
description
|
||||
"Parameters relating to FDB behaviour relating to MAC
|
||||
addresses";
|
||||
|
||||
leaf mac-learning {
|
||||
type boolean;
|
||||
description
|
||||
"When this leaf is set to true, MAC learning is enabled for
|
||||
the network instance, such that MAC addresses are learned
|
||||
from ingress frames and added to the FDB.";
|
||||
}
|
||||
|
||||
leaf mac-aging-time {
|
||||
// Cisco supports one aging time for local and remote, but
|
||||
// can specify this time is absolute or against inactivity.
|
||||
// ALU SROS supports different aging times for local and remote
|
||||
// but does not allow absolute/inactivity specification.
|
||||
// JNPR supports only a single aging time, and no specification
|
||||
// of whether inactivity/absolute is used.
|
||||
// It is easy to augment new options in here for local remote
|
||||
// and an extra leaf to allow specification of the type of aging
|
||||
// so this is left as a single value.
|
||||
type uint16;
|
||||
units seconds;
|
||||
description
|
||||
"The number of seconds of inactivity after which the entry
|
||||
in the local FDB is timed out.";
|
||||
}
|
||||
|
||||
leaf maximum-entries {
|
||||
type uint16;
|
||||
description
|
||||
"The maximum number of MAC address entries that should be
|
||||
accepted into the FDB";
|
||||
}
|
||||
|
||||
uses oc-evpn:evpn-mac-vrf-config;
|
||||
}
|
||||
|
||||
grouping l2ni-encapsulation-config {
|
||||
description
|
||||
"Encapsulation related configuration parameters for a L2
|
||||
network instance";
|
||||
|
||||
leaf control-word {
|
||||
type boolean;
|
||||
description
|
||||
"Whether the control-word should be used for the network
|
||||
instance";
|
||||
reference "RFC3985";
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-mac-table-config {
|
||||
description
|
||||
"Configuration data for MAC table entries";
|
||||
|
||||
leaf mac-address {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"MAC address for the dynamic or static MAC table
|
||||
entry";
|
||||
}
|
||||
|
||||
leaf vlan {
|
||||
//TODO(aashaikh): Consider whether this should just reflect the
|
||||
//VLAN id or be a union type to also support displaying/setting
|
||||
//the VLAN by name (i.e., global VLAN configured in the VLAN
|
||||
// model).
|
||||
type leafref {
|
||||
path "../../../../../../vlans/vlan/config/vlan-id";
|
||||
}
|
||||
description
|
||||
"VLAN on which the MAC address is present. The same MAC
|
||||
address may be seen on multiple VLANs in some cases.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-mac-table-state {
|
||||
description
|
||||
"Operational state data for MAC table entries";
|
||||
|
||||
leaf age {
|
||||
type uint64;
|
||||
units seconds;
|
||||
description
|
||||
"The time in seconds since the MAC address has been in the
|
||||
table";
|
||||
}
|
||||
|
||||
leaf entry-type {
|
||||
type enumeration {
|
||||
enum STATIC {
|
||||
description
|
||||
"Statically programmed MAC table entry";
|
||||
}
|
||||
enum DYNAMIC {
|
||||
description
|
||||
"Dynamically learned MAC table entry";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Indicates whether the entry was statically configured, or
|
||||
dynamically learned.";
|
||||
}
|
||||
|
||||
leaf evi {
|
||||
type oc-evpn-types:vni-id;
|
||||
description "EVPN EVI to associate with the BD/VLAN";
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-mac-table-top {
|
||||
description
|
||||
"Top-level grouping for MAC table list";
|
||||
|
||||
|
||||
container mac-table {
|
||||
description
|
||||
"Table of learned or statically configured MAC addresses and
|
||||
corresponding VLANs in the bridge domain";
|
||||
|
||||
container entries {
|
||||
description
|
||||
"Enclosing container for list of MAC table entries";
|
||||
|
||||
list entry {
|
||||
key "mac-address vlan";
|
||||
description
|
||||
"List of learned MAC addresses";
|
||||
|
||||
leaf mac-address {
|
||||
type leafref {
|
||||
path "../config/mac-address";
|
||||
}
|
||||
description
|
||||
"Reference to mac-address list key";
|
||||
}
|
||||
|
||||
leaf vlan {
|
||||
type leafref {
|
||||
path "../config/vlan";
|
||||
}
|
||||
description
|
||||
"Reference to vlan list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for MAC table entries";
|
||||
|
||||
uses l2ni-mac-table-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for MAC table entries";
|
||||
|
||||
uses l2ni-mac-table-config;
|
||||
uses l2ni-mac-table-state;
|
||||
}
|
||||
|
||||
container interface {
|
||||
description
|
||||
"Reference to the base and/or subinterface for the
|
||||
MAC table entry";
|
||||
|
||||
uses oc-if:interface-ref;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-l2rib-top {
|
||||
description
|
||||
"Top-level grouping for l2rib MAC and MAC-IP table list";
|
||||
|
||||
container l2rib {
|
||||
config false;
|
||||
description
|
||||
"Operational state container for MAC address and MAC-IP address
|
||||
information that is learned and installed into the MAC VRF Layer 2
|
||||
Routing Information Base (L2RIB)";
|
||||
|
||||
container mac-table {
|
||||
description
|
||||
"Operational state container for MAC address information installed
|
||||
into the MAC VRF of the L2RIB";
|
||||
|
||||
container entries {
|
||||
description
|
||||
"Enclosing container for list of MAC address entries";
|
||||
|
||||
list entry {
|
||||
key "mac-address";
|
||||
description "List of learned MAC addresses";
|
||||
|
||||
leaf mac-address {
|
||||
type leafref {
|
||||
path "../state/mac-address";
|
||||
}
|
||||
description "Leafref of MAC address object";
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state data for L2RIB MAC table object entry";
|
||||
uses l2ni-l2rib-mac-table-state;
|
||||
}
|
||||
|
||||
container producers {
|
||||
description "Source producers for each MAC Table entry";
|
||||
list producer {
|
||||
key "producer";
|
||||
description
|
||||
"List of producers for each MAC table entry";
|
||||
|
||||
leaf producer {
|
||||
type leafref {
|
||||
path "../state/producer";
|
||||
}
|
||||
description
|
||||
"Reference to producer list key";
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description "State container for L2RIB MAC Table Entries";
|
||||
uses l2ni-l2rib-common-producer-state;
|
||||
uses l2ni-l2rib-mac-table-producer-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
uses l2ni-l2rib-common-next-hop-group-state;
|
||||
uses l2ni-l2rib-common-next-hop-state;
|
||||
}
|
||||
|
||||
container mac-ip-table {
|
||||
description
|
||||
"Operational state container for MAC-IP address information installed
|
||||
into the MAC VRF of the L2RIB";
|
||||
|
||||
container entries {
|
||||
description
|
||||
"Enclosing container for list of MAC-IP address entries";
|
||||
|
||||
list entry {
|
||||
key "mac-address host-ip";
|
||||
description "List of learned MAC-IP addresses";
|
||||
|
||||
leaf mac-address {
|
||||
type leafref {
|
||||
path "../state/mac-address";
|
||||
}
|
||||
description "Leafref of MAC-IP address object";
|
||||
}
|
||||
|
||||
leaf host-ip {
|
||||
type leafref {
|
||||
path "../state/host-ip";
|
||||
}
|
||||
description "IP address of the Customer Edge device";
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state data for L2RIB MAC-IP table object entry";
|
||||
uses l2ni-l2rib-mac-ip-table-state;
|
||||
}
|
||||
|
||||
container producers {
|
||||
description "Source producers for each MAC-IP Table entry";
|
||||
list producer {
|
||||
key "producer";
|
||||
description
|
||||
"List of producers for each MAC-IP table entry";
|
||||
|
||||
leaf producer {
|
||||
type leafref {
|
||||
path "../state/producer";
|
||||
}
|
||||
description
|
||||
"Reference to producer list key";
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description "State container for L2RIB MAC Table Entries";
|
||||
uses l2ni-l2rib-common-producer-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
uses l2ni-l2rib-common-next-hop-group-state;
|
||||
uses l2ni-l2rib-common-next-hop-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-l2rib-mac-table-state {
|
||||
description "L2RIB MAC Table Operational State Grouping";
|
||||
uses l2ni-l2rib-common-state;
|
||||
}
|
||||
|
||||
grouping l2ni-l2rib-mac-ip-table-state {
|
||||
description "L2RIB Mac-IP Table Operational State Grouping";
|
||||
uses l2ni-l2rib-common-state;
|
||||
|
||||
leaf host-ip {
|
||||
type oc-inet:ip-address;
|
||||
description
|
||||
"Host IP address of the CE device for the L2RIB MAC-IP entry";
|
||||
reference "RFC7432: BGP MPLS-Based Ethernet VPN";
|
||||
}
|
||||
|
||||
leaf l3-vni {
|
||||
type oc-evpn-types:evi-id;
|
||||
description
|
||||
"Symmetric IRB uses the same forwarding semantics when routing
|
||||
between IP subnets with VRF Lite or MPLS L3VPNs. With symmetric IRB,
|
||||
all traffic egressing and returning from a VTEP uses the same VNI.
|
||||
Specifically, the same Layer 3 VNI (L3VNI) associated with the VRF
|
||||
is used for all routed traffic. Layer3 VNI used for inter-subnet
|
||||
routing";
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-l2rib-common-state {
|
||||
description "L2RIB Common Property Operational State Data Grouping";
|
||||
|
||||
leaf mac-address {
|
||||
type oc-yang:mac-address;
|
||||
description "MAC address of the L2RIB MAC or MAC-IP entry";
|
||||
}
|
||||
leaf vlan {
|
||||
type leafref {
|
||||
path "../../../../../../../vlans/vlan/config/vlan-id";
|
||||
}
|
||||
description
|
||||
"VLAN on which the MAC or MAC-IP address is present.";
|
||||
}
|
||||
leaf evi {
|
||||
type oc-evpn-types:evi-id;
|
||||
description "EVPN Instance Identifier for the MAC or MAC-IP";
|
||||
}
|
||||
leaf l2-vni {
|
||||
type oc-evpn-types:evi-id;
|
||||
description "Layer2 VNI segment mapped to given vlan-id";
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-l2rib-common-producer-state {
|
||||
description "L2RIB Common Producer Attributes Operational State Data Grouping";
|
||||
|
||||
leaf producer {
|
||||
type enumeration {
|
||||
enum LOCAL {
|
||||
description "local producer source";
|
||||
}
|
||||
enum STATIC {
|
||||
description "static producer source";
|
||||
}
|
||||
enum BGP {
|
||||
description "bgp producer source";
|
||||
}
|
||||
}
|
||||
description "Source of the learned L2RIB route";
|
||||
}
|
||||
|
||||
leaf seq-number {
|
||||
type uint32;
|
||||
description
|
||||
"The sequence number is used to ensure that PEs retain the correct
|
||||
MAC/IP Advertisement route when multiple updates occur for the same
|
||||
MAC address";
|
||||
reference "RFC7432: BGP MPLS-Based Ethernet VPN";
|
||||
}
|
||||
|
||||
leaf mobility-state {
|
||||
type enumeration {
|
||||
enum FROZEN {
|
||||
description
|
||||
"Permanently frozen mac-address";
|
||||
}
|
||||
enum DUPLICATE {
|
||||
description
|
||||
"Duplicate mac-address";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Indicates if learned MAC address is duplicate or frozen";
|
||||
reference "draft-ietf-bess-evpn-irb-extended-mobility-05";
|
||||
}
|
||||
|
||||
leaf esi {
|
||||
type oc-evpn-types:esi;
|
||||
description
|
||||
"Ethernet Segment Identifier (ESI) for local and remote routes.
|
||||
ESI is used to resolve the next-hop-group. All mac-addresses
|
||||
learned with the same ESI should point to the same next-hop-group";
|
||||
}
|
||||
|
||||
leaf sticky {
|
||||
type boolean;
|
||||
description "MAC address is sticky and not subjected to MAC moves";
|
||||
reference "RFC7432: BGP MPLS-Based Ethernet VPN";
|
||||
}
|
||||
|
||||
leaf next-hop {
|
||||
type leafref {
|
||||
path "../../../../../../next-hops/next-hop/index";
|
||||
}
|
||||
status deprecated;
|
||||
description "Leafref next-hop for the MAC-IP table entry";
|
||||
}
|
||||
|
||||
leaf-list next-hop-group {
|
||||
type leafref {
|
||||
path "../../../../../../next-hop-groups/next-hop-group/id";
|
||||
}
|
||||
description "Leafref next-hop-group for the MAC-IP table entry";
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-l2rib-common-next-hop-state {
|
||||
description "L2RIB Common Next Hop Attributes Operational State Data Grouping";
|
||||
|
||||
container next-hops {
|
||||
description "A next-hop associated with the MAC or MAC-IP entry";
|
||||
list next-hop {
|
||||
key "index";
|
||||
description "List of next hop attributes for each MAC or MAC-IP";
|
||||
|
||||
leaf index {
|
||||
type leafref {
|
||||
path "../state/index";
|
||||
}
|
||||
description
|
||||
"A unique index identifying the next-hop entry for the
|
||||
MAC or MAC-IP entry";
|
||||
}
|
||||
container state {
|
||||
description "State container for common next-hop attributes";
|
||||
config false;
|
||||
leaf index {
|
||||
type uint64;
|
||||
description "A unique entry for the next-hop.";
|
||||
}
|
||||
leaf peer-ip {
|
||||
type oc-inet:ip-address;
|
||||
description "Next hop peer address";
|
||||
}
|
||||
leaf label {
|
||||
type oc-evpn-types:evi-id;
|
||||
description "Next hop label representing the l2vni for the route";
|
||||
}
|
||||
leaf esi {
|
||||
type oc-evpn-types:esi;
|
||||
description "Ethernet Segment Identifier (ESI)";
|
||||
reference "RFC7432: BGP MPLS-Based Ethernet VPN";
|
||||
}
|
||||
leaf resolved {
|
||||
type boolean;
|
||||
description
|
||||
"Indicates if the path is eligible for forwarding as per evpn mass
|
||||
withdraw procedures as defined in RFC 7432";
|
||||
}
|
||||
uses oc-if:interface-ref-common;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-l2rib-common-next-hop-group-state {
|
||||
description "L2RIB Common Next Hop Group Attributes Operational State Data Grouping";
|
||||
|
||||
container next-hop-groups {
|
||||
description "Surrounding container for groups of L2RIB next-hops.";
|
||||
list next-hop-group {
|
||||
key "id";
|
||||
description
|
||||
"An individual set of next-hops grouped into a common group.
|
||||
Each entry within an L2RIB can optionally point to a
|
||||
next-hop-group.";
|
||||
|
||||
leaf id {
|
||||
type leafref {
|
||||
path "../state/id";
|
||||
}
|
||||
description
|
||||
"A reference to a unique identifier for the next-hop-group.";
|
||||
}
|
||||
container state {
|
||||
description "State container for common next-hop-group attributes";
|
||||
config false;
|
||||
leaf id {
|
||||
type uint64;
|
||||
description
|
||||
"A unique identifier for the next-hop-group. This index is not
|
||||
expected to be consistent across reboots, or reprogramming of
|
||||
the next-hop-group. When updating a next-hop-group, if the group
|
||||
is removed by the system or assigned an alternate identifier, the
|
||||
system should send telemetry notifications deleting the previous
|
||||
identifier. If the identifier of the next-hop-group is changed,
|
||||
all L2RIB entries that reference it must also be updated.";
|
||||
}
|
||||
leaf esi {
|
||||
type oc-evpn-types:esi;
|
||||
description "Ethernet Segment Identifier (ESI)";
|
||||
reference "RFC7432: BGP MPLS-Based Ethernet VPN";
|
||||
}
|
||||
leaf type {
|
||||
type enumeration {
|
||||
enum ESI {
|
||||
description
|
||||
"Per ESI pathlist next-hop-group used for evpn mass withdraw procedures as defined in RFC 7432";
|
||||
}
|
||||
enum ESI_EVI {
|
||||
description
|
||||
"Per ESI,EVI pathlist next-hop-group used for evpn aliasing procedures as defined in RFC 7432";
|
||||
}
|
||||
enum BASE_ECMP {
|
||||
description
|
||||
"Base ECMP next-hop-group used in absence of evpn aliasing";
|
||||
}
|
||||
}
|
||||
description "Type of next-hop-group";
|
||||
}
|
||||
}
|
||||
container next-hops {
|
||||
description
|
||||
"Surrounding container for the list of next-hops within the next-hop-group.";
|
||||
list next-hop {
|
||||
key "index";
|
||||
description
|
||||
"An individual next-hop within the next-hop-group. Each next-hop is a
|
||||
reference to an entry within the next-hop list.";
|
||||
|
||||
leaf index {
|
||||
type leafref {
|
||||
path "../state/index";
|
||||
}
|
||||
description
|
||||
"A reference to the index for the next-hop within the the next-hop-group.";
|
||||
}
|
||||
container state {
|
||||
description
|
||||
"Operational state parameters related to a next-hop within the next-hop-group.";
|
||||
config false;
|
||||
leaf index {
|
||||
type leafref {
|
||||
path "../../../../../../next-hops/next-hop/index";
|
||||
}
|
||||
description
|
||||
"A reference to the identifier for the next-hop to which the entry in the
|
||||
next-hop group corresponds.";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping l2ni-l2rib-mac-table-producer-state {
|
||||
description "L2RIB MAC Table Operational State Data Grouping";
|
||||
|
||||
leaf derived-from-mac-ip {
|
||||
type boolean;
|
||||
description "Derived from BGP MAC-IP route-type 2";
|
||||
}
|
||||
|
||||
leaf directly-received {
|
||||
type boolean;
|
||||
description "BGP learned MAC route-type 2";
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,242 @@
|
||||
module openconfig-network-instance-l3 {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/network-instance-l3";
|
||||
|
||||
prefix "oc-ni-l3";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix "oc-ext"; }
|
||||
import openconfig-types { prefix "octypes"; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module contains groupings which specifically relate to
|
||||
Layer 3 network instance configuration and operational state
|
||||
parameters.";
|
||||
|
||||
oc-ext:openconfig-version "2.0.0";
|
||||
|
||||
revision "2022-11-08" {
|
||||
description
|
||||
"Removal of top-level enabled-address-families leaf-list";
|
||||
reference "2.0.0";
|
||||
}
|
||||
|
||||
revision "2022-09-15" {
|
||||
description
|
||||
"Reflect implementation status by releasing 1.0.0.";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.11.1";
|
||||
}
|
||||
|
||||
revision "2018-08-17" {
|
||||
description
|
||||
"Add a route limit for L3 network instances.";
|
||||
reference "0.11.0";
|
||||
}
|
||||
|
||||
revision "2017-12-13" {
|
||||
description
|
||||
"Fix incorrect constraint on SR and MPLS containers";
|
||||
reference "0.9.0";
|
||||
}
|
||||
|
||||
revision "2017-08-24" {
|
||||
description
|
||||
"Minor formatting fixes";
|
||||
reference "0.8.1";
|
||||
}
|
||||
|
||||
revision "2017-02-28" {
|
||||
description
|
||||
"Add OSPFv2 to network instance";
|
||||
reference "0.8.0";
|
||||
}
|
||||
|
||||
revision "2017-01-26" {
|
||||
description
|
||||
"Add policy forwarding to network instance";
|
||||
reference "0.7.0";
|
||||
}
|
||||
|
||||
revision "2017-01-13" {
|
||||
description
|
||||
"Add AFT to the network instance";
|
||||
reference "0.6.0";
|
||||
}
|
||||
|
||||
revision "2016-12-15" {
|
||||
description
|
||||
"Add segment routing to network instance";
|
||||
reference "0.5.0";
|
||||
}
|
||||
|
||||
revision "2016-11-10" {
|
||||
description
|
||||
"Update model to include IS-IS.";
|
||||
reference "0.4.1";
|
||||
}
|
||||
|
||||
revision "2016-09-28" {
|
||||
description
|
||||
"Change L2 instance to submodule; add MAC table";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2016-08-11" {
|
||||
description
|
||||
"Resolve repeated container names in routing protocols";
|
||||
reference "0.2.3";
|
||||
}
|
||||
|
||||
revision "2016-07-08" {
|
||||
description
|
||||
"Updated with refactored routing protocol models";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2016-03-29" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2016-03-14" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
grouping l3ni-instance {
|
||||
description
|
||||
"Configuration and operational state parameters relevant
|
||||
to network instances that include a Layer 3 type";
|
||||
|
||||
}
|
||||
|
||||
grouping l3ni-route-limit-structural {
|
||||
description
|
||||
"Configuration and state for the maximum number of routes
|
||||
that should be used by routing instance.";
|
||||
|
||||
container route-limits {
|
||||
description
|
||||
"Configuration and operational state relating to the
|
||||
maximum number of routes for the address family that
|
||||
should be allowed within the Layer 3 network instance.
|
||||
|
||||
When the specified value is reached, no further prefixes
|
||||
should be installed into the system's RIB from this network
|
||||
instance unless the warning only leaf is set. In this case,
|
||||
new routes should still be installed. If a alarm threshold
|
||||
is specified, then this should be used to generate
|
||||
alarms via telemetry for the network instance.";
|
||||
|
||||
list route-limit {
|
||||
key "afi";
|
||||
|
||||
description
|
||||
"A route limit applying to a particular address family.";
|
||||
|
||||
leaf afi {
|
||||
type leafref {
|
||||
path "../config/afi";
|
||||
}
|
||||
description
|
||||
"Reference to the address family for which the route
|
||||
limit is being applied.";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration options relating to the route limit.";
|
||||
uses l3ni-route-limit-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters relating to the route limit.";
|
||||
uses l3ni-route-limit-config;
|
||||
uses l3ni-route-limit-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping l3ni-route-limit-config {
|
||||
description
|
||||
"Configuration options relating to the route limit for a network
|
||||
instance.";
|
||||
|
||||
leaf afi {
|
||||
type identityref {
|
||||
base octypes:ADDRESS_FAMILY;
|
||||
}
|
||||
description
|
||||
"The address family for which the route limit applies.";
|
||||
}
|
||||
|
||||
leaf maximum {
|
||||
type uint32;
|
||||
description
|
||||
"The maximum number of routes for the address family. The
|
||||
system should not install more than maximum number of
|
||||
prefixes into the RIB unless the warning-only leaf is specified.";
|
||||
}
|
||||
|
||||
leaf warning-only {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"When specified, the route limit specified is considered only as
|
||||
a warning - and routes should continue to be installed into the
|
||||
RIB over the limit specified in the maximum leaf.";
|
||||
}
|
||||
|
||||
leaf alarm-threshold {
|
||||
type uint32;
|
||||
description
|
||||
"When specified, an alarm should be generated when the threshold
|
||||
number of installed routes is reached.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping l3ni-route-limit-state {
|
||||
description
|
||||
"Operational state relating to the route limit for a network
|
||||
instance.";
|
||||
|
||||
leaf threshold-exceeded {
|
||||
type boolean;
|
||||
description
|
||||
"This leaf should be set to true in the case that the threshold
|
||||
number of routes has been exceeded.";
|
||||
}
|
||||
|
||||
leaf installed-routes {
|
||||
type uint32;
|
||||
description
|
||||
"The current number of routes installed for the address family.";
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,144 @@
|
||||
module openconfig-network-instance-policy {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/network-instance/policy";
|
||||
|
||||
prefix "oc-ni-pol";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-routing-policy { prefix oc-rpol; }
|
||||
import openconfig-policy-types { prefix oc-pol-types; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines routing policy statements (conditions and
|
||||
actions) for the network instance model. These statements are
|
||||
generally added to the routing policy model.";
|
||||
|
||||
oc-ext:openconfig-version "0.1.3";
|
||||
|
||||
revision "2024-09-19" {
|
||||
description
|
||||
"Correct typo in description of
|
||||
match-protocol-instance/protocol-name.";
|
||||
reference "0.1.3";
|
||||
}
|
||||
|
||||
revision "2023-07-25" {
|
||||
description
|
||||
"Expand description of
|
||||
match-protocol-instance/protocol-name.";
|
||||
reference "0.1.2";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.1.1";
|
||||
}
|
||||
|
||||
revision "2017-02-15" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping protocol-instance-policy-config {
|
||||
description
|
||||
"Configuration data for policy matching on protocol instance";
|
||||
|
||||
leaf protocol-identifier {
|
||||
type identityref {
|
||||
base oc-pol-types:INSTALL_PROTOCOL_TYPE;
|
||||
}
|
||||
description
|
||||
"The identifier (protocol type) of the
|
||||
protocol instance to match on in the local network
|
||||
instance.";
|
||||
}
|
||||
|
||||
leaf protocol-name {
|
||||
type string;
|
||||
description
|
||||
"The name of the protocol instance to match
|
||||
on in the local network instance. The string
|
||||
must match one of /network-instances/
|
||||
network-instance/protocols/
|
||||
protocol/name in the local network
|
||||
instance.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping protocol-instance-policy-state {
|
||||
description
|
||||
"Operational state data for policy matching on protocol
|
||||
instance";
|
||||
}
|
||||
|
||||
grouping protocol-instance-policy-top {
|
||||
description
|
||||
"Top-level grouping for policy matching on protocol instance";
|
||||
|
||||
container match-protocol-instance {
|
||||
description
|
||||
"Top-level container for protocol instance match condition
|
||||
in policy statements. The protocol instance is referenced
|
||||
by an identifier and name";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for policy matching on protocol
|
||||
instance";
|
||||
|
||||
uses protocol-instance-policy-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for policy matching on protocol instance";
|
||||
|
||||
uses protocol-instance-policy-config;
|
||||
uses protocol-instance-policy-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
augment "/oc-rpol:routing-policy/oc-rpol:policy-definitions/" +
|
||||
"oc-rpol:policy-definition/oc-rpol:statements/oc-rpol:statement/" +
|
||||
"oc-rpol:conditions" {
|
||||
description
|
||||
"Add match conditions for protocol instances to the routing
|
||||
policy model.";
|
||||
|
||||
uses protocol-instance-policy-top;
|
||||
}
|
||||
|
||||
// rpc statements
|
||||
|
||||
// notification statements
|
||||
|
||||
}
|
||||
@@ -0,0 +1,350 @@
|
||||
module openconfig-network-instance-static {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/network-instance-static";
|
||||
|
||||
prefix "oc-ni-static";
|
||||
|
||||
import openconfig-extensions { prefix "oc-ext"; }
|
||||
import openconfig-aft { prefix "oc-aft"; }
|
||||
import openconfig-aft-types { prefix "oc-aftt"; }
|
||||
import openconfig-local-routing { prefix "oc-loc-rt"; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"Static configurations associated with a network instance";
|
||||
|
||||
oc-ext:openconfig-version "0.2.1";
|
||||
|
||||
revision "2025-08-05" {
|
||||
description
|
||||
"Fix typo in description of MPLS encapsulation headers.";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2025-07-17" {
|
||||
description
|
||||
"Adding static encapsulation headers for GRE and MPLS.";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2025-02-20" {
|
||||
description
|
||||
"Initial revision adding static next-hop-groups and encapsulation headers.";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
grouping ni-static-structural {
|
||||
description
|
||||
"Logical grouping for static configurations.";
|
||||
|
||||
container static {
|
||||
description
|
||||
"Surrounding container for static configurations.";
|
||||
|
||||
uses next-hop-groups-top {
|
||||
description
|
||||
"Configuration and state parameters relating to
|
||||
statically configured next hop group";
|
||||
}
|
||||
|
||||
uses static-next-hops-top {
|
||||
description
|
||||
"Configuration and state parameters relating to
|
||||
statically configured next hop";
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
grouping next-hop-groups-top {
|
||||
description
|
||||
"Logical grouping for statically configured next-hop-groups";
|
||||
|
||||
container next-hop-groups {
|
||||
description
|
||||
"Surrounding container for groups of next-hops.";
|
||||
|
||||
list next-hop-group {
|
||||
key "name";
|
||||
description
|
||||
"A list of user defined next-hop-groups. Each next-hop-group contains a
|
||||
list of next-hops noting where packets should be forwarded, plus any
|
||||
packet header fields that may be set. Static routes and policy-forwarding
|
||||
actions in OpenConfig may reference a next-hop-group name to indicate
|
||||
where packets should be forwarded.";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "../config/name";
|
||||
}
|
||||
description
|
||||
"A reference to a unique identifier for the next-hop-group.";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to next-hop-groups.";
|
||||
uses static-nhg-top;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"State parameters relating to next-hop-groups.";
|
||||
uses static-nhg-top;
|
||||
}
|
||||
|
||||
container next-hops {
|
||||
description
|
||||
"Surrounding container for the list of next-hops within
|
||||
the next-hop-group.";
|
||||
list next-hop {
|
||||
key "index";
|
||||
description
|
||||
"An individual next-hop within the next-hop-group. Each
|
||||
next-hop is a reference to an entry within the next-hop
|
||||
list.";
|
||||
leaf index {
|
||||
type leafref {
|
||||
path "../config/index";
|
||||
}
|
||||
description
|
||||
"A reference to the index for the next-hop within the
|
||||
the next-hop-group.";
|
||||
}
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters related to a next-hop
|
||||
within the next-hop-group.";
|
||||
uses static-nhg-next-hop;
|
||||
}
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"State parameters related to a next-hop
|
||||
within the next-hop-group.";
|
||||
uses static-nhg-next-hop;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping static-nhg-top {
|
||||
description
|
||||
"Logical grouping for statically configured next-hop-groups";
|
||||
leaf name {
|
||||
type string;
|
||||
description
|
||||
"A user defined name that uniquely identifies the next-hop-group.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping static-nhg-next-hop {
|
||||
description
|
||||
"Configuration parameters relating to an individual next-hop
|
||||
within the next-hop-group.";
|
||||
|
||||
leaf index {
|
||||
type leafref {
|
||||
// We are at network-instance/static/next-hop-groups/next-hop-group/next-hops/next-hop/index
|
||||
path "../../../../../../next-hops/next-hop/index";
|
||||
}
|
||||
|
||||
description
|
||||
"A reference to the identifier for the next-hop to which
|
||||
the entry in the next-hop group corresponds.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping static-next-hops-top {
|
||||
description
|
||||
"Logical grouping for statically configured next-hops.";
|
||||
|
||||
container next-hops {
|
||||
description
|
||||
"The list of next-hops that are to be used for entry within
|
||||
the network instance. The structure of each next-hop is address
|
||||
family independent, such that it is possible to resolve fully
|
||||
how the next-hop is treated. For example:
|
||||
- Where ingress IPv4 unicast packets are to be forwarded via
|
||||
an MPLS LSP, the next-hop list should indicate the MPLS
|
||||
label stack that is used to the next-hop.
|
||||
- Where ingress MPLS labelled packets are to be forwarded to
|
||||
an IPv6 nexthop (for example, a CE within a VPN), then the
|
||||
popped label stack, and IPv6 next-hop address should be
|
||||
indicated.";
|
||||
|
||||
list next-hop {
|
||||
key "index";
|
||||
|
||||
description
|
||||
"A next-hop associated with the forwarding instance.";
|
||||
|
||||
leaf index {
|
||||
type leafref {
|
||||
path "../config/index";
|
||||
}
|
||||
description
|
||||
"A unique index identifying the next-hop entry";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to the next-hop entry";
|
||||
|
||||
uses oc-loc-rt:local-static-nexthop-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"State parameters relating to the next-hop entry";
|
||||
|
||||
uses oc-loc-rt:local-static-nexthop-config;
|
||||
}
|
||||
|
||||
uses static-encap-headers;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping static-encap-headers {
|
||||
description
|
||||
"Grouping for encapsulation headers.";
|
||||
|
||||
container encap-headers {
|
||||
description
|
||||
"Container for packet encapsulation headers. When leaves in this
|
||||
container are populated, it indicates encapsulation of the packet
|
||||
matching the next-hop is performed using a stack of one or more
|
||||
headers defined in the list encap-header.
|
||||
Each entry in the list must indicate an encapsulation type and
|
||||
populate a container with the parameters for that encapsulation
|
||||
header.";
|
||||
|
||||
list encap-header {
|
||||
description
|
||||
"A list of headers added on top of a packet ordered by the
|
||||
index value. The inner-most header is the 0th value and is
|
||||
adjacent to the original packet. Additional headers may be
|
||||
added in index order.
|
||||
For example, in an encapsulation stack for MPLS in UDPv4, the
|
||||
first index in the list is the MPLS header and the second
|
||||
index is a UDPv4 header.";
|
||||
|
||||
key "index";
|
||||
|
||||
leaf index {
|
||||
type leafref {
|
||||
path "../config/index";
|
||||
}
|
||||
|
||||
description
|
||||
"A unique index identifying an encapsulation header in a stack
|
||||
of encapsulation headers.";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Config parameters relating to encapsulation headers.";
|
||||
|
||||
uses oc-aft:aft-common-nexthop-encap-headers-state;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"State parameters relating to encapsulation headers.";
|
||||
|
||||
uses oc-aft:aft-common-nexthop-encap-headers-state;
|
||||
}
|
||||
|
||||
container udp-v4 {
|
||||
when "../config/type = 'oc-aftt:UDPV4'";
|
||||
description
|
||||
"Container of nodes for UDP in IPv4 encapsulation. When this
|
||||
container is used, an IPv4 header with a UDP header is added
|
||||
to the encapsulation list.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to encapsulation headers.";
|
||||
|
||||
uses oc-aft:aft-common-entry-nexthop-encap-udp-v4-state;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"State parameters relating to encapsulation headers.";
|
||||
|
||||
uses oc-aft:aft-common-entry-nexthop-encap-udp-v4-state;
|
||||
}
|
||||
}
|
||||
|
||||
container gre {
|
||||
when "../config/type = 'oc-aftt:GRE'";
|
||||
description
|
||||
"Container of nodes for GRE encapsulation. When this
|
||||
container is used, a GRE header is added to the encapsulation
|
||||
list.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to GRE encapsulation headers.";
|
||||
|
||||
uses oc-aft:aft-common-entry-nexthop-encap-gre-config;
|
||||
}
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"State parameters relating to GRE encapsulation headers.";
|
||||
|
||||
uses oc-aft:aft-common-entry-nexthop-encap-gre-config;
|
||||
}
|
||||
}
|
||||
|
||||
container mpls {
|
||||
when "../config/type = 'oc-aftt:MPLS'";
|
||||
description
|
||||
"Container of nodes for MPLS encapsulation. When this
|
||||
container is used, a MPLS header is added to the encapsulation
|
||||
list. Only client configured leaves are defined. The system
|
||||
should set the MPLS TTL and Bottom of Stack bit per RFC 3032.
|
||||
To specify multiple labels, the client should create multiple
|
||||
encap-header list entries.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to MPLS encapsulation headers.";
|
||||
|
||||
uses oc-aft:aft-common-entry-nexthop-encap-mpls-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"State parameters relating to MPLS encapsulation headers.";
|
||||
|
||||
uses oc-aft:aft-common-entry-nexthop-encap-mpls-config;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,329 @@
|
||||
module openconfig-network-instance-types {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/network-instance-types";
|
||||
|
||||
prefix "oc-ni-types";
|
||||
|
||||
import openconfig-extensions { prefix "oc-ext"; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"Types associated with a network instance";
|
||||
|
||||
oc-ext:openconfig-version "0.9.3";
|
||||
|
||||
revision "2021-07-14" {
|
||||
description
|
||||
"Use auto-generated regex for route-distinguisher pattern statements";
|
||||
reference "0.9.3";
|
||||
}
|
||||
|
||||
revision "2021-06-16" {
|
||||
description
|
||||
"Remove trailing whitespace";
|
||||
reference "0.9.2";
|
||||
}
|
||||
|
||||
revision "2021-05-21" {
|
||||
description
|
||||
"Add support for evpn";
|
||||
reference "0.9.1";
|
||||
}
|
||||
|
||||
revision "2021-03-03" {
|
||||
description
|
||||
"Fix route-distinguisher's pattern statement, and remove the regexp-posix
|
||||
extension, which makes pattern statements conform to the YANG standard.";
|
||||
reference "0.9.0";
|
||||
}
|
||||
|
||||
revision "2020-06-30" {
|
||||
description
|
||||
"Add OpenConfig POSIX pattern extensions.";
|
||||
reference "0.8.3";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.8.2";
|
||||
}
|
||||
|
||||
revision "2017-08-24" {
|
||||
description
|
||||
"Minor formatting fixes";
|
||||
reference "0.8.1";
|
||||
}
|
||||
|
||||
revision "2017-02-28" {
|
||||
description
|
||||
"Add OSPFv2 to network instance";
|
||||
reference "0.8.0";
|
||||
}
|
||||
|
||||
revision "2017-01-26" {
|
||||
description
|
||||
"Add policy forwarding to network instance";
|
||||
reference "0.7.0";
|
||||
}
|
||||
|
||||
revision "2017-01-13" {
|
||||
description
|
||||
"Add AFT to the network instance";
|
||||
reference "0.6.0";
|
||||
}
|
||||
|
||||
revision "2016-12-15" {
|
||||
description
|
||||
"Add segment routing to network instance";
|
||||
reference "0.5.0";
|
||||
}
|
||||
|
||||
revision "2016-11-10" {
|
||||
description
|
||||
"Update model to include IS-IS.";
|
||||
reference "0.4.1";
|
||||
}
|
||||
|
||||
revision "2016-10-12" {
|
||||
description
|
||||
"Update table connections";
|
||||
reference "0.4.0";
|
||||
}
|
||||
|
||||
revision "2016-09-28" {
|
||||
description
|
||||
"Change L2 instance to submodule; add MAC table";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2016-08-11" {
|
||||
description
|
||||
"Resolve repeated container names in routing protocols";
|
||||
reference "0.2.3";
|
||||
}
|
||||
|
||||
revision "2016-07-08" {
|
||||
description
|
||||
"Updated with refactored routing protocol models";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2016-03-29" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2015-10-18" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
identity NETWORK_INSTANCE_TYPE {
|
||||
description
|
||||
"A base identity which can be extended to indicate different
|
||||
types of network instance supported by a device.";
|
||||
}
|
||||
|
||||
identity DEFAULT_INSTANCE {
|
||||
base NETWORK_INSTANCE_TYPE;
|
||||
description
|
||||
"A special routing instance which acts as the 'default' or
|
||||
'global' routing instance for a network device.";
|
||||
}
|
||||
|
||||
identity L3VRF {
|
||||
base NETWORK_INSTANCE_TYPE;
|
||||
description
|
||||
"A private Layer 3 only routing instance which is formed of
|
||||
one or more RIBs";
|
||||
}
|
||||
|
||||
identity L2VSI {
|
||||
base NETWORK_INSTANCE_TYPE;
|
||||
description
|
||||
"A private Layer 2 only switch instance which is formed of
|
||||
one or more L2 forwarding tables";
|
||||
}
|
||||
|
||||
identity L2P2P {
|
||||
base NETWORK_INSTANCE_TYPE;
|
||||
description
|
||||
"A private Layer 2 only forwarding instance which acts as
|
||||
a point to point connection between two endpoints";
|
||||
}
|
||||
|
||||
identity L2L3 {
|
||||
base NETWORK_INSTANCE_TYPE;
|
||||
description
|
||||
"A private Layer 2 and Layer 3 forwarding instance";
|
||||
}
|
||||
|
||||
identity ENDPOINT_TYPE {
|
||||
description
|
||||
"Specification of the type of endpoint that is being associated
|
||||
with a network instance";
|
||||
}
|
||||
|
||||
identity LOCAL {
|
||||
base ENDPOINT_TYPE;
|
||||
description
|
||||
"A local interface which is being associated with the endpoint.
|
||||
In addition, the LOCAL endpoint can be used with the VXLAN
|
||||
attributes to define a VXLAN tunnel end-point interface.";
|
||||
}
|
||||
|
||||
identity REMOTE {
|
||||
base ENDPOINT_TYPE;
|
||||
description
|
||||
"A remote interface which is being associated with the
|
||||
endpoint";
|
||||
}
|
||||
|
||||
identity LABEL_ALLOCATION_MODE {
|
||||
description
|
||||
"Base identity to be used to express types of label allocation
|
||||
strategies to be used within a network instance";
|
||||
}
|
||||
|
||||
identity PER_PREFIX {
|
||||
base LABEL_ALLOCATION_MODE;
|
||||
description
|
||||
"A label is to be allocated per prefix entry in the RIB for the
|
||||
network instance";
|
||||
}
|
||||
|
||||
identity PER_NEXTHOP {
|
||||
base LABEL_ALLOCATION_MODE;
|
||||
description
|
||||
"A label is to be allocated per nexthop entry in the RIB for
|
||||
the network instance";
|
||||
}
|
||||
|
||||
identity INSTANCE_LABEL {
|
||||
base LABEL_ALLOCATION_MODE;
|
||||
description
|
||||
"A single label is to be used for the instance";
|
||||
}
|
||||
|
||||
identity ENCAPSULATION {
|
||||
description
|
||||
"On the wire encapsulations that can be used when
|
||||
differentiating network instances";
|
||||
}
|
||||
|
||||
identity MPLS {
|
||||
base ENCAPSULATION;
|
||||
description
|
||||
"Use MPLS labels to distinguish network instances on the wire";
|
||||
}
|
||||
|
||||
identity VXLAN {
|
||||
base ENCAPSULATION;
|
||||
description
|
||||
"Use VXLAN (RFC7348) VNIs to distinguish network instances on
|
||||
the wire";
|
||||
}
|
||||
|
||||
identity SIGNALLING_PROTOCOL {
|
||||
description
|
||||
"The signalling protocol that should be used to diseminate
|
||||
entries within a forwarding instance";
|
||||
}
|
||||
|
||||
identity LDP {
|
||||
base SIGNALLING_PROTOCOL;
|
||||
description
|
||||
"Use LDP-based setup for signalling. Where the instance is
|
||||
a point-to-point service this refers to RFC4447 ('Martini')
|
||||
setup. Where the service is an L2VSI, or L2L3 instance it
|
||||
refers to RFC4762 LDP-signalled VPLS instances";
|
||||
}
|
||||
|
||||
identity BGP_VPLS {
|
||||
base SIGNALLING_PROTOCOL;
|
||||
description
|
||||
"Use BGP-based signalling and autodiscovery for VPLS instances
|
||||
as per RFC4761";
|
||||
}
|
||||
|
||||
identity BGP_EVPN {
|
||||
base SIGNALLING_PROTOCOL;
|
||||
description
|
||||
"Use BGP-based Ethernet VPN (RFC7432) based signalling for
|
||||
the network instance";
|
||||
}
|
||||
|
||||
// rjs note:
|
||||
// this should move to openconfig-types when merged
|
||||
typedef route-distinguisher {
|
||||
type union {
|
||||
// type 0: <2-byte administrator>:<4-byte assigned number>
|
||||
// <0-65535>:<0-4294967295>
|
||||
type string {
|
||||
pattern
|
||||
'([0-9]|[1-9][0-9]{1,3}|[1-5][0-9]{4}|6[0-4][0-9]{3}|'
|
||||
+ '65[0-4][0-9]{2}|655[0-2][0-9]|6553[0-5]):([0-9]|[1-9][0-9]{1,8}|'
|
||||
+ '[1-3][0-9]{9}|4[01][0-9]{8}|42[0-8][0-9]{7}|429[0-3][0-9]{6}|'
|
||||
+ '4294[0-8][0-9]{5}|42949[0-5][0-9]{4}|429496[0-6][0-9]{3}|'
|
||||
+ '4294967[01][0-9]{2}|42949672[0-8][0-9]|429496729[0-5])';
|
||||
oc-ext:posix-pattern
|
||||
'^(([0-9]|[1-9][0-9]{1,3}|[1-5][0-9]{4}|6[0-4][0-9]{3}|'
|
||||
+ '65[0-4][0-9]{2}|655[0-2][0-9]|6553[0-5]):([0-9]|[1-9][0-9]{1,8}|'
|
||||
+ '[1-3][0-9]{9}|4[01][0-9]{8}|42[0-8][0-9]{7}|429[0-3][0-9]{6}|'
|
||||
+ '4294[0-8][0-9]{5}|42949[0-5][0-9]{4}|429496[0-6][0-9]{3}|'
|
||||
+ '4294967[01][0-9]{2}|42949672[0-8][0-9]|429496729[0-5]))$';
|
||||
}
|
||||
// type 1: <ip-address>:<2-byte assigned number>
|
||||
// <ipv4>:<0-65535>
|
||||
type string {
|
||||
pattern
|
||||
'([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\.([0-9]|'
|
||||
+ '[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])){3}:([0-9]|'
|
||||
+ '[1-9][0-9]{1,3}|[1-5][0-9]{4}|6[0-4][0-9]{3}|65[0-4][0-9]{2}|'
|
||||
+ '655[0-2][0-9]|6553[0-5])';
|
||||
oc-ext:posix-pattern
|
||||
'^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\.([0-9]|'
|
||||
+ '[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])){3}:([0-9]|'
|
||||
+ '[1-9][0-9]{1,3}|[1-5][0-9]{4}|6[0-4][0-9]{3}|65[0-4][0-9]{2}|'
|
||||
+ '655[0-2][0-9]|6553[0-5]))$';
|
||||
}
|
||||
// type 2: <4-byte as-number>:<2-byte assigned number>
|
||||
// <0-4294967295>:<0-65535>
|
||||
type string {
|
||||
pattern
|
||||
'([0-9]|[1-9][0-9]{1,8}|[1-3][0-9]{9}|4[01][0-9]{8}|'
|
||||
+ '42[0-8][0-9]{7}|429[0-3][0-9]{6}|4294[0-8][0-9]{5}|'
|
||||
+ '42949[0-5][0-9]{4}|429496[0-6][0-9]{3}|4294967[01][0-9]{2}|'
|
||||
+ '42949672[0-8][0-9]|429496729[0-5]):([0-9]|[1-9][0-9]{1,3}|'
|
||||
+ '[1-5][0-9]{4}|6[0-4][0-9]{3}|65[0-4][0-9]{2}|655[0-2][0-9]|'
|
||||
+ '6553[0-5])';
|
||||
oc-ext:posix-pattern
|
||||
'^(([0-9]|[1-9][0-9]{1,8}|[1-3][0-9]{9}|4[01][0-9]{8}|'
|
||||
+ '42[0-8][0-9]{7}|429[0-3][0-9]{6}|4294[0-8][0-9]{5}|'
|
||||
+ '42949[0-5][0-9]{4}|429496[0-6][0-9]{3}|4294967[01][0-9]{2}|'
|
||||
+ '42949672[0-8][0-9]|429496729[0-5]):([0-9]|[1-9][0-9]{1,3}|'
|
||||
+ '[1-5][0-9]{4}|6[0-4][0-9]{3}|65[0-4][0-9]{2}|655[0-2][0-9]|'
|
||||
+ '6553[0-5]))$';
|
||||
}
|
||||
}
|
||||
description "A route distinguisher value";
|
||||
reference "RFC4364";
|
||||
}
|
||||
}
|
||||
1556
Parseurs_logs_Switch/src/modèles/openconfig-network-instance.yang
Normal file
1556
Parseurs_logs_Switch/src/modèles/openconfig-network-instance.yang
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,121 @@
|
||||
module openconfig-platform-boot-loader {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/platform/boot-loader";
|
||||
|
||||
prefix "oc-boot-loader";
|
||||
|
||||
import openconfig-platform { prefix oc-platform; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines data related to BOOT_LOADER components in the
|
||||
OpenConfig platform model.";
|
||||
|
||||
oc-ext:openconfig-version "0.2.0";
|
||||
|
||||
revision "2026-02-27" {
|
||||
description
|
||||
"Added uboot, linuxboot, and systemd-boot types";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2025-07-10" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
identity BOOT_LOADER_BASE {
|
||||
description
|
||||
"Base identity for boot-loader types";
|
||||
}
|
||||
|
||||
identity BOOT_LOADER_GRUB {
|
||||
base BOOT_LOADER_BASE;
|
||||
description
|
||||
"GRUB is a boot-loader and boot manager for Linux and other Unix-based
|
||||
OSes.";
|
||||
reference "https://www.gnu.org/software/grub/";
|
||||
}
|
||||
|
||||
identity BOOT_LOADER_ONIE {
|
||||
base BOOT_LOADER_BASE;
|
||||
description
|
||||
"Open Network Install Environment (ONIE) is the combination of a boot
|
||||
loader and a small operating system for network switches.
|
||||
|
||||
https://opencomputeproject.github.io/onie/overview/";
|
||||
}
|
||||
|
||||
identity BOOT_LOADER_UBOOT {
|
||||
base BOOT_LOADER_BASE;
|
||||
description
|
||||
"Das U-Boot, or the Universal Boot Loader.";
|
||||
reference "https://u-boot.org/about/";
|
||||
}
|
||||
|
||||
identity BOOT_LOADER_LINUXBOOT {
|
||||
base BOOT_LOADER_BASE;
|
||||
description
|
||||
"LinuxBoot is the concept of using a Linux kernel and initramfs as a
|
||||
bootloader.";
|
||||
reference "https://www.linuxboot.org/";
|
||||
}
|
||||
|
||||
identity BOOT_LOADER_SYSTEMD_BOOT {
|
||||
base BOOT_LOADER_BASE;
|
||||
description
|
||||
"systemd-boot, previously called gummiboot (German for 'rubber dinghy')
|
||||
and sometimes referred to as sd-boot, is an easy-to-configure UEFI boot
|
||||
manager. It provides a textual menu to select the boot entry and an editor
|
||||
for the kernel command line.";
|
||||
reference "https://systemd.io/";
|
||||
}
|
||||
|
||||
// typedef statements
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping boot-loader-state {
|
||||
description
|
||||
"Operational state data for boot-loader components";
|
||||
|
||||
leaf type {
|
||||
type identityref {
|
||||
base BOOT_LOADER_BASE;
|
||||
}
|
||||
description
|
||||
"Specifies the type of boot-loader";
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
augment "/oc-platform:components/oc-platform:component/" +
|
||||
"oc-platform:boot-loader/oc-platform:state" {
|
||||
description
|
||||
"Adding boot-loader data to component model";
|
||||
|
||||
uses boot-loader-state;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,72 @@
|
||||
module openconfig-platform-cpu {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/platform/cpu";
|
||||
|
||||
prefix "oc-cpu";
|
||||
|
||||
import openconfig-platform { prefix oc-platform; }
|
||||
import openconfig-types { prefix oc-types; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines data related to FAN components in the
|
||||
OpenConfig platform model.";
|
||||
|
||||
oc-ext:openconfig-version "0.1.1";
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.1.1";
|
||||
}
|
||||
|
||||
revision "2018-01-30" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
grouping component-cpu-utilization {
|
||||
description
|
||||
"Per-component CPU statistics";
|
||||
|
||||
container utilization {
|
||||
description
|
||||
"Statistics representing CPU utilization of the
|
||||
component.";
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state variables relating to the utilization
|
||||
of the CPU.";
|
||||
|
||||
uses oc-types:avg-min-max-instant-stats-pct;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
augment "/oc-platform:components/oc-platform:component/" +
|
||||
"oc-platform:cpu" {
|
||||
description
|
||||
"Adding CPU utilization data to component model";
|
||||
|
||||
uses component-cpu-utilization;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,82 @@
|
||||
module openconfig-platform-ext {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/platform/extension";
|
||||
|
||||
prefix "oc-platform-ext";
|
||||
|
||||
import openconfig-platform { prefix oc-platform; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines optional extensions to the OpenConfig
|
||||
platform model.";
|
||||
|
||||
oc-ext:openconfig-version "0.1.1";
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.1.1";
|
||||
}
|
||||
|
||||
revision "2018-01-18" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
// typedef statements
|
||||
|
||||
// grouping statements
|
||||
|
||||
|
||||
grouping platform-component-ext-state {
|
||||
description
|
||||
"Operational state data for platform components";
|
||||
|
||||
leaf entity-id {
|
||||
type uint32;
|
||||
description
|
||||
"A unique numeric identifier assigned by the system to the
|
||||
component. This identifier may be used to represent the
|
||||
corresponding SNMP Entity MIB identifier.";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
augment "/oc-platform:components/oc-platform:component/" +
|
||||
"oc-platform:state" {
|
||||
description
|
||||
"Adding extension state data to components";
|
||||
|
||||
uses platform-component-ext-state;
|
||||
}
|
||||
|
||||
// rpc statements
|
||||
|
||||
// notification statements
|
||||
|
||||
}
|
||||
|
||||
152
Parseurs_logs_Switch/src/modèles/openconfig-platform-fan.yang
Normal file
152
Parseurs_logs_Switch/src/modèles/openconfig-platform-fan.yang
Normal file
@@ -0,0 +1,152 @@
|
||||
module openconfig-platform-fan {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/platform/fan";
|
||||
|
||||
prefix "oc-fan";
|
||||
|
||||
import openconfig-platform { prefix oc-platform; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-alarm-types { prefix oc-alarm-types; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines data related to FAN components in the
|
||||
OpenConfig platform model.";
|
||||
|
||||
oc-ext:openconfig-version "0.2.0";
|
||||
|
||||
revision "2025-07-16" {
|
||||
description
|
||||
"Add fan alarm thresholds.";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.1.1";
|
||||
}
|
||||
|
||||
revision "2018-01-18" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
// typedef statements
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping fan-threshold-state {
|
||||
description
|
||||
"Grouping for all alarm thresholds for a particular severity level.";
|
||||
leaf severity {
|
||||
type identityref {
|
||||
base oc-alarm-types:OPENCONFIG_ALARM_SEVERITY;
|
||||
}
|
||||
description
|
||||
"The type of alarm to which the thresholds apply.";
|
||||
}
|
||||
|
||||
leaf speed-upper {
|
||||
type uint32;
|
||||
units rpm;
|
||||
description
|
||||
"Upper fan speed alarm threshold";
|
||||
}
|
||||
|
||||
leaf speed-lower {
|
||||
type uint32;
|
||||
units rpm;
|
||||
description
|
||||
"Lower fan speed alarm threshold";
|
||||
}
|
||||
}
|
||||
|
||||
grouping fan-threshold-top {
|
||||
description
|
||||
"Top-level grouping for fan speed alarm thresholds";
|
||||
|
||||
container thresholds {
|
||||
description
|
||||
"Enclosing container for fan speed alarm thresholds.";
|
||||
|
||||
list threshold {
|
||||
key "severity";
|
||||
config false;
|
||||
description
|
||||
"List of fan speed alarm thresholds, indexed by alarm severity.";
|
||||
|
||||
leaf severity {
|
||||
type leafref {
|
||||
path "../state/severity";
|
||||
}
|
||||
config false;
|
||||
description
|
||||
"The severity applied to the group of thresholds.
|
||||
An implementation's highest severity threshold
|
||||
should be mapped to OpenConfig's `CRITICAL`
|
||||
severity level.";
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational alarm thresholds for the fan.
|
||||
These thresholds should be sourced by the device manufacturer";
|
||||
uses fan-threshold-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping fan-state {
|
||||
description
|
||||
"Operational state data for fan components";
|
||||
|
||||
leaf speed {
|
||||
type uint32;
|
||||
units rpm;
|
||||
description
|
||||
"Current (instantaneous) fan speed";
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
augment "/oc-platform:components/oc-platform:component/" +
|
||||
"oc-platform:fan/oc-platform:state" {
|
||||
description
|
||||
"Adding fan data to component model";
|
||||
|
||||
uses fan-state;
|
||||
}
|
||||
|
||||
augment "/oc-platform:components/oc-platform:component/" +
|
||||
"oc-platform:fan" {
|
||||
description
|
||||
"Adding fan alarm threshold";
|
||||
|
||||
uses fan-threshold-top;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,157 @@
|
||||
module openconfig-platform-linecard {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/platform/linecard";
|
||||
|
||||
prefix "oc-linecard";
|
||||
|
||||
import openconfig-platform { prefix oc-platform; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines data related to LINECARD components in
|
||||
the openconfig-platform model";
|
||||
|
||||
oc-ext:openconfig-version "1.2.0";
|
||||
|
||||
revision "2024-04-12" {
|
||||
description
|
||||
"Add install-position, install-component and deprecate location and
|
||||
slot-id.";
|
||||
reference "1.2.0";
|
||||
}
|
||||
|
||||
revision "2023-02-13" {
|
||||
description
|
||||
"Renamed platform-utilization-top to platform-resource-utilization-top.";
|
||||
reference "1.1.0";
|
||||
}
|
||||
|
||||
revision "2022-07-28" {
|
||||
description
|
||||
"Remove leaf power-admin-state and use a common definition
|
||||
instead.";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
revision "2022-04-21" {
|
||||
description
|
||||
"Add platform utilization to linecard.";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2020-05-10" {
|
||||
description
|
||||
"Remove when statement that references read-only entity from
|
||||
a read-write context.";
|
||||
reference "0.1.2";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.1.1";
|
||||
}
|
||||
|
||||
revision "2017-08-03" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// extension statements
|
||||
|
||||
// feature statements
|
||||
|
||||
// identity statements
|
||||
|
||||
// typedef statements
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping linecard-config {
|
||||
description
|
||||
"Configuration data for linecard components";
|
||||
|
||||
uses oc-platform:component-power-management;
|
||||
}
|
||||
|
||||
grouping linecard-state {
|
||||
description
|
||||
"Operational state data for linecard components";
|
||||
|
||||
leaf slot-id {
|
||||
status deprecated;
|
||||
type string;
|
||||
description
|
||||
"Identifier for the slot or chassis position in which the
|
||||
linecard is installed.
|
||||
|
||||
This leaf is deprecated and will be replaced by install-position
|
||||
and install-component leaves in a future major revision of this
|
||||
model.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping linecard-top {
|
||||
description
|
||||
"Top-level grouping for linecard data";
|
||||
|
||||
container linecard {
|
||||
description
|
||||
"Top-level container for linecard data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for linecards";
|
||||
|
||||
uses linecard-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for linecards";
|
||||
|
||||
uses linecard-config;
|
||||
uses linecard-state;
|
||||
}
|
||||
uses oc-platform:platform-resource-utilization-top;
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
augment "/oc-platform:components/oc-platform:component" {
|
||||
description
|
||||
"Adding linecard data to physical inventory. This subtree
|
||||
is only valid when the type of the component is LINECARD.";
|
||||
|
||||
uses linecard-top;
|
||||
}
|
||||
|
||||
// rpc statements
|
||||
|
||||
// notification statements
|
||||
|
||||
}
|
||||
|
||||
146
Parseurs_logs_Switch/src/modèles/openconfig-platform-psu.yang
Normal file
146
Parseurs_logs_Switch/src/modèles/openconfig-platform-psu.yang
Normal file
@@ -0,0 +1,146 @@
|
||||
module openconfig-platform-psu {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/platform/psu";
|
||||
|
||||
prefix "oc-platform-psu";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-types { prefix oc-types; }
|
||||
import openconfig-platform { prefix oc-platform; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines a schema for power supply components in
|
||||
the OpenConfig platform model.";
|
||||
|
||||
oc-ext:openconfig-version "0.2.1";
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2018-01-16" {
|
||||
description
|
||||
"Changed admin state leaf name";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2017-12-21" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
// typedef statements
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping psu-config {
|
||||
description
|
||||
"Configuration data for power supply components";
|
||||
|
||||
leaf enabled {
|
||||
type boolean;
|
||||
default true;
|
||||
description
|
||||
"Adminsitrative control on the on/off state of the power
|
||||
supply unit.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping psu-state {
|
||||
description
|
||||
"Operational state data for power supply components";
|
||||
|
||||
|
||||
// TODO(aashaikh): May need to convert some of these to
|
||||
// interval statistics once decided on which leaves to include.
|
||||
leaf capacity {
|
||||
type oc-types:ieeefloat32;
|
||||
units watts;
|
||||
description
|
||||
"Maximum power capacity of the power supply.";
|
||||
}
|
||||
|
||||
leaf input-current {
|
||||
type oc-types:ieeefloat32;
|
||||
units amps;
|
||||
description
|
||||
"The input current draw of the power supply.";
|
||||
}
|
||||
|
||||
leaf input-voltage {
|
||||
type oc-types:ieeefloat32;
|
||||
units volts;
|
||||
description
|
||||
"Input voltage to the power supply.";
|
||||
}
|
||||
|
||||
leaf output-current {
|
||||
type oc-types:ieeefloat32;
|
||||
units amps;
|
||||
description
|
||||
"The output current supplied by the power supply.";
|
||||
}
|
||||
|
||||
leaf output-voltage {
|
||||
type oc-types:ieeefloat32;
|
||||
units volts;
|
||||
description
|
||||
"Output voltage supplied by the power supply.";
|
||||
}
|
||||
|
||||
leaf output-power {
|
||||
type oc-types:ieeefloat32;
|
||||
units watts;
|
||||
description
|
||||
"Output power supplied by the power supply.";
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
augment "/oc-platform:components/oc-platform:component/" +
|
||||
"oc-platform:power-supply/oc-platform:config" {
|
||||
description
|
||||
"Adds power supply data to component operational state.";
|
||||
|
||||
uses psu-config;
|
||||
}
|
||||
|
||||
augment "/oc-platform:components/oc-platform:component/" +
|
||||
"oc-platform:power-supply/oc-platform:state" {
|
||||
description
|
||||
"Adds power supply data to component operational state.";
|
||||
|
||||
uses psu-config;
|
||||
uses psu-state;
|
||||
}
|
||||
|
||||
|
||||
// rpc statements
|
||||
|
||||
// notification statements
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
1373
Parseurs_logs_Switch/src/modèles/openconfig-platform.yang
Normal file
1373
Parseurs_logs_Switch/src/modèles/openconfig-platform.yang
Normal file
File diff suppressed because it is too large
Load Diff
297
Parseurs_logs_Switch/src/modèles/openconfig-policy-types.yang
Normal file
297
Parseurs_logs_Switch/src/modèles/openconfig-policy-types.yang
Normal file
@@ -0,0 +1,297 @@
|
||||
module openconfig-policy-types {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/policy-types";
|
||||
|
||||
prefix "oc-pol-types";
|
||||
|
||||
// import some basic types
|
||||
import ietf-yang-types { prefix yang; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-yang-types { prefix oc-yang; }
|
||||
|
||||
// meta
|
||||
organization
|
||||
"OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
netopenconfig@googlegroups.com";
|
||||
|
||||
description
|
||||
"This module contains general data definitions for use in routing
|
||||
policy. It can be imported by modules that contain protocol-
|
||||
specific policy conditions and actions.";
|
||||
|
||||
oc-ext:openconfig-version "3.3.0";
|
||||
|
||||
revision "2024-05-14" {
|
||||
description
|
||||
"Add hex-string-prefixed to typedef tag-type.";
|
||||
reference "3.3.0";
|
||||
}
|
||||
|
||||
revision "2022-11-08" {
|
||||
description
|
||||
"Add INSTALL_PROTOCOL_TYPE local.";
|
||||
reference "3.2.3";
|
||||
}
|
||||
|
||||
revision "2022-02-11" {
|
||||
description
|
||||
"Add PCEP to INSTALL_PROTOCOL_TYPES identity";
|
||||
reference "3.2.2";
|
||||
}
|
||||
|
||||
revision "2021-12-10" {
|
||||
description
|
||||
"Add INSTALL_PROTOCOL_TYPE gRIBI.";
|
||||
reference "3.2.1";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "3.1.1";
|
||||
}
|
||||
|
||||
revision "2018-06-05" {
|
||||
description
|
||||
"Add PIM, IGMP to INSTALL_PROTOCOL_TYPES identity";
|
||||
reference "3.1.0";
|
||||
}
|
||||
|
||||
revision "2017-07-14" {
|
||||
description
|
||||
"Replace policy choice node/type with policy-result
|
||||
enumeration;simplified defined set naming;removed generic
|
||||
IGP actions; migrate to OpenConfig types; added mode for
|
||||
prefix sets";
|
||||
reference "3.0.0";
|
||||
}
|
||||
|
||||
revision "2016-05-12" {
|
||||
description
|
||||
"OpenConfig public release";
|
||||
reference "2.0.1";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
identity ATTRIBUTE_COMPARISON {
|
||||
description
|
||||
"base type for supported comparison operators on route
|
||||
attributes";
|
||||
}
|
||||
|
||||
identity ATTRIBUTE_EQ {
|
||||
base ATTRIBUTE_COMPARISON;
|
||||
description "== comparison";
|
||||
}
|
||||
|
||||
identity ATTRIBUTE_GE {
|
||||
base ATTRIBUTE_COMPARISON;
|
||||
description ">= comparison";
|
||||
}
|
||||
|
||||
identity ATTRIBUTE_LE {
|
||||
base ATTRIBUTE_COMPARISON;
|
||||
description "<= comparison";
|
||||
}
|
||||
|
||||
typedef match-set-options-type {
|
||||
type enumeration {
|
||||
enum ANY {
|
||||
description "match is true if given value matches any member
|
||||
of the defined set";
|
||||
}
|
||||
enum ALL {
|
||||
description "match is true if given value matches all
|
||||
members of the defined set";
|
||||
}
|
||||
enum INVERT {
|
||||
description "match is true if given value does not match any
|
||||
member of the defined set";
|
||||
}
|
||||
}
|
||||
default ANY;
|
||||
description
|
||||
"Options that govern the behavior of a match statement. The
|
||||
default behavior is ANY, i.e., the given value matches any
|
||||
of the members of the defined set";
|
||||
}
|
||||
|
||||
typedef match-set-options-restricted-type {
|
||||
type enumeration {
|
||||
enum ANY {
|
||||
description "match is true if given value matches any member
|
||||
of the defined set";
|
||||
}
|
||||
enum INVERT {
|
||||
description "match is true if given value does not match any
|
||||
member of the defined set";
|
||||
}
|
||||
}
|
||||
default ANY;
|
||||
description
|
||||
"Options that govern the behavior of a match statement. The
|
||||
default behavior is ANY, i.e., the given value matches any
|
||||
of the members of the defined set. Note this type is a
|
||||
restricted version of the match-set-options-type.";
|
||||
//TODO: restriction on enumerated types is only allowed in
|
||||
//YANG 1.1. Until then, we will require this additional type
|
||||
}
|
||||
|
||||
grouping attribute-compare-operators {
|
||||
description "common definitions for comparison operations in
|
||||
condition statements";
|
||||
|
||||
leaf operator {
|
||||
type identityref {
|
||||
base ATTRIBUTE_COMPARISON;
|
||||
}
|
||||
description
|
||||
"type of comparison to be performed";
|
||||
}
|
||||
|
||||
leaf value {
|
||||
type uint32;
|
||||
description
|
||||
"value to compare with the community count";
|
||||
}
|
||||
}
|
||||
|
||||
typedef tag-type {
|
||||
type union {
|
||||
type uint32;
|
||||
type yang:hex-string;
|
||||
type oc-yang:hex-string-prefixed {
|
||||
length "3..18";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Type for expressing route tags on a local system, including IS-IS
|
||||
and OSPF; This may be expressed as either decimal or hexidecimal
|
||||
integer.";
|
||||
reference
|
||||
"RFC 2178 OSPF Version 2 specifies a 32 bit value
|
||||
RFC 5130 A Policy Control Mechanism in IS-IS Using
|
||||
Administrative Tags specifies 32 bit and 64 bit values.";
|
||||
}
|
||||
|
||||
identity INSTALL_PROTOCOL_TYPE {
|
||||
description
|
||||
"Base type for routing protocols, including those which may
|
||||
install prefixes into the RIB";
|
||||
}
|
||||
|
||||
identity BGP {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"BGP";
|
||||
reference
|
||||
"RFC 4271";
|
||||
}
|
||||
|
||||
identity ISIS {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"IS-IS";
|
||||
reference
|
||||
"ISO/IEC 10589";
|
||||
}
|
||||
|
||||
identity OSPF {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"OSPFv2";
|
||||
reference
|
||||
"RFC 2328";
|
||||
}
|
||||
|
||||
identity OSPF3 {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"OSPFv3";
|
||||
reference
|
||||
"RFC 5340";
|
||||
}
|
||||
|
||||
identity STATIC {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"Locally-installed static route";
|
||||
}
|
||||
|
||||
identity DIRECTLY_CONNECTED {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"A directly connected route";
|
||||
}
|
||||
|
||||
identity LOCAL_AGGREGATE {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"Locally defined aggregate route";
|
||||
}
|
||||
|
||||
identity PIM {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"Protocol Independent Multicast";
|
||||
reference
|
||||
"RFC 7761";
|
||||
}
|
||||
|
||||
identity IGMP {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"Internet Group Management Protocol";
|
||||
reference
|
||||
"RFC 3376";
|
||||
}
|
||||
|
||||
identity GRIBI {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description "gRPC Routing Information Base Interface";
|
||||
}
|
||||
|
||||
identity PCEP {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"Path Computation Element Communication Protocol";
|
||||
reference
|
||||
"RFC 5440";
|
||||
}
|
||||
|
||||
identity LOCAL {
|
||||
base INSTALL_PROTOCOL_TYPE;
|
||||
description
|
||||
"A local route.
|
||||
|
||||
Local routes define a route for the one specific IP
|
||||
address configured on the router interface. They are
|
||||
created in association with directly connected routes.
|
||||
Local routes must end with a /32 in the case of ipv4
|
||||
or /128 for ipv6.
|
||||
For example, when configuring an interface with the ip
|
||||
address
|
||||
|
||||
10.244.136.79/31
|
||||
|
||||
the derived DIRECTLY_CONNECTED route is
|
||||
|
||||
10.244.136.78/31
|
||||
|
||||
and the derived LOCAL route is
|
||||
|
||||
10.244.136.79/32.";
|
||||
}
|
||||
}
|
||||
1057
Parseurs_logs_Switch/src/modèles/openconfig-qos-interfaces.yang
Normal file
1057
Parseurs_logs_Switch/src/modèles/openconfig-qos-interfaces.yang
Normal file
File diff suppressed because it is too large
Load Diff
171
Parseurs_logs_Switch/src/modèles/openconfig-qos-types.yang
Normal file
171
Parseurs_logs_Switch/src/modèles/openconfig-qos-types.yang
Normal file
@@ -0,0 +1,171 @@
|
||||
module openconfig-qos-types {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/qos-types";
|
||||
|
||||
prefix "oc-qos-types";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines types and identities used in OpenConfig
|
||||
models related to quality-of-service (QoS)";
|
||||
|
||||
oc-ext:openconfig-version "1.0.1";
|
||||
|
||||
revision "2026-01-06" {
|
||||
description
|
||||
"Fix typo in description for minimum and maximum queue thresholds.";
|
||||
reference "1.0.1";
|
||||
}
|
||||
|
||||
revision "2025-12-16" {
|
||||
description
|
||||
"Bump version to 1.0.0";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2016-12-16" {
|
||||
description
|
||||
"Fix incorrect interface-ref placement";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2016-08-08" {
|
||||
description
|
||||
"Initial revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// extension statements
|
||||
|
||||
// feature statements
|
||||
|
||||
// identity statements
|
||||
|
||||
identity QOS_QUEUE_TYPE {
|
||||
description
|
||||
"Base identity for supported queue types, primarily
|
||||
defined by their drop behavior / strategy";
|
||||
}
|
||||
|
||||
identity DROP_TAIL {
|
||||
base QOS_QUEUE_TYPE;
|
||||
description
|
||||
"When the queue is filled to capacity, newly arriving packets
|
||||
are discarded until there is room in the queue to accept new
|
||||
traffic. Packets are not differentiated, i.e., all packets
|
||||
are treated identically.";
|
||||
}
|
||||
|
||||
identity RED {
|
||||
base QOS_QUEUE_TYPE;
|
||||
description
|
||||
"Queue management based on Random Early Detection (RED). RED
|
||||
drops packets based on a drop probability that is based on the
|
||||
average queue length, and settings of minimum and maximum
|
||||
queue thresholds. On ECN-capable devices, packets may be
|
||||
marked instead of dropped to signal congestion to the
|
||||
sender.";
|
||||
reference
|
||||
"IETF RFC 2309 - Recommendations on Queue Management and
|
||||
Congestion Avoidance in the Internet
|
||||
IETF RFC 7567 - IETF Recommendations Regarding Active Queue
|
||||
Management";
|
||||
}
|
||||
|
||||
identity WRED {
|
||||
base QOS_QUEUE_TYPE;
|
||||
description
|
||||
"Queue management based on a variant of RED in which the packet
|
||||
drop probability is based on its traffic class.";
|
||||
}
|
||||
|
||||
identity QOS_SCHEDULER_TYPE {
|
||||
description
|
||||
"Base identity to describe supported QoS scheduler types.";
|
||||
}
|
||||
|
||||
identity ONE_RATE_TWO_COLOR {
|
||||
base QOS_SCHEDULER_TYPE;
|
||||
description
|
||||
"Token bucket scheduler with a single rate (committed information
|
||||
rate) and two colors (conforming and exceeding). The scheduler
|
||||
behavior is governed by two parameters, the CIR which
|
||||
determines the rate of token fill (bps) and the committed
|
||||
burst size (depth of the token bucket in bytes).";
|
||||
}
|
||||
|
||||
identity TWO_RATE_THREE_COLOR {
|
||||
base QOS_SCHEDULER_TYPE;
|
||||
description
|
||||
"Token bucket scheduler with two buckets, one filled at the
|
||||
committed information rate (CIR) in bps, and the second filled
|
||||
at the peak information rate (PIR) in bps when the first
|
||||
bucket is full. The first bucket depth is
|
||||
the committed burst size (bytes), and the second is the
|
||||
excess burst size (bytes). Traffic is categorized in three
|
||||
colors as follows: traffic that falls within the
|
||||
the CIR is conforming, traffic that is greater than the CIR
|
||||
but less than the PIR is exceeding, and traffic that is
|
||||
greater than PIR is violating.";
|
||||
}
|
||||
|
||||
// typedef statements
|
||||
|
||||
typedef queue-behavior {
|
||||
type enumeration {
|
||||
enum SHAPE {
|
||||
description
|
||||
"Packets that exceed the CIR should be queued into a
|
||||
buffer. The depth of the buffer is specified to be
|
||||
max-queue-depth-bytes or max-queue-depth-packets.
|
||||
Packets are subsequently scheduled from this queue
|
||||
to the specified output. Only packets that overflow
|
||||
the buffer have the exceed action applied to them.";
|
||||
}
|
||||
enum POLICE {
|
||||
description
|
||||
"Packets that exceed the CIR should be immediately
|
||||
treated as exceeding the defined rate of the scheduler
|
||||
and have the exceed action applied to them.";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Type definition for different queueing behaviours that
|
||||
are available to a scheduler.";
|
||||
}
|
||||
|
||||
// grouping statements
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
// rpc statements
|
||||
|
||||
// notification statements
|
||||
|
||||
}
|
||||
269
Parseurs_logs_Switch/src/modèles/openconfig-qos.yang
Normal file
269
Parseurs_logs_Switch/src/modèles/openconfig-qos.yang
Normal file
@@ -0,0 +1,269 @@
|
||||
module openconfig-qos {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/qos";
|
||||
|
||||
prefix "oc-qos";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
// include submodules
|
||||
include openconfig-qos-interfaces;
|
||||
include openconfig-qos-elements;
|
||||
include openconfig-qos-mem-mgmt;
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines configuration and operational state data
|
||||
related to network quality-of-service.";
|
||||
|
||||
oc-ext:openconfig-version "2.1.0";
|
||||
|
||||
revision "2026-03-25" {
|
||||
description
|
||||
"Add parameters for packet trimming configuration";
|
||||
reference "2.1.0";
|
||||
}
|
||||
|
||||
revision "2026-01-24" {
|
||||
description
|
||||
"Bump version to 2.0.1";
|
||||
reference "2.0.1";
|
||||
}
|
||||
|
||||
revision "2026-01-16" {
|
||||
description
|
||||
"Revert percentage types to uint64 with appropriate
|
||||
scoping/units";
|
||||
reference "2.0.0";
|
||||
}
|
||||
|
||||
revision "2025-12-16" {
|
||||
description
|
||||
"Bump version to 1.0.0";
|
||||
reference "1.0.0";
|
||||
}
|
||||
|
||||
revision "2023-10-13" {
|
||||
description
|
||||
"Fix revision statement date";
|
||||
reference "0.11.2";
|
||||
}
|
||||
|
||||
revision "2023-10-08" {
|
||||
description
|
||||
"Clarification on WRED weight in case it is not present";
|
||||
reference "0.11.1";
|
||||
}
|
||||
|
||||
revision "2023-09-15" {
|
||||
description
|
||||
"Add support for ECN counters";
|
||||
reference "0.11.0";
|
||||
}
|
||||
|
||||
revision "2023-07-26" {
|
||||
description
|
||||
"Add buffer management parameters in time unts (microseconds).
|
||||
Make profiles reusable across LAGs and PHY of different speed";
|
||||
reference "0.10.0";
|
||||
}
|
||||
|
||||
revision "2023-04-25" {
|
||||
description
|
||||
"Clarify interface-ref usage.";
|
||||
reference "0.9.1";
|
||||
}
|
||||
|
||||
revision "2023-04-17" {
|
||||
description
|
||||
"Add support for relative RED min-threshold and max-threshold values.";
|
||||
reference "0.9.0";
|
||||
}
|
||||
|
||||
revision "2023-02-17" {
|
||||
description
|
||||
"Add queue identifier.";
|
||||
reference "0.8.0";
|
||||
}
|
||||
|
||||
revision "2023-02-08" {
|
||||
description
|
||||
"Remove incorrect output placement of interface-ref";
|
||||
reference "0.7.0";
|
||||
}
|
||||
|
||||
revision "2023-01-28" {
|
||||
description
|
||||
"Split groupings in interfaces for better leaf reuse.";
|
||||
reference "0.6.1";
|
||||
}
|
||||
|
||||
revision "2022-09-13" {
|
||||
description
|
||||
"Add queue octet drop counter.";
|
||||
reference "0.6.0";
|
||||
}
|
||||
|
||||
revision "2021-08-28" {
|
||||
description
|
||||
"Revision using latest revision of openconfig-qos-mem-mgmt submodule.";
|
||||
reference "0.5.0";
|
||||
}
|
||||
|
||||
revision "2021-06-28" {
|
||||
description
|
||||
"Revision to include buffer-allocation-profile-q-config
|
||||
parameters in openconfig-qos-mem-mgmt submodule.";
|
||||
reference "0.4.0";
|
||||
}
|
||||
|
||||
revision "2021-04-28" {
|
||||
description
|
||||
"Revision updating buffer management and queue management
|
||||
configuration.";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2019-11-28" {
|
||||
description
|
||||
"Fix xpaths in when statements";
|
||||
reference "0.2.3";
|
||||
}
|
||||
|
||||
revision "2019-08-20" {
|
||||
description
|
||||
"Fix typo in classifiers container name";
|
||||
reference "0.2.2";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2016-12-16" {
|
||||
description
|
||||
"Fix incorrect interface-ref placement";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// grouping statements
|
||||
grouping qos-config {
|
||||
description
|
||||
"Configuration data for global QoS";
|
||||
}
|
||||
|
||||
grouping qos-state {
|
||||
description
|
||||
"Operational state data for global QoS";
|
||||
}
|
||||
|
||||
grouping qos-packet-trim-top {
|
||||
description
|
||||
"Top-level grouping for packet trimming.";
|
||||
|
||||
container packet-trim {
|
||||
description
|
||||
"Container for switch level packet trimming
|
||||
parameters.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for switch level packet
|
||||
trimming parameters.";
|
||||
|
||||
uses packet-trim-config;
|
||||
}
|
||||
container state {
|
||||
description
|
||||
"Operational state data for switch level packet
|
||||
trimming parameters.";
|
||||
config false;
|
||||
|
||||
uses packet-trim-config;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping packet-trim-config {
|
||||
description
|
||||
"Top-level grouping for switch level packet
|
||||
trimming parameters";
|
||||
leaf symmetric-dscp {
|
||||
type uint8;
|
||||
description
|
||||
"The DSCP value for the notification packet
|
||||
(sometimes called a 'symmetric packet') sent back
|
||||
to the source when a packet is trimmed.";
|
||||
}
|
||||
leaf fabric-priority {
|
||||
type uint8;
|
||||
description
|
||||
"Traffic class used to transmit trimmed
|
||||
packets.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping qos-top {
|
||||
description
|
||||
"Top-level grouping for QoS model";
|
||||
|
||||
container qos {
|
||||
description
|
||||
"Top-level container for QoS data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for global QoS";
|
||||
|
||||
uses qos-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
description
|
||||
"Operational state data for global QoS";
|
||||
|
||||
config false;
|
||||
uses qos-config;
|
||||
uses qos-state;
|
||||
}
|
||||
|
||||
uses qos-interfaces-top;
|
||||
uses qos-classifier-top;
|
||||
uses qos-forwarding-group-top;
|
||||
uses qos-queue-top;
|
||||
uses qos-scheduler-top;
|
||||
uses qos-buffer-profile-top;
|
||||
uses qos-queue-mgmt-profile-top;
|
||||
uses qos-packet-trim-top;
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
uses qos-top;
|
||||
|
||||
// augment statements
|
||||
|
||||
// rpc statements
|
||||
|
||||
// notification statements
|
||||
|
||||
}
|
||||
833
Parseurs_logs_Switch/src/modèles/openconfig-relay-agent.yang
Normal file
833
Parseurs_logs_Switch/src/modèles/openconfig-relay-agent.yang
Normal file
@@ -0,0 +1,833 @@
|
||||
module openconfig-relay-agent {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/relay-agent";
|
||||
|
||||
prefix "oc-relay";
|
||||
|
||||
// import some basic types
|
||||
import ietf-inet-types { prefix inet; }
|
||||
import ietf-yang-types { prefix yang; }
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module describes a model for configuration and operational
|
||||
state related to relay agents typically used for DHCP and BOOTP
|
||||
packets. The supports both DHCP and DHCPv6 and device-wide and
|
||||
per-interface settings.";
|
||||
|
||||
oc-ext:openconfig-version "0.1.2";
|
||||
|
||||
revision "2023-02-06" {
|
||||
description
|
||||
"Clarify usage of interface-ref.";
|
||||
reference "0.1.2";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.1.1";
|
||||
}
|
||||
|
||||
revision "2016-05-16" {
|
||||
description
|
||||
"Initial public release";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping agent-information-ipv4-common-config {
|
||||
description
|
||||
"Common configuration data for DHCP relay option";
|
||||
|
||||
leaf enable {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"Enable sending the DHCP option for Relay Agent information
|
||||
-- option 82.";
|
||||
reference
|
||||
"RFC 3046 - DHCP Relay Agent Information Option";
|
||||
}
|
||||
}
|
||||
|
||||
grouping agent-information-ipv4-common-state {
|
||||
description
|
||||
"Common operational state data for DHCP relay option";
|
||||
|
||||
}
|
||||
|
||||
grouping agent-information-ipv4-global-top {
|
||||
description
|
||||
"Top-level grouping for agent information data at global level";
|
||||
|
||||
container agent-information-option {
|
||||
description
|
||||
"Top-level container for relay agent information option
|
||||
data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for the relay agent information
|
||||
option";
|
||||
|
||||
uses agent-information-ipv4-common-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for agent information at global
|
||||
level";
|
||||
|
||||
uses agent-information-ipv4-common-config;
|
||||
uses agent-information-ipv4-common-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping agent-information-ipv4-interface-config {
|
||||
description
|
||||
"Configuration data for DCHP relay option on interfaces";
|
||||
|
||||
leaf circuit-id {
|
||||
type string;
|
||||
description
|
||||
"Encodes an agent-local identifier of the circuit from which
|
||||
a DHCP client-to-server packet was received. It is intended
|
||||
for use by agents in relaying DHCP responses back to the
|
||||
proper circuit. The circuit id is an opaque value";
|
||||
reference
|
||||
"RFC 3046 - DHCP Relay Agent Information Option";
|
||||
}
|
||||
|
||||
leaf remote-id {
|
||||
type string;
|
||||
description
|
||||
"Provides a mechanism to identify the remote host end of
|
||||
the circuit. The remote-id should be thought of as an
|
||||
opaque value, but must be globally unique.";
|
||||
reference
|
||||
"RFC 3046 - DHCP Relay Agent Information Option";
|
||||
}
|
||||
}
|
||||
|
||||
grouping agent-information-ipv4-interface-state {
|
||||
description
|
||||
"Operational state data for DHCP relay option on interfaces";
|
||||
|
||||
leaf sent-circuit-id {
|
||||
type string;
|
||||
description
|
||||
"Reports the circuit-id sent by the system to the DHCP
|
||||
server.";
|
||||
}
|
||||
|
||||
leaf sent-remote-id {
|
||||
type string;
|
||||
description
|
||||
"Reports the remote-id value sent by the system to the DHCP
|
||||
server";
|
||||
}
|
||||
}
|
||||
|
||||
grouping agent-information-ipv4-interface-top {
|
||||
description
|
||||
"Top-level grouping for relay agent information option data";
|
||||
|
||||
container agent-information-option {
|
||||
description
|
||||
"Top-level container for relay agent information option
|
||||
data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for the relay agent information
|
||||
option";
|
||||
|
||||
uses agent-information-ipv4-common-config;
|
||||
uses agent-information-ipv4-interface-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data ";
|
||||
|
||||
uses agent-information-ipv4-common-config;
|
||||
uses agent-information-ipv4-interface-config;
|
||||
uses agent-information-ipv4-common-state;
|
||||
uses agent-information-ipv4-interface-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping agent-options-ipv6-common-config {
|
||||
description
|
||||
"Configuration data for DHCPv6 options";
|
||||
|
||||
leaf enable-interface-id {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"Enables DHCPv6 OPTION_INTERFACE_ID (18) to identify the
|
||||
interface on which the client message was received.";
|
||||
reference
|
||||
"IETF RFC 3315 - Dynamic Host Configuration Protocol for
|
||||
IPv6 (DHCPv6)";
|
||||
}
|
||||
|
||||
leaf enable-remote-id {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"Sets DHCPv6 OPTION_REMOTE_ID (37). This option is the
|
||||
DHCPv6 equivalent for the IPv4 (DHCPv4) Relay Agent Option's
|
||||
Remote-ID suboption as specified in RFC 3046. The remote-id
|
||||
field may be used to encode a user name, remote IP address,
|
||||
interface/port identifier, etc.";
|
||||
reference
|
||||
"IETF RFC 4649 - Dynamic Host Configuration Protocol for
|
||||
IPv6 (DHCPv6) Relay Agent Remote-ID Option";
|
||||
}
|
||||
}
|
||||
|
||||
grouping agent-options-ipv6-common-state {
|
||||
description
|
||||
"Operational state data for DHCPv6 options";
|
||||
}
|
||||
|
||||
grouping agent-options-ipv6-interface-config {
|
||||
description
|
||||
"Configuration data for DHCPv6 options";
|
||||
|
||||
leaf interface-id {
|
||||
type string;
|
||||
description
|
||||
"Sets DHCPv6 OPTION_INTERFACE_ID (18) to identify the
|
||||
interface on which the client message was received.";
|
||||
reference
|
||||
"IETF RFC 3315 - Dynamic Host Configuration Protocol for
|
||||
IPv6 (DHCPv6)";
|
||||
}
|
||||
|
||||
leaf remote-id {
|
||||
type string;
|
||||
description
|
||||
"Sets DHCPv6 OPTION_REMOTE_ID (37). This option is the
|
||||
DHCPv6 equivalent for the IPv4 (DHCPv4) Relay Agent Option's
|
||||
Remote-ID suboption as specified in RFC 3046. The remote-id
|
||||
field may be used to encode a user name, remote IP address,
|
||||
interface/port identifier, etc.";
|
||||
reference
|
||||
"IETF RFC 4649 - Dynamic Host Configuration Protocol for
|
||||
IPv6 (DHCPv6) Relay Agent Remote-ID Option";
|
||||
}
|
||||
}
|
||||
|
||||
grouping agent-options-ipv6-interface-state {
|
||||
description
|
||||
"Operational state data for DHCPv6 options";
|
||||
|
||||
leaf sent-interface-id {
|
||||
type string;
|
||||
description
|
||||
"Reflects the DHCPv6 OPTION_INTERFACE_ID (18) sent to the
|
||||
server by the system.";
|
||||
reference
|
||||
"IETF RFC 3315 - Dynamic Host Configuration Protocol for
|
||||
IPv6 (DHCPv6)";
|
||||
}
|
||||
|
||||
leaf sent-remote-id {
|
||||
type string;
|
||||
description
|
||||
"Reflects the DHCPv6 OPTION_REMOTE_ID (37) sent to the
|
||||
server by the system.";
|
||||
reference
|
||||
"IETF RFC 4649 - Dynamic Host Configuration Protocol for
|
||||
IPv6 (DHCPv6) Relay Agent Remote-ID Option";
|
||||
}
|
||||
}
|
||||
|
||||
grouping agent-options-ipv6-global-top {
|
||||
description
|
||||
"Top-level grouping for DHCPv6 options on interfaces";
|
||||
|
||||
container options {
|
||||
description
|
||||
"Top-level container for DHCPv6 agent options on interfaces";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data ";
|
||||
|
||||
uses agent-options-ipv6-common-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for DHCPv6 agent option on an
|
||||
interface";
|
||||
|
||||
uses agent-options-ipv6-common-config;
|
||||
uses agent-options-ipv6-common-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping agent-options-ipv6-interface-top {
|
||||
description
|
||||
"Top-level grouping for DHCPv6 options on interfaces";
|
||||
|
||||
container options {
|
||||
description
|
||||
"Top-level container for DHCPv6 agent options on interfaces";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data ";
|
||||
|
||||
uses agent-options-ipv6-common-config;
|
||||
uses agent-options-ipv6-interface-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for DHCPv6 agent option on an
|
||||
interface";
|
||||
|
||||
uses agent-options-ipv6-common-config;
|
||||
uses agent-options-ipv6-interface-config;
|
||||
uses agent-options-ipv6-common-state;
|
||||
uses agent-options-ipv6-interface-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-common-config {
|
||||
description
|
||||
"Configuration data for global level relay agent options,
|
||||
common across address families";
|
||||
|
||||
leaf enable-relay-agent {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"Enables DHCP/BOOTP relay agent on all interfaces";
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-common-state {
|
||||
description
|
||||
"Operational state data for global level relay agent, common
|
||||
across address families";
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv4-config {
|
||||
description
|
||||
"Configuration data for DHCPv4 relay agents";
|
||||
|
||||
uses relay-agent-common-config;
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv4-state {
|
||||
description
|
||||
"Configuration data for DHCPv4 relay agents";
|
||||
|
||||
uses relay-agent-common-state;
|
||||
}
|
||||
|
||||
|
||||
grouping relay-agent-ipv4-top {
|
||||
description
|
||||
"Top-level grouping for global relay agent data";
|
||||
|
||||
container dhcp {
|
||||
description
|
||||
"Top-level container for global relay agent data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for global DHCPv4";
|
||||
|
||||
uses relay-agent-ipv4-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data global DHCPv4";
|
||||
|
||||
uses relay-agent-ipv4-config;
|
||||
uses relay-agent-ipv4-state;
|
||||
}
|
||||
|
||||
uses agent-information-ipv4-global-top;
|
||||
uses relay-agent-ipv4-interfaces-top;
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv6-config {
|
||||
description
|
||||
"Configuration data for DHCPv6 relay agents";
|
||||
|
||||
uses relay-agent-common-config;
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv6-state {
|
||||
description
|
||||
"Configuration data for DHCPv6 relay agents";
|
||||
|
||||
uses relay-agent-common-state;
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv6-top {
|
||||
description
|
||||
"Top-level grouping for global relay agent data";
|
||||
|
||||
container dhcpv6 {
|
||||
description
|
||||
"Top-level container for global relay agent data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for global DHCPv6";
|
||||
|
||||
uses relay-agent-ipv6-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data global DHCPv6";
|
||||
|
||||
uses relay-agent-ipv6-config;
|
||||
uses relay-agent-ipv6-state;
|
||||
}
|
||||
|
||||
uses agent-options-ipv6-global-top;
|
||||
uses relay-agent-ipv6-interfaces-top;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
grouping relay-agent-common-stats {
|
||||
description
|
||||
"Common DHCP / BOOTP message statistics for
|
||||
DHCPv4 and DHCPv6";
|
||||
|
||||
|
||||
leaf total-dropped {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Total number of DHCP packets dropped by the relay agent";
|
||||
}
|
||||
|
||||
leaf invalid-opcode {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCP packets dropped due to an invalid opcode";
|
||||
}
|
||||
|
||||
leaf invalid-options {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCP packets dropped due to an invalid option";
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv4-stats {
|
||||
description
|
||||
"DHCPv4 relay agent message statistics";
|
||||
|
||||
leaf bootrequest-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"BOOTREQUEST messages received by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcp-decline-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"DHCP DECLINE messages received by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcp-discover-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"DHCP DISCOVER messages received by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcp-inform-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"DHCP INFORM messages received by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcp-release-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"DHCP RELEASE messages received by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcp-request-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"DHCP REQUEST messages received by the relay agent";
|
||||
}
|
||||
|
||||
leaf bootrequest-sent {
|
||||
type yang:counter64;
|
||||
description
|
||||
"BOOTREQUEST messages forwarded by the relay agent";
|
||||
}
|
||||
|
||||
leaf bootreply-sent {
|
||||
type yang:counter64;
|
||||
description
|
||||
"BOOTREPLY messages forwarded by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcp-offer-sent {
|
||||
type yang:counter64;
|
||||
description
|
||||
"DHCP OFFER messages sent by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcp-ack-sent {
|
||||
type yang:counter64;
|
||||
description
|
||||
"DHCP ACK messages sent by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcp-nack-sent {
|
||||
type yang:counter64;
|
||||
description
|
||||
"DHCP NACK messages sent by the relay agent";
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv6-stats {
|
||||
description
|
||||
"DHCPv4 relay agent message statistics";
|
||||
|
||||
leaf dhcpv6-solicit-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 SOLICIT messages received from clients
|
||||
by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-decline-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 DECLINE messages received from
|
||||
clients by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-request-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 request messages received from clients
|
||||
by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-release-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 release messages received from clients
|
||||
by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-confirm-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 confirm messages received from clients
|
||||
by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-rebind-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 rebind messages received from clients
|
||||
by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-info-request-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 information requests messages received from
|
||||
clients by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-relay-reply-received {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 relay reply messages received from servers
|
||||
by the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-adverstise-sent {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 adverstise messages sent to clients by
|
||||
the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-reply-sent {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 reply messages sent to clients by
|
||||
the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-reconfigure-sent {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 reconfigure messages sent to clients by
|
||||
the relay agent";
|
||||
}
|
||||
|
||||
leaf dhcpv6-relay-forw-sent {
|
||||
type yang:counter64;
|
||||
description
|
||||
"Number of DHCPv6 relay-forward messages sent to servers
|
||||
by the relay agent";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv4-interfaces-config {
|
||||
description
|
||||
"Configuration data for interfaces enabled for relaying";
|
||||
|
||||
leaf id {
|
||||
type oc-if:interface-id;
|
||||
description
|
||||
"Name of the interface on which relay agent is active";
|
||||
}
|
||||
|
||||
leaf enable {
|
||||
type boolean;
|
||||
description
|
||||
"Enables the relay agent on the referenced interface.
|
||||
At least one helper address should also be configured
|
||||
for forwarding requested.";
|
||||
}
|
||||
|
||||
leaf-list helper-address {
|
||||
type inet:ip-address;
|
||||
description
|
||||
"List of IPv4 or IPv6 addresses of DHCP servers to which the
|
||||
relay agent should forward DHCPv4 requests. The relay agent is
|
||||
expected to forward DHCPv4/BOOTP requests to all listed
|
||||
server addresses when DHCPv4 relaying is enabled globally, or
|
||||
on the interface.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv4-interfaces-state {
|
||||
description
|
||||
"Operational state data for interfaces enabled for relaying";
|
||||
|
||||
container counters {
|
||||
description
|
||||
"Counters and statistics for relay agent operation.";
|
||||
|
||||
uses relay-agent-common-stats;
|
||||
uses relay-agent-ipv4-stats;
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv4-interfaces-top {
|
||||
description
|
||||
"Top-level grouping for DHCPv4 relays on interfaces";
|
||||
|
||||
container interfaces {
|
||||
description
|
||||
"Enclosing container for the list of interface references.";
|
||||
|
||||
list interface {
|
||||
key "id";
|
||||
description
|
||||
"List of interfaces on which the relay agent is
|
||||
configured.
|
||||
|
||||
The interface referenced is based on the interface and
|
||||
subinterface leaves within the interface-ref container -
|
||||
which reference an entry in the /interfaces/interface list -
|
||||
and should not rely on the value of the list key.";
|
||||
|
||||
leaf id {
|
||||
type leafref {
|
||||
path "../config/id";
|
||||
}
|
||||
description
|
||||
"Reference to the interface list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for relay agent interfaces.";
|
||||
|
||||
uses relay-agent-ipv4-interfaces-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for relay agent interfaces.";
|
||||
|
||||
uses relay-agent-ipv4-interfaces-config;
|
||||
uses relay-agent-ipv4-interfaces-state;
|
||||
}
|
||||
|
||||
uses oc-if:interface-ref;
|
||||
uses agent-information-ipv4-interface-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv6-interfaces-config {
|
||||
description
|
||||
"Configuration data for interfaces enabled for relaying";
|
||||
|
||||
leaf id {
|
||||
type oc-if:interface-id;
|
||||
description
|
||||
"Name of the interface on which relay agent is active";
|
||||
}
|
||||
|
||||
leaf enable {
|
||||
type boolean;
|
||||
description
|
||||
"Enables the relay agent on the referenced interface.
|
||||
At least one helper address should also be configured
|
||||
for forwarding requested.";
|
||||
}
|
||||
|
||||
leaf-list helper-address {
|
||||
type inet:ipv6-address;
|
||||
description
|
||||
"List of IPv6 addresses of DHCP servers to which the
|
||||
relay agent should forward DHCPv6 requests. The relay agent
|
||||
is expected to forward DHCPv4/BOOTP requests to all listed
|
||||
server addresses when DHCPv6 relaying is enabled globally, or
|
||||
on the interface.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv6-interfaces-state {
|
||||
description
|
||||
"Operational state data for interfaces enabled for relaying";
|
||||
|
||||
container counters {
|
||||
description
|
||||
"Counters and statistics for relay agent operation.";
|
||||
|
||||
uses relay-agent-common-stats;
|
||||
uses relay-agent-ipv6-stats;
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-ipv6-interfaces-top {
|
||||
description
|
||||
"Top-level grouping for DHCPv4 relays on interfaces";
|
||||
|
||||
container interfaces {
|
||||
description
|
||||
"Enclosing container for the list of interface references.";
|
||||
|
||||
list interface {
|
||||
key "id";
|
||||
description
|
||||
"List of interfaces on which the relay agent is
|
||||
configured.
|
||||
|
||||
The interface referenced is based on the interface and
|
||||
subinterface leaves within the interface-ref container -
|
||||
which reference an entry in the /interfaces/interface list -
|
||||
and should not rely on the value of the list key.";
|
||||
|
||||
leaf id {
|
||||
type leafref {
|
||||
path "../config/id";
|
||||
}
|
||||
description
|
||||
"Reference to the interface list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for relay agent interfaces.";
|
||||
|
||||
uses relay-agent-ipv6-interfaces-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for relay agent interfaces.";
|
||||
|
||||
uses relay-agent-ipv6-interfaces-config;
|
||||
uses relay-agent-ipv6-interfaces-state;
|
||||
}
|
||||
|
||||
uses oc-if:interface-ref;
|
||||
uses agent-options-ipv6-interface-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping relay-agent-top {
|
||||
description
|
||||
"Top-level container for relay agent configuration and opstate
|
||||
data.";
|
||||
|
||||
container relay-agent {
|
||||
description
|
||||
"Top level container for relay-agent configuration and
|
||||
operational state data";
|
||||
|
||||
uses relay-agent-ipv4-top;
|
||||
uses relay-agent-ipv6-top;
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
uses relay-agent-top;
|
||||
|
||||
// augment statements
|
||||
|
||||
|
||||
}
|
||||
1379
Parseurs_logs_Switch/src/modèles/openconfig-routing-policy.yang
Normal file
1379
Parseurs_logs_Switch/src/modèles/openconfig-routing-policy.yang
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,265 @@
|
||||
module openconfig-spanning-tree-types {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/spanning-tree/types";
|
||||
|
||||
prefix "oc-stp-types";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines types related to the
|
||||
spanning-tree protocol model.";
|
||||
|
||||
oc-ext:openconfig-version "0.4.1";
|
||||
|
||||
revision "2021-06-16" {
|
||||
description
|
||||
"Remove trailing whitespace";
|
||||
reference "0.4.1";
|
||||
}
|
||||
|
||||
revision "2021-02-19" {
|
||||
description
|
||||
"Correct range for bridge priority type.";
|
||||
reference "0.4.0";
|
||||
}
|
||||
|
||||
revision "2019-11-28" {
|
||||
description
|
||||
"Correct revision statement date for v0.3.0";
|
||||
reference "0.3.1";
|
||||
}
|
||||
|
||||
revision "2019-07-10" {
|
||||
description
|
||||
"Remove the time-since-last-topology-change leaf and
|
||||
replace it with a timestamp of last topology change.";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2017-07-14" {
|
||||
description
|
||||
"Migrated to OpenConfig types; fixed missing applied state
|
||||
in rapid-pvst";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2016-10-03" {
|
||||
description
|
||||
"Initial public revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
identity STP_PROTOCOL {
|
||||
description
|
||||
"base identity for support spanning tree protocol";
|
||||
}
|
||||
|
||||
identity RSTP {
|
||||
base STP_PROTOCOL;
|
||||
description
|
||||
"Rapid Spanning Tree Protocol";
|
||||
reference "IEEE 802.1D 17";
|
||||
}
|
||||
|
||||
identity MSTP {
|
||||
base STP_PROTOCOL;
|
||||
description
|
||||
"Multiple Spanning Tree Protocol";
|
||||
reference "IEEE 802.1Q 13";
|
||||
}
|
||||
|
||||
identity RAPID_PVST {
|
||||
base STP_PROTOCOL;
|
||||
description
|
||||
"Rapid Per Vlan Spanning Tree Protocol";
|
||||
}
|
||||
|
||||
identity STP_PORT_STATE {
|
||||
description
|
||||
"base identity for the different Spanning Tree Protocol port
|
||||
states";
|
||||
reference
|
||||
"IEEE 802.1D 7.4 Port States and the active topology";
|
||||
}
|
||||
|
||||
identity DISABLED {
|
||||
base STP_PORT_STATE;
|
||||
description
|
||||
"A port that is manually isolated from the network";
|
||||
}
|
||||
|
||||
identity LISTENING {
|
||||
base STP_PORT_STATE;
|
||||
description
|
||||
"Processing BPDUs and building active toplogy";
|
||||
}
|
||||
|
||||
identity LEARNING {
|
||||
base STP_PORT_STATE;
|
||||
description
|
||||
"Building bridging tables; no forwarding of data";
|
||||
}
|
||||
|
||||
identity BLOCKING {
|
||||
base STP_PORT_STATE;
|
||||
description
|
||||
"A port that would cause a loop if it were sending data,
|
||||
so it is only receiving BPDUs, untill a topology change
|
||||
removes the possibliity of a loop";
|
||||
}
|
||||
|
||||
identity FORWARDING {
|
||||
base STP_PORT_STATE;
|
||||
description
|
||||
"Sending and receiving data, normal operation";
|
||||
}
|
||||
|
||||
identity STP_EDGE_PORT {
|
||||
description
|
||||
"base identity for the different edge port modes";
|
||||
reference
|
||||
"IEEE 802.1D 17.13.1";
|
||||
}
|
||||
|
||||
identity EDGE_ENABLE {
|
||||
base STP_EDGE_PORT;
|
||||
description
|
||||
"Enable edge port for the bridge port";
|
||||
}
|
||||
|
||||
identity EDGE_DISABLE {
|
||||
base STP_EDGE_PORT;
|
||||
description
|
||||
"Disable edge port for the bridge port";
|
||||
}
|
||||
|
||||
identity EDGE_AUTO {
|
||||
base STP_EDGE_PORT;
|
||||
description
|
||||
"Enable edge port autodetction for the bridge port";
|
||||
}
|
||||
|
||||
identity STP_PORT_ROLE {
|
||||
description
|
||||
"Base identity for the different Spanning Tree Protocol port
|
||||
roles";
|
||||
reference
|
||||
"IEEE 802.1D 17.7 Port Role assignments";
|
||||
}
|
||||
|
||||
identity ROOT {
|
||||
base STP_PORT_ROLE;
|
||||
description
|
||||
"The port that receives the best BPDU on a bridge is the
|
||||
root port";
|
||||
}
|
||||
|
||||
identity DESIGNATED {
|
||||
base STP_PORT_ROLE;
|
||||
description
|
||||
"A port is designated if it can send the best BPDU on the
|
||||
segment to which it is connected.";
|
||||
}
|
||||
|
||||
identity ALTERNATE {
|
||||
base STP_PORT_ROLE;
|
||||
description
|
||||
"An alternate port receives more useful BPDUs from another
|
||||
bridge and is a port blocked";
|
||||
}
|
||||
|
||||
identity BACKUP {
|
||||
base STP_PORT_ROLE;
|
||||
description
|
||||
"A backup port receives more useful BPDUs from the same
|
||||
bridge it is on and is a port blocked";
|
||||
}
|
||||
|
||||
// typedef statements
|
||||
|
||||
typedef stp-bridge-priority-type {
|
||||
type uint16 {
|
||||
range 0..61440;
|
||||
}
|
||||
default 32768;
|
||||
description
|
||||
"The manageable component of the Bridge Identifier. The bridge priority
|
||||
determines which bridge is selected as the root bridge (lowest priority
|
||||
value is selected as root). Valid values are in the range 0 through
|
||||
61440, in steps of 4096.";
|
||||
reference "IEEE 802.1D 17.13.7 Bridge Identifier Priority";
|
||||
}
|
||||
|
||||
typedef stp-port-priority-type {
|
||||
type uint8 {
|
||||
range 1..240;
|
||||
}
|
||||
description
|
||||
"The manageable component of the Port Identifier,
|
||||
also known as the Port Priority";
|
||||
reference
|
||||
"IEEE 802.1D 17.13.10 Port Identifier Priority";
|
||||
}
|
||||
|
||||
typedef stp-guard-type {
|
||||
type enumeration {
|
||||
enum ROOT {
|
||||
description
|
||||
"Enable root guard";
|
||||
}
|
||||
enum LOOP {
|
||||
description
|
||||
"Enable loop guard";
|
||||
}
|
||||
enum NONE {
|
||||
description
|
||||
"disable guard";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Type definition for the different STP guard for the switch port";
|
||||
reference "IEEE 802.1D 17.2";
|
||||
}
|
||||
|
||||
typedef stp-link-type {
|
||||
type enumeration {
|
||||
enum P2P {
|
||||
description
|
||||
"Point-to-Point link";
|
||||
}
|
||||
enum SHARED {
|
||||
description
|
||||
"Shared link";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Type definition for the different link types";
|
||||
reference "IEEE 802.1D 17.2";
|
||||
}
|
||||
}
|
||||
842
Parseurs_logs_Switch/src/modèles/openconfig-spanning-tree.yang
Normal file
842
Parseurs_logs_Switch/src/modèles/openconfig-spanning-tree.yang
Normal file
@@ -0,0 +1,842 @@
|
||||
module openconfig-spanning-tree {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/spanning-tree";
|
||||
|
||||
prefix "oc-stp";
|
||||
|
||||
import openconfig-spanning-tree-types { prefix oc-stp-types; }
|
||||
import openconfig-interfaces { prefix oc-if; }
|
||||
import openconfig-types { prefix oc-types; }
|
||||
import openconfig-vlan-types { prefix oc-vlan-types; }
|
||||
import openconfig-yang-types { prefix oc-yang; }
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines configuration and operational state data
|
||||
for the spanning tree protocol.";
|
||||
|
||||
oc-ext:openconfig-version "0.3.1";
|
||||
|
||||
revision "2019-11-28" {
|
||||
description
|
||||
"Correct revision statement date for v0.3.0";
|
||||
reference "0.3.1";
|
||||
}
|
||||
|
||||
revision "2019-07-10" {
|
||||
description
|
||||
"Remove the time-since-last-topology-change leaf and
|
||||
replace it with a timestamp of last topology change.";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.2.1";
|
||||
}
|
||||
|
||||
revision "2017-07-14" {
|
||||
description
|
||||
"Migrated to OpenConfig types; fixed missing applied state
|
||||
in rapid-pvst";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2016-10-03" {
|
||||
description
|
||||
"Initial public revision";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping stp-interfaces-state {
|
||||
description
|
||||
"Grouping of STP operational data for bridge port";
|
||||
|
||||
leaf port-num {
|
||||
type uint16;
|
||||
description
|
||||
"The port number of the bridge port";
|
||||
reference "RFC4188 BRIDGE-MIB dot1dStpPort";
|
||||
}
|
||||
|
||||
leaf role {
|
||||
type identityref {
|
||||
base oc-stp-types:STP_PORT_ROLE;
|
||||
}
|
||||
description
|
||||
"The current role of the bridge port";
|
||||
reference
|
||||
"IEEE8021-MSTP-MIB ieee8021MstpPortRole";
|
||||
}
|
||||
|
||||
leaf port-state {
|
||||
type identityref {
|
||||
base oc-stp-types:STP_PORT_STATE;
|
||||
}
|
||||
description
|
||||
"The current state of the bridge port";
|
||||
reference "RFC4188 BRIDGE-MIB dot1dStpPortState";
|
||||
}
|
||||
|
||||
leaf designated-root-priority {
|
||||
type oc-stp-types:stp-bridge-priority-type;
|
||||
description
|
||||
"The bridge priority of the bridge recorded as the
|
||||
root in the configuration BPDUs transmitted by the designated
|
||||
bridge for the segment to which the port is attached";
|
||||
reference "RFC4188 BRIDGE-MIB dot1dStpPortDesignatedRoot";
|
||||
}
|
||||
|
||||
leaf designated-root-address {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"The bridge address of the bridge recorded as the
|
||||
root in the configuration BPDUs transmitted by the designated
|
||||
bridge for the segment to which the port is attached";
|
||||
reference "RFC4188 BRIDGE-MIB dot1dStpPortDesignatedRoot";
|
||||
}
|
||||
|
||||
leaf designated-cost {
|
||||
type uint32;
|
||||
description
|
||||
"The path cost of the Designated Port of the
|
||||
segment connected to this port";
|
||||
reference "RFC4188 BRIDGE-MIB dot1dStpPortDesignatedCost";
|
||||
}
|
||||
|
||||
leaf designated-bridge-priority {
|
||||
type oc-stp-types:stp-bridge-priority-type;
|
||||
description
|
||||
"The bridge priority of the bridge that this port considers
|
||||
to be the designated bridge for this port's segment.";
|
||||
reference "RFC4188 BRIDGE-MIB dot1dStpPortDesignatedBridge";
|
||||
}
|
||||
|
||||
leaf designated-bridge-address {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"The bridge address of the bridge that this port considers
|
||||
to be the designated bridge for this port's segment.";
|
||||
reference "RFC4188 BRIDGE-MIB dot1dStpPortDesignatedBridge";
|
||||
}
|
||||
|
||||
leaf designated-port-priority {
|
||||
type oc-stp-types:stp-port-priority-type;
|
||||
description
|
||||
"The Port priority of the port on the Designated
|
||||
Bridge for this port's segment, two octet string";
|
||||
reference "RFC4188 BRIDGE-MIB dot1dStpPortDesignatedPort";
|
||||
}
|
||||
|
||||
leaf designated-port-num {
|
||||
type uint16;
|
||||
description
|
||||
"The Port number of the port on the Designated
|
||||
Bridge for this port's segment, two octet string";
|
||||
reference "RFC4188 BRIDGE-MIB dot1dStpPortDesignatedPort";
|
||||
}
|
||||
|
||||
leaf forward-transisitions {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of times this port has transitioned
|
||||
from the Learning state to the Forwarding state";
|
||||
reference "RFC4188 BRIDGE-MIB dot1dStpPortForwardTransitions";
|
||||
}
|
||||
|
||||
container counters {
|
||||
description
|
||||
"The BPDU packet transmition statistics";
|
||||
|
||||
leaf bpdu-sent {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of BPDU packet sent";
|
||||
}
|
||||
|
||||
leaf bpdu-received {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The number of BPDU packet received";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping stp-interfaces-config {
|
||||
description
|
||||
"Grouping of STP configuration for bridge port";
|
||||
|
||||
leaf name {
|
||||
type oc-if:base-interface-ref;
|
||||
description
|
||||
"Reference to the STP ethernet interface";
|
||||
}
|
||||
|
||||
leaf cost {
|
||||
type uint32 {
|
||||
range 1..200000000;
|
||||
}
|
||||
description
|
||||
"The port's contribution, when it is the Root Port,
|
||||
to the Root Path Cost for the Bridge";
|
||||
reference
|
||||
"IEEE 802.1D 17.13.11 PortPathCost";
|
||||
}
|
||||
|
||||
leaf port-priority {
|
||||
type oc-stp-types:stp-port-priority-type;
|
||||
description
|
||||
"The manageable component of the Port Identifier,
|
||||
also known as the Port Priority";
|
||||
reference
|
||||
"IEEE 802.1D 17.13.10 Port Identifier Priority";
|
||||
}
|
||||
}
|
||||
|
||||
grouping stp-interfaces-top {
|
||||
description
|
||||
"Grouping of STP configuration and operation data for
|
||||
bridge port";
|
||||
|
||||
container interfaces {
|
||||
description
|
||||
"Enclosing container for the list of interface references";
|
||||
|
||||
list interface {
|
||||
key "name";
|
||||
description
|
||||
"List of interfaces on which STP is enable";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "../config/name";
|
||||
}
|
||||
description
|
||||
"Reference to the list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for STP on each interface";
|
||||
|
||||
uses stp-interfaces-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for STP on each interface";
|
||||
|
||||
uses stp-interfaces-config;
|
||||
uses stp-interfaces-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping bridge-priority-config {
|
||||
description
|
||||
"Grouping for bridge priority";
|
||||
|
||||
leaf bridge-priority {
|
||||
type oc-stp-types:stp-bridge-priority-type;
|
||||
description
|
||||
"The manageable component of the Bridge Identifier";
|
||||
reference
|
||||
"IEEE 802.1D 17.13.7 Bridge Identifier Priority";
|
||||
}
|
||||
}
|
||||
|
||||
grouping stp-common-state {
|
||||
description
|
||||
"Grouping for common STP operation data";
|
||||
|
||||
leaf bridge-address {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"A unique 48-bit Universally Administered MAC Address
|
||||
assigned to the bridge";
|
||||
reference
|
||||
"IEEE 802.1D 7.12.5 Unique identification of a bridge";
|
||||
}
|
||||
|
||||
leaf designated-root-priority {
|
||||
type oc-stp-types:stp-bridge-priority-type;
|
||||
description
|
||||
"The bridge priority of the root of the spanning
|
||||
tree, as determined by the Spanning Tree Protocol,
|
||||
as executed by this node";
|
||||
reference
|
||||
"RFC4188 BRIDGE-MIB dot1dStpDesignatedRoot";
|
||||
}
|
||||
|
||||
leaf designated-root-address {
|
||||
type oc-yang:mac-address;
|
||||
description
|
||||
"The bridge address of the root of the spanning
|
||||
tree, as determined by the Spanning Tree Protocol,
|
||||
as executed by this node";
|
||||
reference
|
||||
"RFC4188 BRIDGE-MIB dot1dStpDesignatedRoot";
|
||||
}
|
||||
|
||||
leaf root-port {
|
||||
type uint16;
|
||||
description
|
||||
"The port number of the port which offers the lowest
|
||||
cost path from this bridge to the root bridge";
|
||||
reference
|
||||
"RFC4188 BRIDGE-MIB dot1dStpRootPort";
|
||||
}
|
||||
|
||||
leaf root-cost {
|
||||
type uint32;
|
||||
description
|
||||
"The cost of the path to the root as seen from this bridge";
|
||||
reference
|
||||
"RFC4188 BRIDGE-MIB dot1dStpRootCost";
|
||||
}
|
||||
|
||||
leaf hold-time {
|
||||
type uint8;
|
||||
description
|
||||
"This time value determines the interval length
|
||||
during which no more than two Configuration bridge
|
||||
PDUs shall be transmitted by this node";
|
||||
reference
|
||||
"RFC4188 BRIDGE-MIB dot1dStpHoldTime";
|
||||
}
|
||||
|
||||
leaf topology-changes {
|
||||
type oc-yang:counter64;
|
||||
description
|
||||
"The total number of topology changes detected by
|
||||
this bridge since the management entity was last
|
||||
reset or initialized";
|
||||
reference
|
||||
"RFC4188 BRIDGE-MIB dot1dStpTopChanges";
|
||||
}
|
||||
|
||||
leaf last-topology-change {
|
||||
type oc-types:timeticks64;
|
||||
description
|
||||
"The time at which the last topology change was
|
||||
detected by the bridge entity. The value is
|
||||
expressed relative to the Unix Epoch (Jan 1, 1970
|
||||
00:00:00 UTC).";
|
||||
}
|
||||
}
|
||||
|
||||
grouping stp-timer-config {
|
||||
description
|
||||
"Grouping for common STP parameters";
|
||||
|
||||
leaf hello-time {
|
||||
type uint8 {
|
||||
range 1..10;
|
||||
}
|
||||
units "seconds";
|
||||
description
|
||||
"The interval between periodic transmissions of
|
||||
configuration messages by designated ports";
|
||||
reference
|
||||
"IEEE 802.1D 17.13.6 Bridge Hello Time";
|
||||
}
|
||||
|
||||
leaf max-age {
|
||||
type uint8 {
|
||||
range 6..40;
|
||||
}
|
||||
units "seconds";
|
||||
description
|
||||
"The maximum age of the information transmitted by the
|
||||
bridge when it is the root bridge";
|
||||
reference
|
||||
"IEEE 802.1D 17.13.8 Bridge Max Age";
|
||||
}
|
||||
|
||||
leaf forwarding-delay {
|
||||
type uint8 {
|
||||
range 4..30;
|
||||
}
|
||||
units "seconds";
|
||||
description
|
||||
"The delay used by STP bridges to transition root and
|
||||
designated ports to forwarding";
|
||||
reference
|
||||
"IEEE 802.1D 17.13.5 Bridge Forward Delay";
|
||||
}
|
||||
|
||||
leaf hold-count {
|
||||
type uint8 {
|
||||
range 1..10;
|
||||
}
|
||||
default 6;
|
||||
description
|
||||
"the maximum number of BPDUs per second that the
|
||||
switch can send from an interface";
|
||||
reference
|
||||
"IEEE 802.1D 17.13.12 Transmit Hold Count";
|
||||
}
|
||||
}
|
||||
|
||||
grouping stp-rapid-pvst-config {
|
||||
description
|
||||
"Configuration parameters relating to rapid PVST";
|
||||
|
||||
leaf vlan-id {
|
||||
type oc-vlan-types:vlan-id;
|
||||
description
|
||||
"Interface VLAN ID";
|
||||
}
|
||||
}
|
||||
|
||||
grouping stp-rapid-pvst-top {
|
||||
description
|
||||
"Top grouping for rapid per vlan spanning tree configuration
|
||||
and operation data";
|
||||
|
||||
list vlan {
|
||||
key "vlan-id";
|
||||
description
|
||||
"List of the vlans";
|
||||
|
||||
leaf vlan-id {
|
||||
type leafref {
|
||||
path "../config/vlan-id";
|
||||
}
|
||||
description
|
||||
"Reference to the list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for each vlan";
|
||||
|
||||
uses stp-rapid-pvst-config;
|
||||
uses stp-timer-config;
|
||||
uses bridge-priority-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational data for each vlan";
|
||||
|
||||
uses stp-rapid-pvst-config;
|
||||
uses stp-timer-config;
|
||||
uses bridge-priority-config;
|
||||
uses stp-common-state;
|
||||
}
|
||||
|
||||
uses stp-interfaces-top;
|
||||
}
|
||||
}
|
||||
|
||||
grouping mst-instance-config {
|
||||
description
|
||||
"Grouping for mstp instance configuration";
|
||||
|
||||
leaf mst-id {
|
||||
type uint16 {
|
||||
range "1..4094";
|
||||
}
|
||||
description
|
||||
"In an MSTP Bridge, an MSTID, i.e., a value used to identify
|
||||
a spanning tree (or MST) instance.";
|
||||
reference
|
||||
"IEEE8021-TC-MIB IEEE8021MstIdentifier";
|
||||
}
|
||||
|
||||
leaf-list vlan {
|
||||
type union {
|
||||
type oc-vlan-types:vlan-id;
|
||||
type oc-vlan-types:vlan-range;
|
||||
}
|
||||
description
|
||||
"list of vlans mapped to the MST instance";
|
||||
}
|
||||
}
|
||||
|
||||
grouping mst-instance-top {
|
||||
description
|
||||
"Top level grouping for mstp instances";
|
||||
|
||||
list mst-instance {
|
||||
key "mst-id";
|
||||
description
|
||||
"List of the mstp instances";
|
||||
|
||||
leaf mst-id {
|
||||
type leafref {
|
||||
path "../config/mst-id";
|
||||
}
|
||||
description
|
||||
"Reference to the list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for MSTP instance";
|
||||
|
||||
uses mst-instance-config;
|
||||
uses bridge-priority-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational data for MSTP instance";
|
||||
|
||||
uses mst-instance-config;
|
||||
uses bridge-priority-config;
|
||||
uses stp-common-state;
|
||||
}
|
||||
|
||||
uses stp-interfaces-top;
|
||||
}
|
||||
}
|
||||
|
||||
grouping mstp-config {
|
||||
description
|
||||
"Grouping for MSTP configuration data";
|
||||
|
||||
leaf name {
|
||||
type string {
|
||||
length "1..32";
|
||||
}
|
||||
description
|
||||
"The Configuration Name in the MST Configuration Identifier";
|
||||
reference
|
||||
"IEEE 802.1Q 13.8 MST Configuration Identifier (MCID)";
|
||||
}
|
||||
|
||||
leaf revision {
|
||||
type uint32;
|
||||
description
|
||||
"The Revision Level in the MST Configuration Identifier";
|
||||
reference
|
||||
"IEEE 802.1Q 13.8 MST Configuration Identifier";
|
||||
}
|
||||
|
||||
leaf max-hop {
|
||||
type uint8 {
|
||||
range 1..255;
|
||||
}
|
||||
description
|
||||
"The max hop determines the number of bridges in an MST
|
||||
region that a BPDU can traverse before it is discarded";
|
||||
reference
|
||||
"IEEE 802.1Q 13.26.4 BridgeTimes";
|
||||
}
|
||||
|
||||
uses stp-timer-config;
|
||||
}
|
||||
|
||||
grouping mstp-state {
|
||||
description
|
||||
"Operational state data for MSTP";
|
||||
}
|
||||
|
||||
grouping stp-mstp-top {
|
||||
description
|
||||
"Top grouping for MSTP configuration and operation data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for MSTP";
|
||||
|
||||
uses mstp-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational data for MSTP";
|
||||
|
||||
uses mstp-config;
|
||||
uses mstp-state;
|
||||
}
|
||||
|
||||
container mst-instances {
|
||||
description
|
||||
"Configuration and operation data for MSTP instances";
|
||||
|
||||
uses mst-instance-top;
|
||||
}
|
||||
}
|
||||
|
||||
grouping stp-rstp-top {
|
||||
description
|
||||
"Top grouping for RSTP configuration and operation data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for RSTP";
|
||||
|
||||
uses stp-timer-config;
|
||||
uses bridge-priority-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for RSTP";
|
||||
|
||||
uses stp-timer-config;
|
||||
uses bridge-priority-config;
|
||||
uses stp-common-state;
|
||||
}
|
||||
|
||||
uses stp-interfaces-top;
|
||||
}
|
||||
|
||||
grouping stp-interface-common-config {
|
||||
description
|
||||
"Configuration data for interface specific STP features";
|
||||
|
||||
leaf name {
|
||||
type oc-if:base-interface-ref;
|
||||
description
|
||||
"Reference to the STP Ethernet interface";
|
||||
}
|
||||
|
||||
leaf edge-port {
|
||||
type identityref {
|
||||
base oc-stp-types:STP_EDGE_PORT;
|
||||
}
|
||||
description
|
||||
"Configure the edge port state";
|
||||
}
|
||||
|
||||
leaf link-type {
|
||||
type oc-stp-types:stp-link-type;
|
||||
description
|
||||
"specifies the interface's link type";
|
||||
}
|
||||
|
||||
leaf guard {
|
||||
type oc-stp-types:stp-guard-type;
|
||||
description
|
||||
"Enable root guard or loop guard";
|
||||
}
|
||||
|
||||
uses stp-bpdu-config;
|
||||
|
||||
}
|
||||
|
||||
grouping stp-interface-common-state {
|
||||
description
|
||||
"Operational state data for STP on interfaces";
|
||||
}
|
||||
|
||||
grouping stp-interface-common-top {
|
||||
description
|
||||
"Top-level grouping for interface specific STP features";
|
||||
|
||||
list interface {
|
||||
key "name";
|
||||
description
|
||||
"List of interfaces on which STP is enable";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "../config/name";
|
||||
}
|
||||
description
|
||||
"Reference to the list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for STP on each bridge port";
|
||||
|
||||
uses stp-interface-common-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for STP on each bridge port";
|
||||
|
||||
uses stp-interface-common-config;
|
||||
uses stp-interface-common-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping stp-bpdu-config {
|
||||
description
|
||||
"Grouping for STP BPDU configuration";
|
||||
|
||||
leaf bpdu-guard {
|
||||
type boolean;
|
||||
description
|
||||
"Enable edge port BPDU guard";
|
||||
}
|
||||
|
||||
leaf bpdu-filter {
|
||||
type boolean;
|
||||
description
|
||||
"Enable edge port BPDU filter";
|
||||
}
|
||||
}
|
||||
|
||||
grouping stp-global-config {
|
||||
description
|
||||
"Global spanning tree configuration";
|
||||
|
||||
leaf-list enabled-protocol {
|
||||
type identityref {
|
||||
base oc-stp-types:STP_PROTOCOL;
|
||||
}
|
||||
description
|
||||
"List of the spanning tree protocols enabled on the
|
||||
device";
|
||||
}
|
||||
|
||||
leaf bridge-assurance {
|
||||
type boolean;
|
||||
description
|
||||
"Enable bridge assurance to protect against unidirectional
|
||||
link failure";
|
||||
}
|
||||
|
||||
leaf etherchannel-misconfig-guard {
|
||||
type boolean;
|
||||
description
|
||||
"EtherChannel guard detects a misconfigured EtherChannel
|
||||
when interfaces on the switch are configured as an
|
||||
EtherChannel while interfaces on the other device are not
|
||||
or when not all the interfaces on the other device are in
|
||||
the same EtherChannel.";
|
||||
}
|
||||
|
||||
leaf bpduguard-timeout-recovery {
|
||||
type uint8;
|
||||
units "seconds";
|
||||
description
|
||||
"Amount of time, in seconds, the interface receiving BPDUs
|
||||
is disabled. Once the timeout expires, the interface is
|
||||
brought back into service.";
|
||||
}
|
||||
|
||||
leaf loop-guard {
|
||||
type boolean;
|
||||
description
|
||||
"The loop guard default setting for the bridge";
|
||||
}
|
||||
|
||||
uses stp-bpdu-config;
|
||||
|
||||
}
|
||||
|
||||
grouping stp-global-state {
|
||||
description
|
||||
"Global operational state for STP";
|
||||
}
|
||||
|
||||
grouping stp-global-base {
|
||||
description
|
||||
"Grouping for global spanning tree data";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Global spanning tree configuration";
|
||||
uses stp-global-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
|
||||
description
|
||||
"Global spanning tree state";
|
||||
uses stp-global-config;
|
||||
uses stp-global-state;
|
||||
}
|
||||
}
|
||||
|
||||
grouping stp-top {
|
||||
description
|
||||
"Top-level grouping for spanning-tree model";
|
||||
|
||||
container stp {
|
||||
description
|
||||
"Top-level container for spanning tree configuration and
|
||||
state data";
|
||||
|
||||
container global {
|
||||
description
|
||||
"Global configuration and state data";
|
||||
|
||||
uses stp-global-base;
|
||||
}
|
||||
|
||||
container rstp {
|
||||
|
||||
description
|
||||
"Rapid Spanning-tree protocol configuration and operation
|
||||
data";
|
||||
|
||||
uses stp-rstp-top;
|
||||
}
|
||||
|
||||
container mstp {
|
||||
description
|
||||
"Multi Spanning-tree protocol configuration and operation
|
||||
data";
|
||||
|
||||
uses stp-mstp-top;
|
||||
}
|
||||
|
||||
container rapid-pvst {
|
||||
description
|
||||
"Rapid per vlan Spanning-tree protocol configuration and
|
||||
operational data";
|
||||
|
||||
uses stp-rapid-pvst-top;
|
||||
}
|
||||
|
||||
container interfaces {
|
||||
description
|
||||
"Enclosing container for the list of interface references";
|
||||
|
||||
uses stp-interface-common-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
uses stp-top;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,374 @@
|
||||
module openconfig-system-controlplane {
|
||||
yang-version "1";
|
||||
|
||||
namespace "http://openconfig.net/yang/system-controlplane";
|
||||
prefix "oc-sys-copp";
|
||||
|
||||
import openconfig-extensions {
|
||||
prefix oc-ext;
|
||||
}
|
||||
import openconfig-system {
|
||||
prefix oc-sys;
|
||||
}
|
||||
import openconfig-acl {
|
||||
prefix oc-acl;
|
||||
}
|
||||
import openconfig-qos {
|
||||
prefix oc-qos;
|
||||
}
|
||||
|
||||
organization
|
||||
"OpenConfig working group";
|
||||
contact
|
||||
"www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module adds configuration and operational state relating to
|
||||
policies for traffic destined to the system's control-plane.
|
||||
Particularly, it allows for mechanisms to:
|
||||
- apply an ACL that forwards or drops traffic towards the control-plane.
|
||||
- classify traffic that is destined to the control-plane according to
|
||||
a QoS classifier.
|
||||
- schedule traffic that has been forwarded towards the control-plane,
|
||||
to allow for policies such as rate limits to be applied.
|
||||
The configured policies apply generically to all control-planes that
|
||||
exist within the system, and should be mapped to the internal interfaces
|
||||
via which packets are forwarded to control-plane modules.
|
||||
When a packet is received at an input interface - it is classified into a
|
||||
forwarding group which drains to a specific queue. If this input mapping
|
||||
is sufficient, the CPU-facing interface uses the specified scheduler
|
||||
to determine how to drain queues. If more granular remapping is required
|
||||
(e.g., to classify control-plane traffic more granularly), a user specifies
|
||||
an alternate classifier that is used to reclassify traffic into
|
||||
a new set of forwarding-groups (and hence queues) that can subsequently
|
||||
be scheduled by the specified scheduler.
|
||||
The specified control-plane ACL is applied to traffic received by the
|
||||
control-plane of the system.";
|
||||
|
||||
oc-ext:openconfig-version "0.2.0";
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
revision "2023-03-03" {
|
||||
description
|
||||
"Add missing state container to ACL.";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2021-08-02" {
|
||||
description
|
||||
"Initial revision.";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
grouping system-controlplane-top {
|
||||
description
|
||||
"Top-level structural grouping for control-plane traffic policies.";
|
||||
|
||||
container control-plane-traffic {
|
||||
description
|
||||
"Policies and configuration relating to the traffic destined towards
|
||||
the system control-plane.";
|
||||
|
||||
container ingress {
|
||||
description
|
||||
"Control-plane traffic parameters relating to ingress traffic.
|
||||
This refers to traffic that is being received by the system's
|
||||
control plane from external-to-the-controlplane sources.";
|
||||
|
||||
uses system-controlplane-acl-common-top;
|
||||
|
||||
container qos {
|
||||
description
|
||||
"Configuration and operational state relating to QoS policies
|
||||
that are applied to control-plane traffic.";
|
||||
|
||||
container classifier {
|
||||
description
|
||||
"Configuration and state parameters relating to the QoS
|
||||
classifier that is applied to control plane traffic. A QoS
|
||||
classifier - defined in /qos/classifiers specifies how traffic
|
||||
is mapped to QoS queues. The classifier specified in this
|
||||
container and corresponding state allows for traffic towards
|
||||
the control-plane to be classified.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to QoS classifier
|
||||
applied to match control plane traffic.";
|
||||
uses system-controlplane-qos-classifier-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters relating to the QoS classifier
|
||||
applied to match control plane traffic.";
|
||||
uses system-controlplane-qos-classifier-config;
|
||||
}
|
||||
|
||||
container terms {
|
||||
config false;
|
||||
description
|
||||
"Operational state and counters relating to the classifier
|
||||
applied to control-plane traffic.";
|
||||
|
||||
list term {
|
||||
key "id";
|
||||
|
||||
description
|
||||
"A list of the terms within the QoS classifier being
|
||||
applied for control-plane traffic. Each term has
|
||||
corresponding operational state parameters.";
|
||||
|
||||
leaf id {
|
||||
type leafref {
|
||||
path "../state/id";
|
||||
}
|
||||
description
|
||||
"Reference to the identifier for the classifier term.";
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters relating to a term within
|
||||
the applied control-plane classifier";
|
||||
|
||||
uses system-controlplane-qos-classifier-term-state;
|
||||
uses oc-qos:qos-interface-classifier-match-counters-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
container scheduler-policy {
|
||||
description
|
||||
"Configuration and operational state relating to the QoS
|
||||
scheduler policy that is applied to control-plane traffic.
|
||||
The scheduler policy determines how traffic, classified by
|
||||
the specified control-plane classifier is rate-limited towards
|
||||
the control-plane. The scheduler policy is defined in
|
||||
/qos/scheduler-policies.";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to the scheduler-policy
|
||||
that is to be applied control-plane traffic.";
|
||||
|
||||
uses system-controlplane-qos-scheduler-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters relating to the scheduler policy
|
||||
applied to the control-plane traffic.";
|
||||
|
||||
uses system-controlplane-qos-scheduler-config;
|
||||
}
|
||||
|
||||
container scheduler-statistics {
|
||||
config false;
|
||||
description
|
||||
"Operational state and counters relating to the
|
||||
scheduler-policy applied to control plane traffic.";
|
||||
|
||||
list scheduler {
|
||||
key "sequence";
|
||||
description
|
||||
"List of the schedulers that are part of the scheduler-policy
|
||||
specified.";
|
||||
|
||||
leaf sequence {
|
||||
type leafref {
|
||||
path "../state/sequence";
|
||||
}
|
||||
description
|
||||
"Reference to the sequence ID for the scheduler.";
|
||||
}
|
||||
|
||||
container state {
|
||||
description
|
||||
"Operational state parameters relating to the scheduler
|
||||
policy.";
|
||||
|
||||
uses system-controlplane-qos-scheduler-seq-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
container egress {
|
||||
description
|
||||
"Control-plane traffic parameters relating to egress traffic.
|
||||
This refers to traffic that is sent by the system's control
|
||||
plane to external-to-the-controlplane destinations.";
|
||||
|
||||
uses system-controlplane-acl-common-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping system-controlplane-acl-common-top {
|
||||
description
|
||||
"Common structural grouping for ACL configuration and state for
|
||||
control plane traffic.";
|
||||
|
||||
container acl {
|
||||
description
|
||||
"Configuration and operational state parameters relating to the
|
||||
access control list applied to control-plane traffic.";
|
||||
|
||||
list acl-set {
|
||||
key "set-name type";
|
||||
|
||||
description
|
||||
"List of the ACL that is to be applied in the specific ingress
|
||||
or egress context. The key of the list specifies the type of
|
||||
traffic to be matched, along with a reference to an ACL
|
||||
configured in the OpenConfig ACL model within the /acl hierarchy.";
|
||||
|
||||
leaf set-name {
|
||||
type leafref {
|
||||
path "../config/set-name";
|
||||
}
|
||||
description
|
||||
"Reference to the name of the ACL-set to be applied.";
|
||||
}
|
||||
|
||||
leaf type {
|
||||
type leafref {
|
||||
path "../config/type";
|
||||
}
|
||||
description
|
||||
"Reference to the type of the ACL-set to be applied.";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration parameters relating to the ACL to be applied.";
|
||||
|
||||
uses system-controlplane-common-acl-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state parameters relating to the ACL to be applied.";
|
||||
uses system-controlplane-common-acl-config;
|
||||
}
|
||||
|
||||
uses oc-acl:interface-acl-entries-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping system-controlplane-common-acl-config {
|
||||
description
|
||||
"Grouping for ACL parameters relating to the system control-plane.";
|
||||
|
||||
leaf set-name {
|
||||
type leafref {
|
||||
path "/oc-acl:acl/oc-acl:acl-sets/oc-acl:acl-set/" +
|
||||
"oc-acl:config/oc-acl:name";
|
||||
}
|
||||
description
|
||||
"Reference to the ACL to be applied to traffic
|
||||
in the specified context (ingress or egress).";
|
||||
}
|
||||
|
||||
leaf type {
|
||||
type leafref {
|
||||
path "/oc-acl:acl/oc-acl:acl-sets/oc-acl:acl-set" +
|
||||
"[oc-acl:name=current()/../set-name]" +
|
||||
"/oc-acl:config/oc-acl:type";
|
||||
}
|
||||
description
|
||||
"Reference to the ACL set type applied to traffic
|
||||
in the specified context (ingress or egress).";
|
||||
}
|
||||
}
|
||||
|
||||
grouping system-controlplane-qos-classifier-config {
|
||||
description
|
||||
"Grouping for configuration parameters relating to QoS classifiers
|
||||
for the system control-plane.";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "/oc-qos:qos/oc-qos:classifiers/oc-qos:classifier/" +
|
||||
"oc-qos:config/oc-qos:name";
|
||||
}
|
||||
description
|
||||
"Reference to a classifier that is used to classify traffic
|
||||
destined to the control-plane of the system.
|
||||
This classifier determines how packets that match each terms
|
||||
are classified into forwarding groups, and subsequently into
|
||||
queues to be forwarded.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping system-controlplane-qos-classifier-term-state {
|
||||
description
|
||||
"Grouping for control-plane traffic specific leaves required for
|
||||
each configuration term.";
|
||||
|
||||
leaf id {
|
||||
// Current location /system/control-plane/ingress/qos/classifier/
|
||||
// terms/term/state/id
|
||||
type leafref {
|
||||
path "/oc-qos:qos/oc-qos:classifiers/" +
|
||||
"oc-qos:classifier[oc-qos:name=current()/../../../../config/name]" +
|
||||
"/oc-qos:terms/oc-qos:term/oc-qos:config/oc-qos:id";
|
||||
}
|
||||
description
|
||||
"Reference to a term identifier within the configured control-plane
|
||||
classifier.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping system-controlplane-qos-scheduler-config {
|
||||
description
|
||||
"Grouping for configuration parameters relating to the QoS scheduler
|
||||
policy for control-plane traffic.";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "/oc-qos:qos/oc-qos:scheduler-policies/oc-qos:scheduler-policy/" +
|
||||
"oc-qos:config/oc-qos:name";
|
||||
}
|
||||
description
|
||||
"Reference to a scheduler policy that determines rate limits, or
|
||||
shaping of packets towards the control-plane.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping system-controlplane-qos-scheduler-seq-state {
|
||||
description
|
||||
"Grouping for operational state parameters relating to indivual
|
||||
schedulers within the applied scheduler policy.";
|
||||
|
||||
leaf sequence {
|
||||
type leafref {
|
||||
path "/oc-qos:qos/oc-qos:scheduler-policies/oc-qos:scheduler-policy" +
|
||||
"[oc-qos:name=current()/../../../../config/name]" +
|
||||
"/oc-qos:schedulers/oc-qos:scheduler/oc-qos:config/" +
|
||||
"oc-qos:sequence";
|
||||
}
|
||||
description
|
||||
"Reference to a scheduler within the configured scheduler policy.";
|
||||
}
|
||||
|
||||
uses oc-qos:qos-scheduler-common-state;
|
||||
}
|
||||
|
||||
augment "/oc-sys:system" {
|
||||
description
|
||||
"Add control-plane configuration and state to the system model.";
|
||||
|
||||
uses system-controlplane-top;
|
||||
}
|
||||
}
|
||||
673
Parseurs_logs_Switch/src/modèles/openconfig-system-logging.yang
Normal file
673
Parseurs_logs_Switch/src/modèles/openconfig-system-logging.yang
Normal file
@@ -0,0 +1,673 @@
|
||||
module openconfig-system-logging {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/system/logging";
|
||||
|
||||
prefix "oc-log";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-inet-types { prefix oc-inet; }
|
||||
import openconfig-network-instance { prefix oc-ni; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines configuration and operational state data
|
||||
for common logging facilities on network systems.";
|
||||
|
||||
oc-ext:openconfig-version "0.7.0";
|
||||
|
||||
revision "2024-08-20" {
|
||||
description
|
||||
"Adding tls support for syslog.";
|
||||
reference "0.7.0";
|
||||
}
|
||||
|
||||
revision "2023-07-20" {
|
||||
description
|
||||
"adding VTY and local files as logging destinations";
|
||||
reference "0.6.0";
|
||||
}
|
||||
|
||||
revision "2023-05-04" {
|
||||
description
|
||||
"removing LOG_DESTINATION_TYPE identities";
|
||||
reference "0.5.0";
|
||||
}
|
||||
|
||||
revision "2022-12-29" {
|
||||
description
|
||||
"Add network-instance for remote logging servers";
|
||||
reference "0.4.1";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.3.1";
|
||||
}
|
||||
|
||||
revision "2017-09-18" {
|
||||
description
|
||||
"Updated to use OpenConfig types modules";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2017-07-06" {
|
||||
description
|
||||
"Move to oc-inet types, add IETF attribution, add RADIUS
|
||||
counters, changed password leaf names to indicate hashed";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2017-01-29" {
|
||||
description
|
||||
"Initial public release";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// extension statements
|
||||
|
||||
// feature statements
|
||||
|
||||
// identity statements
|
||||
|
||||
identity SYSLOG_FACILITY {
|
||||
description
|
||||
"Base identity for Syslog message facilities.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity ALL {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"All supported facilities";
|
||||
}
|
||||
|
||||
identity KERNEL {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for kernel messages";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity USER {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for user-level messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity MAIL {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for the mail system.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity SYSTEM_DAEMON {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for the system daemons.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity AUTH {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for security/authorization messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity SYSLOG {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for messages generated internally by syslogd
|
||||
facility.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity AUTHPRIV {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for privileged security/authorization messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
|
||||
identity NTP {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for the NTP subsystem.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity AUDIT {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for log audit messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity CONSOLE {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for log alert messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity LOCAL0 {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for local use 0 messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity LOCAL1 {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for local use 1 messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity LOCAL2 {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for local use 2 messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity LOCAL3 {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for local use 3 messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity LOCAL4 {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for local use 4 messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity LOCAL5 {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for local use 5 messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity LOCAL6 {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for local use 6 messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
identity LOCAL7 {
|
||||
base SYSLOG_FACILITY;
|
||||
description
|
||||
"The facility for local use 7 messages.";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
// typedef statements
|
||||
|
||||
typedef syslog-severity {
|
||||
type enumeration {
|
||||
enum EMERGENCY {
|
||||
description
|
||||
"Emergency: system is unusable (0)";
|
||||
}
|
||||
enum ALERT {
|
||||
description
|
||||
"Alert: action must be taken immediately (1)";
|
||||
}
|
||||
enum CRITICAL {
|
||||
description
|
||||
"Critical: critical conditions (2)";
|
||||
}
|
||||
enum ERROR {
|
||||
description
|
||||
"Error: error conditions (3)";
|
||||
}
|
||||
enum WARNING {
|
||||
description
|
||||
"Warning: warning conditions (4)";
|
||||
}
|
||||
enum NOTICE {
|
||||
description
|
||||
"Notice: normal but significant condition(5)";
|
||||
}
|
||||
enum INFORMATIONAL {
|
||||
description
|
||||
"Informational: informational messages (6)";
|
||||
}
|
||||
enum DEBUG {
|
||||
description
|
||||
"Debug: debug-level messages (7)";
|
||||
}
|
||||
}
|
||||
description
|
||||
"Syslog message severities";
|
||||
reference
|
||||
"IETF RFC 5424 - The Syslog Protocol";
|
||||
}
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping logging-selectors-config {
|
||||
description
|
||||
"Configuration data for logging selectors";
|
||||
|
||||
leaf facility {
|
||||
type identityref {
|
||||
base SYSLOG_FACILITY;
|
||||
}
|
||||
description
|
||||
"Specifies the facility, or class of messages to log";
|
||||
}
|
||||
|
||||
leaf severity {
|
||||
type syslog-severity;
|
||||
description
|
||||
"Specifies that only messages of the given severity (or
|
||||
greater severity) for the corresonding facility are logged";
|
||||
}
|
||||
}
|
||||
|
||||
grouping logging-selectors-state {
|
||||
description
|
||||
"Operational state data for logging selectors";
|
||||
}
|
||||
|
||||
grouping logging-selectors-top {
|
||||
description
|
||||
"Top-level grouping for the logging selector list";
|
||||
|
||||
container selectors {
|
||||
description
|
||||
"Enclosing container ";
|
||||
|
||||
list selector {
|
||||
key "facility severity";
|
||||
description
|
||||
"List of selectors for log messages";
|
||||
|
||||
leaf facility {
|
||||
type leafref {
|
||||
path "../config/facility";
|
||||
}
|
||||
description
|
||||
"Reference to facility list key";
|
||||
}
|
||||
|
||||
leaf severity {
|
||||
type leafref {
|
||||
path "../config/severity";
|
||||
}
|
||||
description
|
||||
"Reference to severity list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data ";
|
||||
|
||||
uses logging-selectors-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data ";
|
||||
|
||||
uses logging-selectors-config;
|
||||
uses logging-selectors-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping logging-console-config {
|
||||
description
|
||||
"Configuration data for console and vty logging";
|
||||
}
|
||||
|
||||
grouping logging-console-state {
|
||||
description
|
||||
"Operational state data for console and vty logging";
|
||||
}
|
||||
|
||||
grouping logging-console-top {
|
||||
description
|
||||
"Top-level grouping for console logging data";
|
||||
|
||||
container console {
|
||||
description
|
||||
"Top-level container for data related to console-based
|
||||
logging";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for console logging";
|
||||
|
||||
uses logging-console-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for console logging";
|
||||
|
||||
uses logging-console-config;
|
||||
uses logging-console-state;
|
||||
}
|
||||
|
||||
uses logging-selectors-top;
|
||||
}
|
||||
}
|
||||
|
||||
grouping logging-remote-config {
|
||||
description
|
||||
"Configuration data for remote log servers";
|
||||
|
||||
leaf host {
|
||||
type oc-inet:host;
|
||||
description
|
||||
"IP address or hostname of the remote log server";
|
||||
}
|
||||
|
||||
leaf source-address {
|
||||
type oc-inet:ip-address;
|
||||
description
|
||||
"Source IP address for packets to the log server";
|
||||
}
|
||||
|
||||
leaf network-instance {
|
||||
type oc-ni:network-instance-ref;
|
||||
description
|
||||
"The network instance used to reach the log server. If no
|
||||
instance is specified, DEFAULT_INSTANCE is used.";
|
||||
}
|
||||
|
||||
leaf remote-port {
|
||||
type oc-inet:port-number;
|
||||
default 514;
|
||||
description
|
||||
"Sets the destination port number for syslog UDP messages to
|
||||
the server. The default for syslog is 514.";
|
||||
}
|
||||
|
||||
leaf transport-security {
|
||||
type boolean;
|
||||
description
|
||||
"Indicates if syslog transport layer security (TLS) is enabled.";
|
||||
}
|
||||
|
||||
leaf tls-profile-id {
|
||||
type string;
|
||||
description
|
||||
"The ID of this syslog client's TLS profile. TLS profiles are managed
|
||||
using the gNSI Certz service or other certificate management service
|
||||
provided by the system.";
|
||||
reference
|
||||
"https://github.com/openconfig/gnsi/tree/main/certz";
|
||||
}
|
||||
}
|
||||
|
||||
grouping logging-remote-state {
|
||||
description
|
||||
"Operational state data for remote log servers";
|
||||
}
|
||||
|
||||
grouping logging-remote-top {
|
||||
description
|
||||
"Top-level grouping for remote log servers";
|
||||
|
||||
container remote-servers {
|
||||
description
|
||||
"Enclosing container for the list of remote log
|
||||
servers";
|
||||
|
||||
list remote-server {
|
||||
key "host";
|
||||
description
|
||||
"List of remote log servers";
|
||||
|
||||
leaf host {
|
||||
type leafref {
|
||||
path "../config/host";
|
||||
}
|
||||
description
|
||||
"Reference to the host list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for remote log servers";
|
||||
|
||||
uses logging-remote-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for remote log servers";
|
||||
|
||||
uses logging-remote-config;
|
||||
uses logging-remote-state;
|
||||
}
|
||||
uses logging-selectors-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping logging-file-config {
|
||||
description
|
||||
"Configuration data for logfile";
|
||||
|
||||
leaf filename-prefix {
|
||||
type string {
|
||||
length 0..255;
|
||||
}
|
||||
description
|
||||
"A name used for the file. It is expected that an
|
||||
implementation may append timestamp, serial-number or
|
||||
other identifier to the filename.";
|
||||
}
|
||||
|
||||
leaf path {
|
||||
type string {
|
||||
length 0..255;
|
||||
}
|
||||
description
|
||||
"The fully specified path of the folder where the
|
||||
logfile is stored. The path is implementation specific
|
||||
and may include attributes such as a drive identifier.";
|
||||
}
|
||||
|
||||
leaf rotate {
|
||||
type uint32;
|
||||
default 0;
|
||||
description
|
||||
"Used for logfile rotation.
|
||||
Log files are rotated the number of times defined by
|
||||
this leaf.
|
||||
The default value of 1 indicates that there will be one
|
||||
rotation file and one active file. A 0 value indicates
|
||||
old versions are removed rather than rotated.";
|
||||
}
|
||||
|
||||
leaf max-size {
|
||||
type uint32;
|
||||
default 1000;
|
||||
description
|
||||
"Used for logfile rotation.
|
||||
Maximum size in Bytes, logfile may grow to. When logfile
|
||||
reach this size it triggers log rotation. The log file need to
|
||||
be save, closed, and new file open or future log storage.
|
||||
If needed oldest logfile of same prefix shall be deleted to";
|
||||
}
|
||||
|
||||
leaf max-open-time {
|
||||
type uint32;
|
||||
default 1440;
|
||||
description
|
||||
"Used for logfile rotation.
|
||||
Maximum time, in minutes, the logfile can be open. When expires,
|
||||
it triggers log rotation.
|
||||
Actions are same ans when log file reaches its max-size.
|
||||
it need to be closed, save, and new file open or future log
|
||||
storage. If needed oldest logfile of same prefix shall be
|
||||
deleted to ";
|
||||
}
|
||||
}
|
||||
|
||||
grouping logging-file-state {
|
||||
description
|
||||
"Operational state data for logfile";
|
||||
leaf open-logfile {
|
||||
type string{
|
||||
length 0..511;
|
||||
}
|
||||
description
|
||||
"the currently active/open filename prepended by folder path
|
||||
and including suffix appended to filename-prefix by system";
|
||||
}
|
||||
}
|
||||
|
||||
grouping logging-files-top {
|
||||
description
|
||||
"Top-level grouping for local log files";
|
||||
|
||||
container files {
|
||||
description
|
||||
"Enclosing container for the list of log files";
|
||||
|
||||
list file {
|
||||
key "path filename-prefix";
|
||||
description
|
||||
"List of logfiles";
|
||||
|
||||
leaf filename-prefix {
|
||||
type leafref {
|
||||
path "../config/filename-prefix";
|
||||
}
|
||||
description
|
||||
"Reference to the logfiles list key";
|
||||
}
|
||||
|
||||
leaf path {
|
||||
type leafref {
|
||||
path "../config/path";
|
||||
}
|
||||
description
|
||||
"Reference to the logfiles list key";
|
||||
}
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for logfile";
|
||||
uses logging-file-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state data for logfile servers";
|
||||
uses logging-file-config;
|
||||
uses logging-file-state;
|
||||
}
|
||||
uses logging-selectors-top;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping logging-vty-top {
|
||||
description
|
||||
"Top-level grouping for vty logging data";
|
||||
|
||||
container vty {
|
||||
description
|
||||
"Top-level container for data related to vty-based
|
||||
logging (active sessions of ssh, telnet, etc )";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for vty logging";
|
||||
|
||||
uses logging-console-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
config false;
|
||||
description
|
||||
"Operational state data for console logging";
|
||||
uses logging-console-config;
|
||||
uses logging-console-state;
|
||||
}
|
||||
uses logging-selectors-top;
|
||||
}
|
||||
}
|
||||
|
||||
grouping logging-top {
|
||||
description
|
||||
"Top-level grouping for logging data";
|
||||
|
||||
container logging {
|
||||
description
|
||||
"Top-level container for data related to logging / syslog";
|
||||
|
||||
uses logging-console-top;
|
||||
uses logging-remote-top;
|
||||
uses logging-files-top;
|
||||
uses logging-vty-top;
|
||||
|
||||
}
|
||||
}
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
|
||||
}
|
||||
261
Parseurs_logs_Switch/src/modèles/openconfig-system-terminal.yang
Normal file
261
Parseurs_logs_Switch/src/modèles/openconfig-system-terminal.yang
Normal file
@@ -0,0 +1,261 @@
|
||||
module openconfig-system-terminal {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/system/terminal";
|
||||
|
||||
prefix "oc-sys-term";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module defines configuration and operational state data
|
||||
related to remote terminal services such as ssh and telnet.";
|
||||
|
||||
oc-ext:openconfig-version "0.4.0";
|
||||
|
||||
revision "2025-11-10" {
|
||||
description
|
||||
"Add a host-certificate leaf.";
|
||||
reference "0.4.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "0.3.1";
|
||||
}
|
||||
|
||||
revision "2017-09-18" {
|
||||
description
|
||||
"Updated to use OpenConfig types modules";
|
||||
reference "0.3.0";
|
||||
}
|
||||
|
||||
revision "2017-07-06" {
|
||||
description
|
||||
"Move to oc-inet types, add IETF attribution, add RADIUS
|
||||
counters, changed password leaf names to indicate hashed";
|
||||
reference "0.2.0";
|
||||
}
|
||||
|
||||
revision "2017-01-29" {
|
||||
description
|
||||
"Initial public release";
|
||||
reference "0.1.0";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:regexp-posix;
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// identity statements
|
||||
|
||||
// typedef statements
|
||||
|
||||
// grouping statements
|
||||
|
||||
grouping system-terminal-common-config {
|
||||
description
|
||||
"Common configuration data for terminal services";
|
||||
|
||||
leaf timeout {
|
||||
type uint16;
|
||||
units seconds;
|
||||
description
|
||||
"Set the idle timeout in seconds on terminal connections to
|
||||
the system for the protocol.";
|
||||
}
|
||||
|
||||
leaf rate-limit {
|
||||
type uint16;
|
||||
units "conn/min";
|
||||
description
|
||||
"Set a limit on the number of connection attempts per
|
||||
minute to the system for the protocol.";
|
||||
}
|
||||
|
||||
leaf session-limit {
|
||||
type uint16;
|
||||
description
|
||||
"Set a limit on the number of simultaneous active terminal
|
||||
sessions to the system for the protocol (e.g., ssh,
|
||||
telnet, ...) ";
|
||||
}
|
||||
}
|
||||
|
||||
grouping system-terminal-common-state {
|
||||
description
|
||||
"Common operational state data for terminal services";
|
||||
}
|
||||
|
||||
grouping system-terminal-common-top {
|
||||
description
|
||||
"Top-level grouping for common terminal service data";
|
||||
|
||||
container terminal-servers {
|
||||
description
|
||||
"Top-level container for terminal services";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for terminal services";
|
||||
|
||||
uses system-terminal-common-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data ";
|
||||
|
||||
uses system-terminal-common-config;
|
||||
uses system-terminal-common-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping system-ssh-server-config {
|
||||
description
|
||||
"Configuration data for system ssh configuration";
|
||||
|
||||
leaf enable {
|
||||
type boolean;
|
||||
default true;
|
||||
description
|
||||
"Enables the ssh server. The ssh server is enabled by
|
||||
default.";
|
||||
}
|
||||
|
||||
leaf protocol-version {
|
||||
type enumeration {
|
||||
enum V2 {
|
||||
description
|
||||
"Use SSH v2 only";
|
||||
}
|
||||
enum V1 {
|
||||
description
|
||||
"Use SSH v1 only";
|
||||
}
|
||||
enum V1_V2 {
|
||||
description
|
||||
"Use either SSH v1 or v2";
|
||||
}
|
||||
}
|
||||
default V2;
|
||||
description
|
||||
"Set the protocol version for SSH connections to the system";
|
||||
}
|
||||
|
||||
leaf host-certificate {
|
||||
type string;
|
||||
description
|
||||
"SSH Host Certificate string. This is the full content of an openssh host certificate";
|
||||
}
|
||||
|
||||
uses system-terminal-common-config;
|
||||
}
|
||||
|
||||
grouping system-ssh-server-state {
|
||||
description
|
||||
"Operational state data for ssh server";
|
||||
}
|
||||
|
||||
grouping system-ssh-server-top {
|
||||
description
|
||||
"Top-level grouping for ssh server data";
|
||||
|
||||
container ssh-server {
|
||||
description
|
||||
"Top-level container for ssh server";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for the system ssh server";
|
||||
|
||||
uses system-ssh-server-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for the system ssh server";
|
||||
|
||||
uses system-ssh-server-config;
|
||||
uses system-ssh-server-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
grouping system-telnet-server-config {
|
||||
description
|
||||
"Configuration data for telnet server";
|
||||
|
||||
leaf enable {
|
||||
type boolean;
|
||||
default false;
|
||||
description
|
||||
"Enables the telnet server. Telnet is disabled by
|
||||
default";
|
||||
}
|
||||
uses system-terminal-common-config;
|
||||
|
||||
}
|
||||
|
||||
grouping system-telnet-server-state {
|
||||
description
|
||||
"Operational state data for telnet server";
|
||||
}
|
||||
|
||||
grouping system-telnet-server-top {
|
||||
description
|
||||
"Top-level grouping for telnet server ";
|
||||
|
||||
container telnet-server {
|
||||
description
|
||||
"Top-level container for telnet terminal servers";
|
||||
|
||||
container config {
|
||||
description
|
||||
"Configuration data for telnet";
|
||||
|
||||
uses system-telnet-server-config;
|
||||
}
|
||||
|
||||
container state {
|
||||
|
||||
config false;
|
||||
|
||||
description
|
||||
"Operational state data for telnet";
|
||||
|
||||
uses system-telnet-server-config;
|
||||
uses system-telnet-server-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// data definition statements
|
||||
|
||||
// augment statements
|
||||
|
||||
// rpc statements
|
||||
|
||||
// notification statements
|
||||
|
||||
}
|
||||
@@ -0,0 +1,115 @@
|
||||
module openconfig-system-utilization {
|
||||
yang-version "1";
|
||||
|
||||
namespace "http://openconfig.net/yang/system-utilization";
|
||||
prefix "oc-sys-util";
|
||||
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
import openconfig-system { prefix oc-sys; }
|
||||
import openconfig-platform { prefix oc-platform; }
|
||||
|
||||
organization
|
||||
"OpenConfig working group";
|
||||
contact
|
||||
"www.openconfig.net";
|
||||
|
||||
description
|
||||
"This module adds configuration and operational state for
|
||||
system wide resource utilization thresholds.";
|
||||
|
||||
oc-ext:openconfig-version "0.1.0";
|
||||
|
||||
revision "2023-02-13" {
|
||||
description
|
||||
"Add system wide utilization thresholds.";
|
||||
reference
|
||||
"0.1.0";
|
||||
}
|
||||
|
||||
grouping system-resource-utilization-config {
|
||||
description
|
||||
"Configuration data for resource utilization. The configuration added here should
|
||||
apply across all of the components that matches the respective resource.
|
||||
/components/component/*/utilization/resources/resource/name";
|
||||
|
||||
|
||||
leaf name {
|
||||
type string;
|
||||
description
|
||||
"Resource name within the system.";
|
||||
}
|
||||
|
||||
uses oc-platform:resource-utilization-threshold-common;
|
||||
}
|
||||
|
||||
grouping system-resource-utilization-state {
|
||||
description
|
||||
"State data for resource utilization.";
|
||||
|
||||
leaf-list active-component-list {
|
||||
type leafref {
|
||||
path "/oc-platform:components/oc-platform:component/oc-platform:config/oc-platform:name";
|
||||
}
|
||||
|
||||
description
|
||||
"List of references to each component which has this resource.";
|
||||
}
|
||||
}
|
||||
|
||||
grouping system-resource-utilization-top {
|
||||
description
|
||||
"Top level grouping for system wide configuration of resources for
|
||||
all components.";
|
||||
|
||||
container "utilization" {
|
||||
description
|
||||
"System wide resource utilization configuration.";
|
||||
|
||||
container "resources" {
|
||||
description
|
||||
"Enclosing container for the resources in the entire system. The system
|
||||
resource names should be aggregated from the following collections:
|
||||
|
||||
* /components/component/chassis/utilization/resources/resource
|
||||
* /components/component/integrate-circuit/utilization/resources/resource
|
||||
* /components/component/linecard/utilization/resources/resource.";
|
||||
|
||||
list "resource" {
|
||||
key "name";
|
||||
description
|
||||
"The list of all resources across all platform components keyed by
|
||||
resource name.";
|
||||
|
||||
leaf name {
|
||||
type leafref {
|
||||
path "../config/name";
|
||||
}
|
||||
description
|
||||
"References the resource name.";
|
||||
}
|
||||
|
||||
container "config" {
|
||||
description
|
||||
"Configuration data for resource utilization.";
|
||||
uses system-resource-utilization-config;
|
||||
}
|
||||
|
||||
container "state" {
|
||||
config false;
|
||||
description
|
||||
"Operational state data for resource utilization.";
|
||||
|
||||
uses system-resource-utilization-config;
|
||||
uses system-resource-utilization-state;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
augment "/oc-sys:system" {
|
||||
description
|
||||
"Add system resource utilization.";
|
||||
uses system-resource-utilization-top;
|
||||
}
|
||||
}
|
||||
1398
Parseurs_logs_Switch/src/modèles/openconfig-system.yang
Normal file
1398
Parseurs_logs_Switch/src/modèles/openconfig-system.yang
Normal file
File diff suppressed because it is too large
Load Diff
283
Parseurs_logs_Switch/src/modèles/openconfig-vlan-types.yang
Normal file
283
Parseurs_logs_Switch/src/modèles/openconfig-vlan-types.yang
Normal file
@@ -0,0 +1,283 @@
|
||||
module openconfig-vlan-types {
|
||||
|
||||
yang-version "1";
|
||||
|
||||
// namespace
|
||||
namespace "http://openconfig.net/yang/vlan-types";
|
||||
|
||||
prefix "oc-vlan-types";
|
||||
|
||||
// import some basic types
|
||||
import openconfig-extensions { prefix oc-ext; }
|
||||
|
||||
// meta
|
||||
organization "OpenConfig working group";
|
||||
|
||||
contact
|
||||
"OpenConfig working group
|
||||
netopenconfig@googlegroups.com";
|
||||
|
||||
description
|
||||
"This module defines configuration and state variables for VLANs,
|
||||
in addition to VLAN parameters associated with interfaces";
|
||||
|
||||
oc-ext:openconfig-version "3.2.0";
|
||||
|
||||
revision "2022-05-24" {
|
||||
description
|
||||
"Remove module extension oc-ext:regexp-posix by making pattern regexes
|
||||
conform to RFC6020/7950.
|
||||
|
||||
Types impacted:
|
||||
- vlan-range
|
||||
- qinq-id
|
||||
- qinq-id-range";
|
||||
reference "3.2.0";
|
||||
}
|
||||
|
||||
revision "2020-06-30" {
|
||||
description
|
||||
"Add OpenConfig POSIX pattern extensions.";
|
||||
reference "3.1.1";
|
||||
}
|
||||
|
||||
revision "2019-01-31" {
|
||||
description
|
||||
"Add TPID_ANY wildcard match and a QinQ list type.";
|
||||
reference "3.1.0";
|
||||
}
|
||||
|
||||
revision "2018-11-21" {
|
||||
description
|
||||
"Add OpenConfig module metadata extensions.";
|
||||
reference "3.0.1";
|
||||
}
|
||||
|
||||
revision "2018-02-14" {
|
||||
description
|
||||
"Fix bug with name of 802.1ad identity.";
|
||||
reference "3.0.0";
|
||||
}
|
||||
|
||||
revision "2017-07-14" {
|
||||
description
|
||||
"Move top-level vlan data to network-instance; Update
|
||||
identities to comply to style guide; fixed pattern
|
||||
quoting; corrected trunk vlan types; added TPID config to
|
||||
base interface.";
|
||||
reference "2.0.0";
|
||||
}
|
||||
|
||||
revision "2016-05-26" {
|
||||
description
|
||||
"OpenConfig public release";
|
||||
reference "1.0.2";
|
||||
}
|
||||
|
||||
// OpenConfig specific extensions for module metadata.
|
||||
oc-ext:catalog-organization "openconfig";
|
||||
oc-ext:origin "openconfig";
|
||||
|
||||
// extension statements
|
||||
|
||||
// feature statements
|
||||
|
||||
// identity statements
|
||||
|
||||
identity TPID_TYPES {
|
||||
description
|
||||
"Base identity for TPID values that can be matched or that override
|
||||
the VLAN ethertype value";
|
||||
}
|
||||
|
||||
identity TPID_0X8100 {
|
||||
base TPID_TYPES;
|
||||
description
|
||||
"Default TPID value for 802.1q single-tagged VLANs.";
|
||||
}
|
||||
|
||||
identity TPID_0X88A8 {
|
||||
base TPID_TYPES;
|
||||
description
|
||||
"TPID value for 802.1ad provider bridging, QinQ or
|
||||
stacked VLANs.";
|
||||
}
|
||||
|
||||
identity TPID_0X9100 {
|
||||
base TPID_TYPES;
|
||||
description
|
||||
"Alternate TPID value.";
|
||||
}
|
||||
|
||||
identity TPID_0X9200 {
|
||||
base TPID_TYPES;
|
||||
description
|
||||
"Alternate TPID value.";
|
||||
}
|
||||
|
||||
identity TPID_ANY {
|
||||
base TPID_TYPES;
|
||||
description
|
||||
"A wildcard that matches any of the generally used TPID values
|
||||
for singly- or multiply-tagged VLANs. Equivalent to matching
|
||||
any of TPID_0X8100, TPID_0X88A8, TPID_0X9100 and TPID_0x9200.
|
||||
This value is only applicable where the TPID of a packet is
|
||||
being matched.";
|
||||
}
|
||||
|
||||
// typedef statements
|
||||
|
||||
// TODO: typedefs should be defined in a vlan-types.yang file.
|
||||
typedef vlan-id {
|
||||
type uint16 {
|
||||
range 1..4094;
|
||||
}
|
||||
description
|
||||
"Type definition representing a single-tagged VLAN";
|
||||
}
|
||||
|
||||
typedef vlan-range {
|
||||
type string {
|
||||
// range specified as [lower]..[upper]
|
||||
pattern '(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])\.\.(409[0-4]|' +
|
||||
'40[0-8][0-9]|[1-3][0-9]{3}|[1-9][0-9]{1,2}|' +
|
||||
'[1-9])';
|
||||
oc-ext:posix-pattern '^(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])\.\.(409[0-4]|' +
|
||||
'40[0-8][0-9]|[1-3][0-9]{3}|[1-9][0-9]{1,2}|' +
|
||||
'[1-9])$';
|
||||
}
|
||||
description
|
||||
"Type definition representing a range of single-tagged
|
||||
VLANs. A range is specified as x..y where x and y are
|
||||
valid VLAN IDs (1 <= vlan-id <= 4094). The range is
|
||||
assumed to be inclusive, such that any VLAN-ID matching
|
||||
x <= VLAN-ID <= y falls within the range.";
|
||||
}
|
||||
|
||||
typedef qinq-id {
|
||||
type string {
|
||||
pattern
|
||||
'(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])\.' +
|
||||
'((409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])|\*)';
|
||||
oc-ext:posix-pattern
|
||||
'^(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])\.' +
|
||||
'((409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])|\*)$';
|
||||
}
|
||||
description
|
||||
"Type definition representing a single double-tagged/QinQ VLAN
|
||||
identifier. The format of a QinQ VLAN-ID is x.y where X is the
|
||||
'outer' VLAN identifier, and y is the 'inner' VLAN identifier.
|
||||
Both x and y must be valid VLAN IDs (1 <= vlan-id <= 4094)
|
||||
with the exception that y may be equal to a wildcard (*). In
|
||||
cases where y is set to the wildcard, this represents all inner
|
||||
VLAN identifiers where the outer VLAN identifier is equal to
|
||||
x.";
|
||||
}
|
||||
|
||||
typedef qinq-id-range {
|
||||
type union {
|
||||
type string {
|
||||
// match cases where the range is specified as x..y.z
|
||||
pattern
|
||||
'(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])\.\.' +
|
||||
'(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])\.' +
|
||||
'((409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])|\*)';
|
||||
oc-ext:posix-pattern
|
||||
'^(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])\.\.' +
|
||||
'(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])\.' +
|
||||
'((409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])|\*)$';
|
||||
}
|
||||
type string {
|
||||
// match cases where the range is specified as x.y..z
|
||||
pattern
|
||||
'(\*|(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9]))\.' +
|
||||
'(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])\.\.' +
|
||||
'(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])';
|
||||
oc-ext:posix-pattern
|
||||
'^(\*|(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9]))\.' +
|
||||
'(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])\.\.' +
|
||||
'(409[0-4]|40[0-8][0-9]|[1-3][0-9]{3}|' +
|
||||
'[1-9][0-9]{1,2}|[1-9])$';
|
||||
}
|
||||
}
|
||||
description
|
||||
"A type definition representing a range of double-tagged/QinQ
|
||||
VLAN identifiers. The format of a QinQ VLAN-ID range can be
|
||||
specified in two formats. Where the range is outer VLAN IDs
|
||||
the range is specified as x..y.z. In this case outer VLAN
|
||||
identifiers meeting the criteria x <= outer-vlan-id <= y are
|
||||
accepted if and only if the inner VLAN-ID is equal to y - or
|
||||
any inner-tag if the wildcard is specified. Alternatively the
|
||||
ange can be specified as x.y..z. In this case only VLANs with an
|
||||
outer-vlan-id qual to x are accepted (x may again be the
|
||||
wildcard). Inner VLANs are accepted if they meet the inequality
|
||||
y <= inner-vlan-id <= z.";
|
||||
}
|
||||
|
||||
typedef vlan-mode-type {
|
||||
type enumeration {
|
||||
enum ACCESS {
|
||||
description "Access mode VLAN interface (No 802.1q header)";
|
||||
}
|
||||
enum TRUNK {
|
||||
description "Trunk mode VLAN interface";
|
||||
}
|
||||
}
|
||||
description
|
||||
"VLAN interface mode (trunk or access)";
|
||||
}
|
||||
|
||||
typedef vlan-ref {
|
||||
type union {
|
||||
type vlan-id;
|
||||
type string;
|
||||
// TODO: string should be changed to leafref to reference
|
||||
// an existing VLAN. this is not allowed in YANG 1.0 but
|
||||
// is expected to be in YANG 1.1.
|
||||
// type leafref {
|
||||
// path "vlan:vlans/vlan:vlan/vlan:config/vlan:name";
|
||||
// }
|
||||
}
|
||||
description
|
||||
"Reference to a VLAN by name or id";
|
||||
}
|
||||
|
||||
typedef vlan-stack-action {
|
||||
type enumeration {
|
||||
enum PUSH {
|
||||
description
|
||||
"Push a VLAN onto the VLAN stack.";
|
||||
}
|
||||
enum POP {
|
||||
description
|
||||
"Pop a VLAN from the VLAN stack.";
|
||||
}
|
||||
enum SWAP {
|
||||
description
|
||||
"Swap the VLAN at the top of the VLAN stack.";
|
||||
}
|
||||
// TODO: add push-push, pop-pop, push-swap etc
|
||||
}
|
||||
description
|
||||
"Operations that can be performed on a VLAN stack.";
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
1001
Parseurs_logs_Switch/src/modèles/openconfig-vlan.yang
Normal file
1001
Parseurs_logs_Switch/src/modèles/openconfig-vlan.yang
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user