Skip to content

Commit

Permalink
revert oc-if-ip counters
Browse files Browse the repository at this point in the history
  • Loading branch information
dplore committed Jul 28, 2023
1 parent 7a7a74f commit 4a03123
Show file tree
Hide file tree
Showing 2 changed files with 113 additions and 47 deletions.
151 changes: 104 additions & 47 deletions release/models/interfaces/openconfig-if-ip.yang
Original file line number Diff line number Diff line change
Expand Up @@ -44,21 +44,7 @@ module openconfig-if-ip {
Section 4.c of the IETF Trust's Legal Provisions Relating
to IETF Documents (http://trustee.ietf.org/license-info).";

oc-ext:openconfig-version "3.5.0";

revision "2023-07-14" {
description
"Move counters which apply to both interfaces and subinterfaces to
a common grouping. Deprecate physical counters from subinterface";
reference "3.5.0";
}

revision "2023-06-30" {
description
"Deprecate IPv6 router advertisment config suppress leaf and add config
mode leaf.";
reference "3.4.0";
}
oc-ext:openconfig-version "3.3.0";

revision "2023-04-12" {
description
Expand All @@ -68,7 +54,7 @@ module openconfig-if-ip {

revision "2023-02-06" {
description
"Add IPv6 link-local configuration.";
"Add ipv6 link-local configuration.";
reference "3.2.0";
}

Expand Down Expand Up @@ -237,6 +223,42 @@ module openconfig-if-ip {
"Packet and byte counters for IP transmission and
reception for the address family.";


leaf in-pkts {
type oc-yang:counter64;
description
"The total number of IP packets received for the specified
address family, including those received in error";
reference
"RFC 4293 - Management Information Base for the
Internet Protocol (IP)";
}

leaf in-octets {
type oc-yang:counter64;
description
"The total number of octets received in input IP packets
for the specified address family, including those received
in error.";
reference
"RFC 4293 - Management Information Base for the
Internet Protocol (IP)";
}

leaf in-error-pkts {
// TODO: this counter combines several error conditions --
// could consider breaking them out to separate leaf nodes
type oc-yang:counter64;
description
"Number of IP packets discarded due to errors for the
specified address family, including errors in the IP
header, no route found to the IP destination, invalid
address, unknown protocol, etc.";
reference
"RFC 4293 - Management Information Base for the
Internet Protocol (IP)";
}

leaf in-forwarded-pkts {
type oc-yang:counter64;
description
Expand All @@ -262,6 +284,57 @@ module openconfig-if-ip {
Internet Protocol (IP)";
}

leaf in-discarded-pkts {
type oc-yang:counter64;
description
"The number of input IP packets for the
specified address family, for which no problems were
encountered to prevent their continued processing, but
were discarded (e.g., for lack of buffer space).";
reference
"RFC 4293 - Management Information Base for the
Internet Protocol (IP)";
}

leaf out-pkts {
type oc-yang:counter64;
description
"The total number of IP packets for the
specified address family that the device supplied
to the lower layers for transmission. This includes
packets generated locally and those forwarded by the
device.";
reference
"RFC 4293 - Management Information Base for the
Internet Protocol (IP)";
}

leaf out-octets {
type oc-yang:counter64;
description
"The total number of octets in IP packets for the
specified address family that the device
supplied to the lower layers for transmission. This
includes packets generated locally and those forwarded by
the device.";
reference
"RFC 4293 - Management Information Base for the
Internet Protocol (IP)";
}

leaf out-error-pkts {
// TODO: this counter combines several error conditions --
// could consider breaking them out to separate leaf nodes
type oc-yang:counter64;
description
"Number of IP packets for the specified address family
locally generated and discarded due to errors, including
no route found to the IP destination.";
reference
"RFC 4293 - Management Information Base for the
Internet Protocol (IP)";
}

leaf out-forwarded-pkts {
type oc-yang:counter64;
description
Expand All @@ -283,10 +356,25 @@ module openconfig-if-ip {
"RFC 4293 - Management Information Base for the
Internet Protocol (IP)";
}

leaf out-discarded-pkts {
type oc-yang:counter64;
description
"The number of output IP packets for the
specified address family for which no problem was
encountered to prevent their transmission to their
destination, but were discarded (e.g., for lack of
buffer space).";
reference
"RFC 4293 - Management Information Base for the
Internet Protocol (IP)";
}
}

}



grouping ipv4-global-config {
description
"Configuration data for IPv4 interfaces across
Expand Down Expand Up @@ -851,15 +939,6 @@ module openconfig-if-ip {
description
"Configuration parameters for IPv6 router advertisements.";

leaf enable {
type boolean;
default true;
description
"If set to false, all IPv6 router advertisement functions are
disabled. The local system will not transmit router advertisement
messages and will not respond to router solicitation messages.";
}

leaf interval {
type uint32;
units seconds;
Expand All @@ -878,35 +957,13 @@ module openconfig-if-ip {
}

leaf suppress {
status deprecated;
type boolean;
default false;
description
"When set to true, router advertisement neighbor discovery
messages are not transmitted on this interface.";
}

leaf mode {
type enumeration {
enum ALL {
description
"The system will transmit unsolicited router advertisement
messages and respond to router solicitation requests.";
}
enum DISABLE_UNSOLICITED_RA {
description
"Unsolicted router advertisement messages are not transmitted on
this interface. Responses to router solicitation messages will
be transmitted.";
}
}
default "ALL";
description
"Mode controls which set of behaviors the local system should perform
to support IPv6 router advertisements.";
reference "RFC4861: Neighbor Discovery for IP version 6 (IPv6)";
}

leaf managed {
type boolean;
default false;
Expand Down
9 changes: 9 additions & 0 deletions release/models/interfaces/openconfig-interfaces.yang
Original file line number Diff line number Diff line change
Expand Up @@ -952,6 +952,15 @@ grouping interface-common-counters-state {
or the last-clear time, whichever is most recent.";
oc-ext:telemetry-on-change;
}

leaf resets {
type oc-yang:counter64;
description
"Number of times the interface hardware has been reset. The
triggers and effects of this event are hardware-specifc.";
oc-ext:telemetry-on-change;

}
}

grouping subinterfaces-counters-state {
Expand Down

0 comments on commit 4a03123

Please sign in to comment.