Re: [Lwip] draft-gomez-lwig-tcp-constrained-node-networks-03

"Scharf, Michael (Nokia - DE/Stuttgart)" <michael.scharf@nokia.com> Fri, 11 August 2017 08:37 UTC

Return-Path: <michael.scharf@nokia.com>
X-Original-To: lwip@ietfa.amsl.com
Delivered-To: lwip@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 1245E1324ED for <lwip@ietfa.amsl.com>; Fri, 11 Aug 2017 01:37:26 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.921
X-Spam-Level:
X-Spam-Status: No, score=-1.921 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=nokia.onmicrosoft.com
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id fylUTv4wKyDn for <lwip@ietfa.amsl.com>; Fri, 11 Aug 2017 01:37:21 -0700 (PDT)
Received: from EUR03-VE1-obe.outbound.protection.outlook.com (mail-eopbgr50134.outbound.protection.outlook.com [40.107.5.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 9C5171324C9 for <lwip@ietf.org>; Fri, 11 Aug 2017 01:37:20 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nokia.onmicrosoft.com; s=selector1-nokia-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=JZ/0Ffm7T9KmcejOxyyUFypoX1a7RPD7pY5pwH1Y66E=; b=axXbSYeee31WLlCnPq+r/F+blXw6UieStfhx3TbcAjQb0eXoPu3EUnHLK1lgMhXxOfBHK53OuLln7sD6XW30OJ3Cn/eE0DvDYXYyFtWc8aGL+4kkSE5AiPAu7nmXCEAd/sxTN1IRC4izf3IwV9hPiSQZUtsjROIqNJiBKGVFvMU=
Received: from AM5PR0701MB2547.eurprd07.prod.outlook.com (10.173.92.15) by AM5PR0701MB2900.eurprd07.prod.outlook.com (10.168.156.11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.1.1341.9; Fri, 11 Aug 2017 08:37:17 +0000
Received: from AM5PR0701MB2547.eurprd07.prod.outlook.com ([fe80::f4af:c8dd:95b1:766d]) by AM5PR0701MB2547.eurprd07.prod.outlook.com ([fe80::f4af:c8dd:95b1:766d%18]) with mapi id 15.01.1341.019; Fri, 11 Aug 2017 08:37:17 +0000
From: "Scharf, Michael (Nokia - DE/Stuttgart)" <michael.scharf@nokia.com>
To: Hannes Tschofenig <hannes.tschofenig@gmx.net>, "jon.crowcroft@cl.cam.ac.uk" <jon.crowcroft@cl.cam.ac.uk>, Carles Gomez Montenegro <carlesgo@entel.upc.edu>, "lwip@ietf.org" <lwip@ietf.org>
Thread-Topic: draft-gomez-lwig-tcp-constrained-node-networks-03
Thread-Index: AQHTEc1YE3LKlnpxEky9nwgp8XjDYaJ+1guQ
Date: Fri, 11 Aug 2017 08:37:17 +0000
Message-ID: <AM5PR0701MB2547A9404D9176B827ABECCC93890@AM5PR0701MB2547.eurprd07.prod.outlook.com>
References: <ad1ebfaf-03b4-9b3c-4a2d-da3eda7c4648@gmx.net>
In-Reply-To: <ad1ebfaf-03b4-9b3c-4a2d-da3eda7c4648@gmx.net>
Accept-Language: en-US, de-DE
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-originating-ip: [135.245.212.24]
x-ms-publictraffictype: Email
x-microsoft-exchange-diagnostics: 1; AM5PR0701MB2900; 6:pdp/inF0MvgLDwkNq7VE6K9HWZM8/IYlCkfuqSsYYMmSTbGESvCJjwy32++v8D1Fi1WEr1oPpAYR5PAFF+lKNXImeSzfq3Hckn+jDYw/kymUusbroH3xflWyp8HSQPT1JINe9t+sciKdeWEpEsOoJp0q6I9Ha9qPoFBFEo864gGGYp8R69QBMs4kXbSBUS685CuI7znVer+u9AoNNDZdD2bnq0jdKygR0rbnctsV+yxBBlGqHgEgNPtKX+s1hsS6s/UsvqbIUUb3gfnvYdo+P4VWK8rJQaQzi/L5WJUu2XXf8dAfaszSuoEi8Ha2P3uia5HVH1oGsd1PWHXwYDekbg==; 5:Wbeiee7nmQfrBp47z3vD7GnjdqHZ+oW0RVISjhCUsOKaiiR2KJIxcRelmB1HHAW+pScDEG/a4AkAW4FLLeFsS3eOj58jo+pnzZH8s61lBFrqmgaBnW0XQuj7mTu84qMDkPdQGHtOhEQvhtkvBW/Xhw==; 24:Lw6Pt/MlnQ2A0dDFa87QysYVNCCtleqWjOkYIhuW98pp9KSn7evgYPR97zJxhFJJO3AZcZWd6aBtNAj9D9I8cNg1ZkDiAU7RGSF4Mi9xdx0=; 7:P9hy9d4BwK3kDLYNMpFkHQqKTwt7Y70CXP6QQicb+eRVYYyZeMUcwAy+4K0Y7WHzBYWE2TMqO7bbYYfe+zuW3fdrgAhqbBMAWTfTwn7NzMdWCddwgQuIjdHVyrlwUmoq5locxVBZXQRPIOMYKeKJ55BFg0zY1EpzMEgACu7PMbBtEnvwph+Pnm+Xaa4RzzCFTuwR8vKqC/S/QihmesH2LRUWt4GAbXBOiLIgIqVhL/s=
x-ms-office365-filtering-correlation-id: ddea749b-65fd-41b8-ccdf-08d4e0942c8b
x-ms-office365-filtering-ht: Tenant
x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(300000502095)(300135100095)(22001)(2017030254152)(300000503095)(300135400095)(48565401081)(2017052603124)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:AM5PR0701MB2900;
x-ms-traffictypediagnostic: AM5PR0701MB2900:
authentication-results: spf=none (sender IP is ) smtp.mailfrom=michael.scharf@nokia.com;
x-exchange-antispam-report-test: UriScan:(158342451672863)(278428928389397)(192374486261705)(82608151540597)(248736688235697)(21532816269658);
x-microsoft-antispam-prvs: <AM5PR0701MB29000F4D913D03129EF7F1BB93890@AM5PR0701MB2900.eurprd07.prod.outlook.com>
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(5005006)(8121501046)(100000703101)(100105400095)(93006095)(93001095)(10201501046)(3002001)(6055026)(6041248)(20161123558100)(20161123564025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123562025)(20161123555025)(20161123560025)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:AM5PR0701MB2900; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:AM5PR0701MB2900;
x-forefront-prvs: 03965EFC76
x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(6009001)(39860400002)(377454003)(13464003)(50084003)(199003)(189002)(53546010)(2171002)(3280700002)(305945005)(6506006)(7736002)(2950100002)(189998001)(7696004)(2501003)(66066001)(14454004)(229853002)(53936002)(74316002)(5250100002)(3660700001)(102836003)(81156014)(81166006)(8676002)(3846002)(230783001)(6116002)(33656002)(2900100001)(8936002)(97736004)(966005)(2906002)(25786009)(6246003)(76176999)(106356001)(105586002)(6436002)(86362001)(54356999)(101416001)(5660300001)(68736007)(6306002)(50986999)(478600001)(9686003)(99286003)(55016002); DIR:OUT; SFP:1102; SCL:1; SRVR:AM5PR0701MB2900; H:AM5PR0701MB2547.eurprd07.prod.outlook.com; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en;
received-spf: None (protection.outlook.com: nokia.com does not designate permitted sender hosts)
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
MIME-Version: 1.0
X-OriginatorOrg: nokia.com
X-MS-Exchange-CrossTenant-originalarrivaltime: 11 Aug 2017 08:37:17.2286 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 5d471751-9675-428d-917b-70f44f9630b0
X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM5PR0701MB2900
Archived-At: <https://mailarchive.ietf.org/arch/msg/lwip/ZvgHW80pLvgIkHWbpGztyDgrwcs>
Subject: Re: [Lwip] draft-gomez-lwig-tcp-constrained-node-networks-03
X-BeenThere: lwip@ietf.org
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: Lightweight IP stack <lwip.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/lwip>, <mailto:lwip-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/lwip/>
List-Post: <mailto:lwip@ietf.org>
List-Help: <mailto:lwip-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/lwip>, <mailto:lwip-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 11 Aug 2017 08:37:26 -0000

Hi Hannes,

Thanks a lot for this very valuable review, which will be addressed. Please give us some time to come back with actual wording proposals.

Thanks

Michael


> -----Original Message-----
> From: Hannes Tschofenig [mailto:hannes.tschofenig@gmx.net]
> Sent: Thursday, August 10, 2017 1:40 PM
> To: jon.crowcroft@cl.cam.ac.uk; Scharf, Michael (Nokia - DE/Stuttgart)
> <michael.scharf@nokia.com>; Carles Gomez Montenegro
> <carlesgo@entel.upc.edu>; lwip@ietf.org
> Subject: draft-gomez-lwig-tcp-constrained-node-networks-03
> 
> Hi Michael, Jon, Carles
> 
> it is great that you have worked on this topic and, as stated during the Prague
> IETF meeting, I believe this document should become a WG item of the LWIG
> working group.
> 
> I nevertheless have a couple of comments & questions.
> 
> - Who do you think is the main audience for this draft? Is it primarily written
> for implementers of embedded TCP stacks or is it rather written for
> embedded developers who have to decide what stack and what features of
> TCP to use?
> 
> If you ask me, I prefer it to be the latter. The reason is that there are very
> few implementers who write their own embedded TCP stack. There is,
> however, also an implication if you are aiming for the latter group, namely
> you cannot expect them to know all the details of TCP well. So, you need to
> present them with enough background so that they can make informed
> trade-off decisions.
> 
> - The title of the document was probably the reason why I only noticed it
> recently. For some reason the term "Constrained Node Networks" does not
> stick well with me. I would have expect to see something like "Guidance for
> TCP Usage for Internet of Things". I am also uncertain why you claim that the
> document defines a profile. It does not really define any profiles as far as I
> can tell.
> 
> - I would like to see some discussion about the communication patterns.
> For example, in the draft you talk about transactions (and I assume you mean
> request/response interactions). Are you focusing on those only or do you
> also consider cases of firmware updates into account? (In Section
> 4.8 you briefly mention firmware updates.) Have you looked at traffic
> patterns of some IoT applications?
> 
> - Section 7 with the information about the protocol stacks is great. I hope you
> will complete the table some time in the near future and provide additional
> information about RAM requirements as well (in addition to the codesize).
> 
> More detailed comments:
> 
> You write:
>    "In order to meet the requirements that
>    stem from CNNs, the IETF has produced a suite of protocols
>    specifically designed for such environments
>    [I-D.ietf-lwig-energy-efficient]."
> 
> The IETF approach on IoT in general has been to re-use as much as possible
> rather than to develop a whole new universe just for IoT. There are,
> however, a few new protocol developments but those are not really
> described well in [I-D.ietf-lwig-energy-efficient] since [I-D.ietf-lwig-energy-
> efficient] talks specifically about energy efficiency.
> 
> [I-D.tschofenig-core-coap-tcp-tls] has been replaced by [I-D.ietf-core-coap-
> tcp-tls].
> 
> You write:
> 
>    "On the other hand, other application layer protocols not specifically
>    designed for CNNs are also being considered for the IoT space.  Some
>    examples include HTTP/2 and even HTTP/1.1, both of which run over TCP
>    by default [RFC7540][RFC2616], and the Extensible Messaging and
>    Presence Protocol (XMPP) [RFC 6120].  TCP is also used by non-IETF
>    application-layer protocols in the IoT space such as MQTT and its
>    lightweight variants [MQTTS]."
> 
> I don't think the reference to [MQTTS] is appropriate. The other variant of
> MQTT, which exists as a standardized protocol is MQTT-SN and it uses UDP (if
> I recall correctly). As such, it does not fit into the argument you are making
> about TCP usage.
> 
> XMPP is also not a good example since it is mostly used on gateways rather
> than low end IoT devices. It is just a very verbose protocol.
> 
> Section 2 about "Characteristics of CNNs relevant for TCP" somehow feels a
> bit misplaced. I am wondering whether there is any loss in value of the
> document if you delete this entire section. RFC 7228, which you reference
> already in the abstract, talks about the constraints of IoT devices and there is
> probably no need to repeat them again (and if you think so then maybe it fits
> better into the introduction).
> 
> Section 3 talks about the scenario and speaks about a model where
> constrained devices connect to unconstrained servers (cloud). What about
> cases where the TCP server itself is running on an IoT device? It appears that
> you consider such a scenario out of scope. Also the text in Section 4.1 gives
> me that impression.
> 
> Section 4 is where the meat of the document is. I personally would have
> structured the document a bit differently. It seems to me that there is the
> impression in the engineering community that a TCP stack is complex (and
> therefore codesize-wise large) and requires a lot of RAM. I would have
> probably started by informing the reader of where the complexity comes
> from and what "tuning" can be done to make it more lightweight.
> 
> 4.2. Maximum Segment Size (MSS)
> 
> Am I reading the recommendations correctly? You have three cases: If the
> underlying layer supports a frame size of ...
> 
>  1) < 1280 bytes THEN use an adaptation layer (like 6lowpan to make it look
> like case #2)
>  2) 1280 bytes THEN you are OK.
>  3) > 1280 bytes THEN limit the MTU to 1280 bytes and you SHOULD use the
> Path MTU mechanism.
> 
> 4.3 Window Size
> 
> You write:
> "
>    A TCP stack can reduce the implementation complexity by advertising a
>    TCP window size of one MSS, and also transmit at most one MSS of
>    unacknowledged data, at the cost of decreased performance.  This size
>    for receive and send window is appropriate for simple message
>    exchanges in the CNN space, reduces implementation complexity and
>    memory requirements, and reduces overhead (see section 4.7).
> "
> 
> I don't think it is a matter of implementation complexity on how large the
> window size should be but rather a question of how much RAM you have. I
> think that this section could better describe the performance tradeoffs.
> 
> You write:
> "
>    A TCP window size of one MSS follows the same rationale as the
>    default setting for NSTART in [RFC7252], leading to equivalent
>    operation when CoAP is used over TCP.
> "
> 
> Could you explain the relationship between MSS and the NSTART concept in
> CoAP in more details? I only see an indirect relationship (via the congestion
> control mechanism) but not a direct one. I am also uncertain what you mean
> by the reference to CoAP over TCP.
> 
> Expand and ideally explain all abbreviations, such as RTO
> 
> You write:
> 
> "  For devices that can afford greater TCP window size, it may be useful
>    to allow window sizes of at least five MSSs, in order to allow Fast
>    Retransmit and Fast Recovery [RFC5681].
> "
> 
> Could you expand a bit on what you mean by "can afford"? If you have x
> amount of additional KB RAM then ....
> 
> 
> 4.4 RTO estimation
> 
> You write:
> 
> "
>    A fundamental
>    trade-off exists between responsiveness and correctness of RTOs
>    [I-D.ietf-tcpm-rto-consider].
> "
> 
> Maybe you can explain the reader what the tradeoff is rather than just
> pointing to the document. You make an attempt in the text following the
> statement but it is incomplete (at least according to my reading of the tcp-
> rto-consider document.) At least I would have expected that you provide the
> recommendation from [I-D.ietf-tcpm-rto-consider] regarding the RTO setting
> or mention the timer setting in the DTLS/TLS profiles for IoT.
> 
> I also believe that the paragraph about the work on congestion control for
> CoAP isn't really appropriate in this document. I would delete it.
> I understand why Carles wants to have it in there though ;-)
> 
> 4. TCP connection lifetime
> 
> In the discussions regarding using TCP keep-alive messages for CoAP over
> TCP we essentially got no response:
> https://www.ietf.org/mail-archive/web/maprg/current/msg00016.html
> 
> I would expect a recommendation whether TCP keep-alives should or should
> not be used. With CoAP over TCP we have also defined a separate ping/pong
> mechanism.
> 
> 4.7.  TCP options
> 
> You write:
> 
> "
>    TCP implementation for a constrained device that uses a single-MSS
>    TCP receive or transmit window size may not benefit from supporting
>    the following TCP options: Window scale [RFC1323], TCP Timestamps
>    [RFC1323], Selective Acknowledgements (SACK) and SACK-Permitted
>    [RFC2018].  Other TCP options should not be used, in keeping with the
>    principle of lightweight operation.
> 
>    Other TCP options should not be supported by a constrained device, in
>    keeping with the principle of lightweight implementation and
>    operation.
>    "
> 
> The last sentence starting with "Other TCP options ..." appears twice.
> 
> I am not sure I understand the recommendation: Are you saying that "TCP
> implementation for a constrained device that uses a single-MSS TCP receive
> or transmit window size should not implement any TCP options?"
> 
> Then, for all other devices should they implement SACK and TFO?
> 
> Maybe you want to explain your rational a bit more, particularly under why
> you do not consider certain TCP options useful in an IoT environment.
> 
> 4.8.  Delayed Acknowledgments
> 
> The recommendation is not clear to me. It sounds like you are suggesting to
> almost dynamically adjust the ACKs based on the type of traffic being sent.
> 
> 5. Security Considerations
> 
> I don't think that the The TCP Authentication Option is a useful option for IoT
> deployments. At least I haven't even heard anyone suggesting it to be used
> so far. Most standards (even outside the IETF) recommend the use of TLS.
> 
> 8. References
> 
> IMHO there are too many references in the normative reference section. I
> would put the background reading into the informative section.
> 
> Ciao
> Hannes