Re: [netmod] LL review of draft-ietf-netmod-intf-ext-yang-03

Robert Wilton <> Fri, 10 March 2017 12:00 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 78D4012954A for <>; Fri, 10 Mar 2017 04:00:56 -0800 (PST)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -14.523
X-Spam-Status: No, score=-14.523 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, USER_IN_DEF_DKIM_WL=-7.5] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (1024-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id t8qlPMqqDtdu for <>; Fri, 10 Mar 2017 04:00:55 -0800 (PST)
Received: from ( []) (using TLSv1.2 with cipher DHE-RSA-SEED-SHA (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 68BB8129545 for <>; Fri, 10 Mar 2017 04:00:54 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple;;; l=7363; q=dns/txt; s=iport; t=1489147254; x=1490356854; h=subject:to:references:from:message-id:date:mime-version: in-reply-to:content-transfer-encoding; bh=tGUkMY64mSTst9tqrLC6k84VVDr75TXWiO7K40ZPBGw=; b=MCqL6N5+kwRNThA5Bfx0xrd+0JKQzzRM8VYnJ5YSgrEIbY+CoxSuRVei wrSqpgv+3pdKqv+retij8xY5iJOaPYcPKAfJ3gA+vN126eLj53GUq1FkD IPXGwOakawrYw9hapsKVCy3ya70aXpjRGvikzrKZGLguNnT72p6t0xax4 k=;
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0AAAwCllMJY/xbLJq1dGgEBAQECAQEBA?= =?us-ascii?q?QgBAQEBhFyEQIoOc5BdlTiCDoYiAoJ4GAECAQEBAQEBAWsohRUBAQEBAgEjDwE?= =?us-ascii?q?FUQsYAgImAgJXBgEMCAEBiXQIsR2CJoppAQEBAQEBBAEBAQEBAQEhgQuFQ4IFg?= =?us-ascii?q?WGBCYdagl8Fj1iMYpI4ilGGUYszg2yEIR84gQMiFggXFT+GVUCKTwEBAQ?=
X-IronPort-AV: E=Sophos;i="5.36,140,1486425600"; d="scan'208";a="653168566"
Received: from (HELO ([]) by with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Mar 2017 12:00:50 +0000
Received: from [] ( []) by (8.14.5/8.14.5) with ESMTP id v2AC0nFh012985; Fri, 10 Mar 2017 12:00:49 GMT
To: Ladislav Lhotka <>,
References: <> <>
From: Robert Wilton <>
Message-ID: <>
Date: Fri, 10 Mar 2017 12:00:46 +0000
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1
MIME-Version: 1.0
In-Reply-To: <>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Archived-At: <>
Subject: Re: [netmod] LL review of draft-ietf-netmod-intf-ext-yang-03
X-Mailman-Version: 2.1.17
Precedence: list
List-Id: NETMOD WG list <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Fri, 10 Mar 2017 12:00:56 -0000

Hi Lada,

To pick up an old thread, I'm updating the interface model per your 
comments below, and I had a few questions that you might have an opinion on.

On 22/12/2016 14:32, Robert Wilton wrote:
> Hi Lada,
> Thanks for the review and comments.
> On 21/12/2016 13:08, Ladislav Lhotka wrote:
>> Hi,
>> I think this is a very useful addition to ietf-interfaces. In general,
>> the document is clearly written and YANG modules nicely designed. Here
>> are my comments:
>> *** Sec. 1
>>      - "This document defines two YANG RFC 7950 [RFC7950] modules …"
>>        looks weird. I'd suggest "… YANG 1.1 [RFC7950] …" instead.
> OK.
>> *** Sec. 2
>>      - first line: s/of of/of/

>> *** Sec. 3.1
>>      - If the "bandwidth" parameter is only used for tuning routing
>>        algorithms and has nothing to do with real bandwidth on the
>>        interface, I would suggest to use a different name
>>        (metric?). Perhaps it may indeed be better to leave this to
>>        routing protocol modules because they can also specify how
>>        exactly such a parameter is used.
> Yes, possibility it would be better to define this as part of the 
> routing models.  The idea here is that the bandwidth would span across 
> the routing protocols rather than be tied to a specific protocol.

I think that we need a better name than just "bandwidth" since this leaf 
doesn't affect the actual bandwidth on the of the link, just the 
bandwidth that is reported to routing protocols to implicitly adjust 
their link metrics.  Hence, I was considering renaming this to 

I also think that it would be good to follow up with the routing folks 
to see if this leaf would be better covered in a general routing model.  
Where do you think is the best place that I raise this, the routing area 
yang design team?

>> *** Sec. 3.6
>>      - The "l3-mtu" parameter is probably the same as "mtu" defined in
>>        ietf-ip. Again, I would suggest to leave the definition of MTU
>>        to each L3 protocol because there may be specific aspects and
>>        constraints.
> The MTU being defined here is an "l2-mtu" parameter.  I.e. the maximum 
> size of the L2 frames that can be sent/received.  For some devices 
> this value is independent of a protocol specific L3 MTU that only 
> affects that particular protocol instance.
I've updated the text to make it clear that it is only a L2 MTU 
configuration leaf, and if not configured, the system will automatically 
decide on the L2 MTU.

>> *** Sec. 3.8
>>      - I think that "transport-layer" is not a good name because in the
>>        ISO OSI model it denotes a particular layer (L4). How about
>>        "iso-osi-layer"?
I agree that "transport-layer" is somewhat ambiguous.

I was wondering whether "service-layer" or "service-type" would work?

Or perhaps it could be called "forwarding-mode"?

>>      - The type of "transport-layer" has three enums, namely
>>        "layer-[123]". I would suggest to use descriptive names
>>        ("physical-layer" etc.), include the remaining layers of the ISO
>>        OSI model, and maybe also define it as a typedef - or does this
>>        belong to ietf-inet-types?
I'm not sure that defining the higher layers of the OSI model helps.  
Perhaps using identities would be a better choice?


But I prefer "layer-2" over "data-link-layer" since I think that term is 
much more widespread.  I'm also not quite sure whether "physical-layer" 
is actually the right term, I think that is probably really "below-layer-2"

>>      - Is a leaf sufficient? I think some interfaces can be in multiple
>>        layers at the same time (e.g. an ATM interface is L3 but can
>>        also be L2 for Classical IP over ATM). Or is the idea that such
>>        an interface will be split into two entries of the "interface"
>>        list?
> This needs some further thought/work.
I think that using sub-interfaces is the cleanest way of doing this, so 
each sub-interface can be offering a service at a different layer.

> The main idea here was to be able to label sub-interfaces as 
> supporting only L2 services or L3 services, since on some platforms 
> different types of interfaces get instantiated internally.
>> *** YANG modules
>>      - Descriptions are not consistently formatted. I think that the
>>        current BCP is to start description text on the same line as the
>>        "description" keyword only if it all fits on one line.
>>      - I don't have a strong opinion on this but it might increase
>>        readability if the number of augments is reduced. Perhaps at
>>        least augments that contain only one node could be made into one
>>        (and the "feature" and "when" statements moved to the nodes'
>>        definitions.
> Yes, I'll fix these, probably using Martin's suggested approach.
I've fixed the descriptions, and merged all the augments except for the 
sub-interface one (which is an if-feature conditional augment of a 
mandatory node).

I also have a question about the "encapsulation" container that is 
currently defined as:

      * Various types of interfaces support a configurable layer 2
      * encapsulation, any that are supported by YANG should be
      * listed here.
      * Different encapsulations can hook into the common encaps-type
      * choice statement.
     container encapsulation {
         "derived-from-or-self(if:type, 'ianaift:ethernetCsmacd') or
          derived-from-or-self(if:type, 'ianaift:ieee8023adLag') or
          derived-from-or-self(if:type, 'ianaift:pos') or
          derived-from-or-self(if:type, 'ianaift:atmSubInterface') or
          derived-from-or-self(if:type, 'ethSubInterface')" {

           "All interface types that can have a configurable L2
          * TODO - Should we introduce an abstract type to make this
          *        extensible to new interface types, or vendor
          *        specific interface types?

         "Holds the OSI layer 2 encapsulation associated with an
       choice encaps-type {
         description "Extensible choice of L2 encapsulations";

I was considering removing the when statement to generalize this, since 
the case statements can be constricted to suitable interface types using 
when statements anyway.  E.g. I'm proposing to changing it to something 
like this:

      * Various types of interfaces support a configurable
      * encapsulation.
      * Different encapsulations (often layer 2) can hook into the
      * common encaps-type choice statement.
     container encapsulation {
         "Holds the encapsulation (often layer 2) associated with an
       choice encaps-type {
           "Extensible choice of encapsulations";

Do you have a view on this?


> Thanks again,
> Rob
>> Lada