IPPM Working Group M. Wang Internet-Draft L. Han Intended status: Standards Track China Mobile Expires: 12 January 2023 X. Min J. Guo ZTE Corporation 11 July 2022 A YANG Data Model for Alternate Marking Method draft-wang-ippm-alt-mark-yang-00 Abstract Alternate-Marking Method (AMM) is a technique used to perform packet loss, delay, and jitter measurements on live traffic. This document defines a YANG data model for Alternate Marking Method. Status of This Memo This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet- Drafts is at https://datatracker.ietf.org/drafts/current/. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." This Internet-Draft will expire on 12 January 2023. Copyright Notice Copyright (c) 2022 IETF Trust and the persons identified as the document authors. All rights reserved. This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/ license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License. Wang, et al. Expires 12 January 2023 [Page 1] Internet-Draft YANG Model for AMM July 2022 Table of Contents 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 1.1. Conventions Used in This Document . . . . . . . . . . . . 2 2. Tree Diagram . . . . . . . . . . . . . . . . . . . . . . . . 2 3. Alternate Marking Method YANG Data Model . . . . . . . . . . 3 4. Security Considerations . . . . . . . . . . . . . . . . . . . 11 5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 11 6. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 11 7. References . . . . . . . . . . . . . . . . . . . . . . . . . 11 7.1. Normative References . . . . . . . . . . . . . . . . . . 11 7.2. Informative References . . . . . . . . . . . . . . . . . 12 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 12 1. Introduction Alternate-Marking Method is a technique used to perform packet loss, delay, and jitter measurements on live traffic. This document defines a YANG data model for alternate marking method. 1.1. Conventions Used in This Document The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here. 2. Tree Diagram This section presents a simplified graphical representation of the AMM data model using a YANG tree diagram [RFC8340]. Wang, et al. Expires 12 January 2023 [Page 2] Internet-Draft YANG Model for AMM July 2022 module: spn-inband-oam +--rw configuration +--rw inband-oam +--rw global | +--rw label? uint32 | +--rw fii-mode? enumeration +--rw head-node | +--rw flow* [flow-id] | +--rw flow-id uint32 | +--rw alternate-status? enable-status | +--rw period? alternate-marking-period | +--rw hop-by-hop-status? enable-status | +--rw source-mac? yang:mac-address | +--rw dest-mac? yang:mac-address | +--rw vlan-id? uint16 | +--rw internal-vlan-id? uint16 | +--rw priority-8021p? uint8 | +--rw sip? inet:ip-prefix | +--rw dip? inet:ip-prefix | +--rw protocol? uint8 | +--rw source-port? uint16 | +--rw dest-port? uint16 | +--rw vpn-type? enumeration | +--rw vpn-name? string | +--rw if-name string | +--rw member-port? string +--rw end-node +--rw relation* [flow-id] +--rw flow-id uint32 +--rw (vpn-type)? | +--:(vrf) | | +--rw vrf-name string | +--:(vpws) | | +--rw vpws-name string | +--:(vpls) | +--rw vpls-name string +--rw period? alternate-marking-period +--rw hop-by-hop-status? enable-status +--rw if-name? string 3. Alternate Marking Method YANG Data Model Wang, et al. Expires 12 January 2023 [Page 3] Internet-Draft YANG Model for AMM July 2022 file "ietf-AMM@2022-07-08.yang" module spn-inband-oam { namespace urn:cmcc:yang:spn-inband-oam ; prefix inband-oam; import ietf-inet-types { prefix inet ; revision-date 2013-07-15 ; } import ietf-yang-types { prefix yang ; revision-date 2013-07-15 ; } organization 'China Mobile Communications Corporation (CMCC)' ; contact 'zhangtingting ' ; description 'This module describes device management.'+"\n" + 'Copyright (c) CMCC. All rights reserved' ; revision 2022-05-11 { description 'First draft.' ; } typedef alternate-marking-period { type enumeration { enum 1s { value 1 ; description 'Alternate marking period is 1s.' ; } enum 10s { value 2 ; description 'Alternate marking period is 10s.' ; } enum 30s { value 3 ; description 'Alternate marking period is 30s.' ; } enum 60s { value 4 ; description 'Alternate marking period is 60s.' ; } enum 5min { value 5 ; Wang, et al. Expires 12 January 2023 [Page 4] Internet-Draft YANG Model for AMM July 2022 description 'Alternate marking period is 5min.' ; } } description 'Alternate marking period,including 1s,10s,30s,60s,5min.' ; } typedef enable-status { type enumeration { enum enable { value 1 ; description 'Enables the function.' ; } enum disable { value 0 ; description 'Disables the function.' ; } } description 'Enable status,including enable and disable.' ; } container configuration { description 'Configuration of inband OAM model Info.' ; container inband-oam { description 'Inband OAM flow alternate marking configuration.' ; container global { description 'Global configuration.' ; leaf label { description 'The label ranges from 4 to 6 and 8 to 12(default:12).' ; type uint32 { range '4..6 | 8..12' { description 'The range of the label.' ; } } default 12 ; } leaf fii-mode { description 'Position ID of the guide label.' ; type enumeration { Wang, et al. Expires 12 January 2023 [Page 5] Internet-Draft YANG Model for AMM July 2022 enum non-bottom { value 0 ; } enum bottom { value 1 ; } } default non-bottom ; } } container head-node { description 'Configure inband OAM flow coloring.' ; list flow { description 'Configure inband OAM flow coloring.' ; key flow-id ; leaf flow-id { description 'The flow id to identify a specific flow,ranges from 1 ' + 'to 1048575.' ; type uint32 { range 1..1048575 { description 'The range of flow id.' ; } } } leaf alternate-status { description 'The status of flow alternate marking,including enable ' + 'and disable(default:enable).' ; type enable-status ; default enable ; } leaf period { description 'The period of flow coloring,including 1s,10s,30s,60s a' + 'nd 5min(default:30s).' ; type alternate-marking-period ; default 30s ; } leaf hop-by-hop-status { description 'The status of hop-by-hop coloring,including enable and' + ' disable(default:enable).' ; type enable-status ; default disable ; Wang, et al. Expires 12 January 2023 [Page 6] Internet-Draft YANG Model for AMM July 2022 } leaf source-mac { description 'The source MAC address.' ; type yang:mac-address ; } leaf dest-mac { description 'The destination MAC address.' ; type yang:mac-address ; } leaf vlan-id { description 'The value of vlan ID,ranges from 1 to 4094.' ; type uint16 { range 1..4094 { description 'The range of VLAN ID.' ; } } } leaf internal-vlan-id { description 'The value of internal vlan ID,ranges from 1 to 4094.' ; type uint16 { range 1..4094 { description 'The range of internal VLAN ID.' ; } } } leaf priority-8021p { description 'The value of priority-8021p,ranges from 0 to 7.' ; type uint8 { range 0..7 { description 'The range of priority-8021p.' ; } } } leaf sip { description 'The source ip address.' ; type inet:ip-prefix ; } leaf dip { description 'The destination ip address.' Wang, et al. Expires 12 January 2023 [Page 7] Internet-Draft YANG Model for AMM July 2022 ; type inet:ip-prefix ; } leaf protocol { description 'The protocol number,ranges from 1 to 255.' ; type uint8 { range 1..255 { description 'The range of protocol.' ; } } } leaf source-port { description 'The source port,ranges from 1 to 65535.' ; type uint16 { range 1..65535 { description 'The range of port number.' ; } } } leaf dest-port { description 'The destination port,ranges from 1 to 65535.' ; type uint16 { range 1..65535 { description 'The range of port number.' ; } } } leaf vpn-type { description 'The VPN type of the UNI interface.' ; type enumeration { enum l3vpn { value 0 ; } enum l2vpn { value 1 ; } } default l3vpn ; } leaf vpn-name { description 'The access VPN name of ip flow.' Wang, et al. Expires 12 January 2023 [Page 8] Internet-Draft YANG Model for AMM July 2022 ; type string { length 1..31 { description 'The range of VRF name length.' ; } } } leaf if-name { description 'The UNI interface name of ip flow.' ; type string { length 1..31 ; } mandatory true ; } leaf member-port { description 'The member port of the UNI interface.' ; type string ; } } } container end-node { description 'Configure the relation between Flowid and VPN.' ; list relation { description 'Configure the relation between Flowid and VPN.' ; key flow-id ; leaf flow-id { description 'The flow id to identify a specific flow,ranges from 1 ' + 'to 1048575.' ; type uint32 { range 1..1048575 { description 'The range of flow-id.' ; } } } choice vpn-type { description 'Choose one from vrf and vpws.' ; case vrf { description 'Type is VRF.' ; leaf vrf-name { Wang, et al. Expires 12 January 2023 [Page 9] Internet-Draft YANG Model for AMM July 2022 description 'The name of VRF,this string length ranges from 1 t' + 'o 32.' ; type string { length 1..32 { description 'This string length ranges from 1 to 32.' ; } } mandatory true ; } } case vpws { description 'Type is vpws.' ; leaf vpws-name { description 'The name of VPWS,this string length ranges from 1 ' + 'to 32.' ; type string { length 1..32 { description 'This string length ranges from 1 to 32.' ; } } mandatory true ; } } case vpls { description 'Type is VPLS.' ; leaf vpls-name { description 'The name of VPLS,this string length ranges from 1 ' + 'to 32.' ; type string { length 1..32 { description 'This string length ranges from 1 to 32.' ; } } mandatory true ; } } } leaf period { description 'The flip period of relation,including 1s,10s,30s,60s,5' + 'min(default:30s).' Wang, et al. Expires 12 January 2023 [Page 10] Internet-Draft YANG Model for AMM July 2022 ; type alternate-marking-period ; units ms ; default 30s ; } leaf hop-by-hop-status { description 'The status of hop-by-hop,including enable and disable(' + 'default:disable).' ; type enable-status ; default disable ; } leaf if-name { description 'The UNI interface name of relation.' ; type string { length 1..31 ; } } } } } } } 4. Security Considerations TBD. 5. IANA Considerations TBD. 6. Acknowledgements The authors would like to acknowledge Zhanwei Dou for his contribution to this document. 7. References 7.1. Normative References [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/RFC2119, March 1997, . Wang, et al. Expires 12 January 2023 [Page 11] Internet-Draft YANG Model for AMM July 2022 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, May 2017, . 7.2. Informative References [RFC8340] Bjorklund, M. and L. Berger, Ed., "YANG Tree Diagrams", BCP 215, RFC 8340, DOI 10.17487/RFC8340, March 2018, . Authors' Addresses Minxue Wang China Mobile No.32 Xuanwumen west street Beijing 100053 China Email: wangminxue@chinamobile.com Liuyan Han China Mobile No.32 Xuanwumen west street Beijing 100053 China Email: hanliuyan@chinamobile.com Xiao Min ZTE Corporation Nanjing China Email: xiao.min2@zte.com.cn Jun Guo ZTE Corporation Nanjing China Email: guo.jun2@zte.com.cn Wang, et al. Expires 12 January 2023 [Page 12]