Internet DRAFT - draft-liu-l2vpn-evpn-yang

draft-liu-l2vpn-evpn-yang



Network Working Group                                      A. Liu
Internet Draft		                                 Ericsson
Intended status: Informational
Expires: November 27, 2015                           June 2, 2015



                            Ethernet VPN Yang Model
                       draft-liu-l2vpn-evpn-yang-00.txt

Abstruct

   This document defines a YANG model for Ethernet VPN support. 
   The model includes both configuration and operation to support 
   Ethernet VPN service and deployment.

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), its areas, and its working groups.  Note that 
   other groups may also distribute working documents as Internet-
   Drafts.

   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."

   The list of current Internet-Drafts can be accessed at
   http://www.ietf.org/1id-abstracts.html

   The list of Internet-Draft Shadow Directories can be accessed at
   http://www.ietf.org/shadow.html

   This Internet-Draft will expire on November 27, 2015.

Copyright Notice

   Copyright (c) 2015 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 
   (http://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 Simplified BSD License text as described in




Liu, et al.	        Expires November 27, 2015          [Page 1]

Internet-Draft	        Ethernet VPN Yang Model       November 2015


   Section 4.e of the Trust Legal Provisions and are provided without 
   warranty as described in the Simplified BSD License.

Table of Contents

   1. Introduction  . . . . . . . . . . . . . . . . . . . . . .   1
   2. Conventions . . . . . . . . . . . . . . . . . . . . . . .   1
   3. Terminology . . . . . . . . . . . . . . . . . . . . . . .   1
   4. Data Model  . . . . . . . . . . . . . . . . . . . . . . .   2
   4.1. Overview  . . . . . . . . . . . . . . . . . . . . . . .   2
   4.1.1. EVPN Configuration Model  . . . . . . . . . . . . . .   2
   4.1.2. EVPN Operation Model  . . . . . . . . . . . . . . . .   4
   5. EVPN YANG Model . . . . . . . . . . . . . . . . . . . . .   4
   6. Security Considerations . . . . . . . . . . . . . . . . .  11
   7. IANA Considerations . . . . . . . . . . . . . . . . . . .  11
   8. Acknowlegements . . . . . . . . . . . . . . . . . . . . .  11
   9. References  . . . . . . . . . . . . . . . . . . . . . . .  12
   Authors' Address . . . . . . . . . . . . . . . . . . . . . .  12

1. Introduction

   YANG [RFC6020] is a data definition language used to define a 
   conceptual data model that allows NETCONF[RFC6241] to manage the 
   network devices.

   RFC7432 describes procedures for BGP MPLS based Ethernet VPN. This 
   document defines a YANG data model to configure and manage Ethernet 
   vpn service.

2. Conventions
 
   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 
   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 
   document are to be interpreted as described in [RFC2119]. 

3. Terminology

   EVPN: Ethernet VPN

   ES: Ethernet Segment

   ESI: Ethernet Segment Identifier

   ETAG: Ethernet Tag




Liu, et al.	        Expires November 27, 2015          [Page 2]

Internet-Draft	        Ethernet VPN Yang Model       November 2015


   DF: Designated Forwarder

   EVI: EVPN Instance

4. Data Model

4.1. Overview

   The EVPN YANG model includes configuration part and operation part. 
   The configuration model defines the parameters for EVPN provisioning. 
   The operation defines operation data for EVPN service.

   This model is defined based on the BGP YANG model and bridge YANG model.

4.1.1. EVPN Configuration Model

   The tree structure of the EVPN configuration model is shown as follows:

   module: evpn-bgp
   augment /rt:routing/rt:routing-instance/rt:routing-protocols/rt:routing-protocol:
   +--rw bgp-router
      +--rw af-configuration
         +--rw l2vpn
            +--rw evpn
               +--rw bgp
                  +--rw export
                  |  +--rw auto-derive-route-target?   boolean
                  +--rw import
                  |  +--rw auto-derive-route-target?   boolean
                  +--rw (replication-type)?
                  |  +--:(ingress-replication)
                  |  |  +--rw ingress-replication?     boolean
                  |  +--:(p2mp-replication)
                  |  |  +--rw p2mp-replication?        boolean
                  |  +--:(mp2mp-replication)
                  |     +--rw mp2mp-replication?       boolean
                  +--rw (evpn-label-allocation)?
                  |  +--:(per-service-instance)
                  |  |  +--rw evpn-label-per-service-instance? boolean
                  |  +--:(per-evi)
                  |     +--rw evpn-label-per-evi?      boolean
                  +--rw (flood-label-allocation)?
                  |  +--:(per-vlan)
                  |  |  +--rw flood-label-per-vlan?     boolean
                  |  +--:(per-evi)
                  |     +--rw flood-label-per-evi?      boolean
                  +--rw (active-mode)?
                  |  +--:(single-active-mode)




Liu, et al.	        Expires November 27, 2015          [Page 3]

Internet-Draft	        Ethernet VPN Yang Model       November 2015


                  |  |  +--rw fast-reroute?             boolean
                  |  +--:(all-active-mode)
                  |     +--rw ecmp?                     boolean
                  +--rw df-election
                     +--rw (df-election-method)?
                     |  +--:(modulus-based)
                     |  |  +--rw enable-modulus-based?     boolean
                     |  +--:(highest-random-weight)
                     |     +--rw enable-hrw?               boolean
                     +--rw df-electioin-wait-time?   uint32

   module: evpn-bridging
   augment /rt:bridging/rt:bridging-instance/:
   +--rw bgp-router
   +--rw bridging
      |  +--rw bridging-instance* [name]
      |  |  +--rw flood-unknown-unicast  boolean
      |  |  +--rw evpn-instance [name]
      |  |  |  +--rw service-instance [name]
      |  |  |  +--rw port
   

   augment /if:interfaces/if:interface:
   +--rw bridge-port
   |  +--rw service-instance [name]
   |  |  +--rw l2-bundle [name]
   |  |  +--rw esi
   |  |  |  +--rw type?    Enumeration
   |  |  |  +--rw value    string   
   |  |  +--rw (active-mode)?
   |  |     +--:(single-active)
   |  |        +--rw single-active-mode     boolean
   |  |     +--:(all-active)
   |  |        +--rw all-active-mode        boolean
   |  |  +--rw evpn-arp-proxy               boolean
   |  |  +--rw evpn-nd-proxy                boolean









Liu, et al.	        Expires November 27, 2015          [Page 4]

Internet-Draft	        Ethernet VPN Yang Model       November 2015


4.1.2. EVPN Operation Model

   The tree structure of the EVPN operation model is shown as follows:

   |  +--ro bgp-routes
   |  |  +--ro list route
   |  |  |  +--ro af-specific
   |  |  |  |  +--ro l2vpn
   |  |  |  |  |  +--ro evpn
   |  |  |  |  |  |  +--ro ethernet-auto-discovery-route
   |  |  |  |  |  |  |  +--ro esi
   |  |  |  |  |  |  |  +--ro etag
   |  |  |  |  |  |  +--ro mac-ip-route
   |  |  |  |  |  |  |  +--ro esi
   |  |  |  |  |  |  |  +--ro etag
   |  |  |  |  |  |  |  +--ro mac-addr
   |  |  |  |  |  |  |  +--ro ip-addr  
   |  |  |  |  |  |  +--ro inclusive-multicast-ethernet-tag-route
   |  |  |  |  |  |  |  +--ro etag
   |  |  |  |  |  |  |  +--ro originator-ip-addr
   |  |  |  |  |  |  +--ro Ethernet-segment-route
   |  |  |  |  |  |  |  +--ro esi
   |  |  |  |  |  |  |  +--ro originator-ip-addr





5. EVPN YANG Model
EVPN YANG MODEL
<CODE BEGINS> 
module evpn-bgp {
  namespace "urn:ietf:params:xml:ns:yang:ietf-rip";

  prefix evpn-bgp;

  import ietf-routing {
    prefix "rt";
  }

  augment "/rt:routing/rt:routing-instance/rt:routing-protocols/"
          +"rt:routing-protocol" {
    description
      "This is a top-level container for the BGP.";
    container bgp-router {
      when "./type=bgp"{
      description
        "This is a top-level container for the BGP router.";
      }
      
      container af-configuration {
        container l2vpn {
          description
              "L2vpn specific commands.";



Liu, et al.	        Expires November 27, 2015          [Page 5]

Internet-Draft	        Ethernet VPN Yang Model       November 2015


          
          container evpn{
            description
              "BGP specific commands for l2vpn-evpn.";
            container bgp {
              description
                "BGP specific commands for l2vpn-evpn.";
              container export {
                list export {
                  key "export-id";
                  max-elements "1";
                leaf auto-derive-route-target {
                  type boolean;
                  description
                    "enable auto derive route target";
                }
                uses export;
                description
                  "Export configuration.";
              }
              list import {
                key "import-id";
                max-elements "1";
              container import {
                leaf auto-derive-route-target {
                  type boolean;
                  description
                    "enable auto derive route target";
                } 
                uses import;
                description
                  "Import configuration.";
              }
              choice replication-type {
                description
                  "Configure replication type.";
                case ingress-replication {
                  leaf ingress-replication {
                    type boolean;
                    description
                      "Ingress replication.";
                  }
                }
                case p2mp-replication {
                  leaf p2mp-replication {
                    type boolean;
                    description
                      "replication using p2pm LSP.";
                  }
                }
                case mp2mp-replication {
                  leaf mp2mp-replication {
                    type boolean;
                    description
                      "replication using mp2pm LSP.";
                  }
                }
              }




Liu, et al.	        Expires November 27, 2015          [Page 6]

Internet-Draft	        Ethernet VPN Yang Model       November 2015



              choice evpn-label-allocation {
                description
                  "Configure evpn label allocation method.";
                case per-service-instance {
                  leaf evpn-label-per-service-instance {
                    type boolean;
                    description
                      "evpn label is allocated per service instance.";
                  }
                }
                case per-evi {
                  leaf evpn-label-per-evi {
                    type boolean;
                    description
                      "evpn label is allocated per evpn instance.";
                  }
                }
              }
              choice flood-label-allocation {
                description
                  "Configure flood label allocation method.";
                case per-vlan {
                  leaf flood-label-per-vlan {
                    type boolean;
                    description
                      "flood label is allocated per vlan.";
                  }
                }
                case per-evi {
                  leaf flood-label-per-evi {
                    type boolean;
                    description
                      "flood label is allocated per evpn instance.";
                  }
                }
              }
              choice active-mode {
                description
                  "Enable ecmp when it is all active mode. Enable fast-route when it is single active mode";
                case single-active-mode {
                  leaf fast-reroute {
                    type boolean;
                    description
                      "Enable fast reroute when it is single active mode.";
                  }
                }
                case all-active-mode {
                  leaf ecmp {
                    type boolean;
                    description
                      "Enable ecmp when it is all active mode.";
                  }
                }
              }
            }





Liu, et al.	        Expires November 27, 2015          [Page 7]

Internet-Draft	        Ethernet VPN Yang Model       November 2015



            list df-election {
              container df-election {
                description
                  "configure DF election method and timer interval";
                choice df-election-method {
                  description
                    "Configure df selection method.";
                  case modulus-based {
                    leaf enable-modulus-based {
                      type boolean;
                      description
                        "Enable modulus based df election.";
                    }
                  }
                  case highest-random-weight {
                    leaf enable-hrw {
                      type boolean;
                      description
                        "Enable HRW df selection.";
                    }
                  }
                }
                leaf df-electioin-wait-time {
                  type uint32;
                  description
                    "DF election time interval.";
                }
              } 
            }
          }
        }
      }
    }
  }
}



module: bridging {
  
  prefix evpn-bridging;

  augment "/rt:bridging/rt:bridging-instance" {
    description
      "This is a top-level container for the BRIDGING.";
    
    container bridging {
      list bridging-instance {
        leaf flood-unknown-unicast {
          type boolean;
          description
            "enable unknown unicast flood".
        }
        Leaf evpn-instance {
          type string;
          description
            "configure evpn instance"
        }
      }
    }
  }




Liu, et al.	        Expires November 27, 2015          [Page 8]

Internet-Draft	        Ethernet VPN Yang Model       November 2015
        


  augment "/if:interfaces/if:interface" {
    when "if:type = 'ianaift:bridge'" {
      description
        "Support 802.1Q bridge interface";
    }
    description
      "Define 802.1Q bridge interface";
    
    container bridge-port {
      container l2-bundle {
        leaf name {
          type string {
            length "1..39";
          }
        }
        description
          "l2 bundle name comprising up to 39 characters".
        Leaf esi {
          leaf type {
            type enumeration {
              enum manual {
                description
                  "type 0, manually configured esi".
              }
              enum lacp-based {
                description
                  "type 1, esi is auto-generated based on lacp".
              }
              enum mstp-based {
                description
                  "type 2, esi is auto-generated based on mstp".
              }
              enum mac-based {
                description
                  "type 3, esi is auto-generated based on mac address".
              }
              enum router-id-based {
                description
                  "type 4, esi is auto-generated based on router-id".
              }
              enum as-based {
                description
                  "type 5, esi is auto-generated based on as number".
              }
            }
            description 
              "ESI type".
          }
          leaf value {
          type string {
            length 9.
          }
          description
            "9-bytes esi value".
          }
        }




Liu, et al.	        Expires November 27, 2015          [Page 9]

Internet-Draft	        Ethernet VPN Yang Model       November 2015


        choice active-mode {
          description
            "Configure all active mode or single active mode".
          case single-active-mode {
            leaf single-active {
              type Boolean;
              description
                "Configure single active mode".
            }
          }
          case all-active-mode {
            leaf all-active {
              type boolean;
              description
                "Configure all active mode".
            }
          }
        }
        leaf evpn-arp-proxy {
          type boolean;
          "Enable evpn arp proxy".
        }
        leaf evpn-nd-proxy {
          type boolean;
          "Enable evpn nd proxy".
        }
      }
    }
  }
}


//operational data
  augment "/rt:routing-state/rt:routing-instance/"
          +"rt:routing-protocols/rt:routing-protocol" {
    description
      "This is a top-level container for the BGP operation.";
    container bgp-router{
      container bgp-routes {
        description
          "container of bgp-routes";
        list route {
        container af-specific-config {
          container l2vpn {
            container evpn {
              description
                "evpn routes.";




Liu, et al.	        Expires November 27, 2015          [Page 10]

Internet-Draft	        Ethernet VPN Yang Model       November 2015


              container ethernet-auto-discovery-route {
                container esi {
                  decription "esi";
                  leaf esi-type {
                    type esi-type-enum;
                    description "esi type";
                  }
                  leaf-list esi-value {
                    type uint8;
                    max-element 9;
                    description "esi value";
                  }
                }
                leaf etag {
                  type uint32;
                  description "Ethernet Tag."
                }
              }
              container mac-ip-route {
                container esi {
                  decription "esi";
                  leaf esi-type {
                    type esi-type-enum;
                    description "esi type";
                  }
                  leaf-list esi-value {
                    type uint8;
                    max-element 9;
                    description "esi value";
                  }
                }
                leaf etag {
                  type uint32;
                  description "Ethernet Tag.";
                }
                leaf-list mac-addr {
                  type uint8;
                  max-element 6;
                  description "mac address"; 
                }
                leaf ip-addr {
                  type inet:ip-address;
                  description
                    "Ip address.";
                }
              }
              container inclusive-multicast-Ethernet-Tag-route {
                leaf etag {
                  type uint32;
                  description "Ethernet Tag."
                }
                leaf originator-ip-addr {
                  type inet:ip-address;
                  description
                    "Ip address of the originator."; 
                } 
              }




Liu, et al.	        Expires November 27, 2015          [Page 11]

Internet-Draft	        Ethernet VPN Yang Model       November 2015



              container ethernet-segment-route {
                container esi {
                  decription "esi";
                  leaf esi-type {
                    type esi-type-enum;
                    description "esi type";
                  }
                  leaf-list esi-value {
                    type uint8;
                    max-element 9;
                    description "esi value";
                  }
                }
                leaf originator-ip-addr {
                  type inet:ip-address;
                  description
                    "Ip address of the originator.";
                }
              }
            }
          }          
        }
      }
    }
  }


</CODE ENDS>

6. Security Considerations

   This document does not introduce any new security risk.

7. IANA Considerations

   This document makes no request of IANA.

8. Acknowlegements
   The authors would like to thank Raju Dugyala, Antoni Przygienda, 
   Sajjad Ahmed, Prasanna Chalapathy for their valuable contributions 
   to this document. The authosr would also like to thank Xufeng Liu 
   for his review and comments on the draft.





Liu, et al.	        Expires November 27, 2015          [Page 12]

Internet-Draft	        Ethernet VPN Yang Model       November 2015


9. References

9.1. Normative References

   [RFC7432]    Sajassi, A., Aggarwal, R., Bitar, N., Isaac, A., and 
                J. Uttaro, "BGP MPLS Based Ethernet VPN", RFC 7432, 
                February 2015. 
   [RFC6020]    Bjorklund, M.,"Yang - A Data Modeling Language for 
                the Network Configuration Protocol (NETCONF)", RFC 
                6020, October 2010. 
   [RFC6241]    Enns, R., Bjorklund, M., Schoenwaelder, J., and A.
                Bierman, "Network Configuration Protocol (NETCONF)", 
                RFC 6241, June 2011.
   [RFC2119]    Bradner, S., "Key words for use in RFCs to Indicate 
                Requirement Levels", BCP 14, RFC 2119, March 1997.

9.2. Informative References


Authors' Addresses
   Autumn Liu
   Ericsson	
   Email: autumn.liu@ericsson.com