{"id":378,"date":"2016-09-09T11:39:45","date_gmt":"2016-09-09T10:39:45","guid":{"rendered":"http:\/\/blogs.it.ox.ac.uk\/nexus\/?p=378"},"modified":"2016-09-09T11:52:53","modified_gmt":"2016-09-09T10:52:53","slug":"rdp-the-connection-has-been-lost","status":"publish","type":"post","link":"https:\/\/blogs.it.ox.ac.uk\/nexus\/2016\/09\/09\/rdp-the-connection-has-been-lost\/","title":{"rendered":"RDP: &#8220;The connection has been lost.&#8221;"},"content":{"rendered":"<p>This message was appearing a little too often for my liking:<\/p>\n<div id=\"attachment_379\" style=\"width: 328px\" class=\"wp-caption aligncenter\"><a href=\"http:\/\/blogs.it.ox.ac.uk\/nexus\/files\/2016\/09\/download.jpg\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-379\" class=\"wp-image-379 size-full\" src=\"http:\/\/blogs.it.ox.ac.uk\/nexus\/files\/2016\/09\/download.jpg\" alt=\"download\" width=\"318\" height=\"208\" srcset=\"https:\/\/blogs.it.ox.ac.uk\/nexus\/files\/2016\/09\/download.jpg 318w, https:\/\/blogs.it.ox.ac.uk\/nexus\/files\/2016\/09\/download-300x196.jpg 300w\" sizes=\"auto, (max-width: 318px) 100vw, 318px\" \/><\/a><p id=\"caption-attachment-379\" class=\"wp-caption-text\">&#8220;The connection has been lost. Attempting to reconnect to your session\u2026 &#8220;<\/p><\/div>\n<p align=\"left\">In many cases\u00a0this problem is caused by a feature known as\u00a0Auto-Tuning. This is supposed to\u00a0continually adjust TCP\/IP receive window size based on the network conditions at any given moment. But on a less-than-perfect network this can cause time-out issues.<\/p>\n<p>The TCP receive window size is the maximum amount of incoming\u00a0data that can be buffered at once\u00a0on the receiving side of a connection. The sending host can send only that amount of data before waiting for an acknowledgement and then\u00a0a &#8220;receive window&#8221; update from the receiving host.<\/p>\n<p>The TCP\/IP stack nowadays tunes itself with larger default window sizes than it used to. Instead of using a hard-coded default value, TCP automatically adjusts the window size &#8211; beneficial\u00a0during bulk data transmission by reducing the number of segments sent with\u00a0large\u00a0amounts\u00a0of data.<\/p>\n<p>Auto-Tuning continually determines the optimal receive window size by measuring bandwidth delays and the application&#8217;s retrieve rate. In an ideal world this means excellent performance even with\u00a0changing network conditions. In the real world this means occasional timeout errors&#8230;<\/p>\n<p>This doesn&#8217;t just affect Remote Desktop &#8211; some older version of\u00a0Outlook\u00a0used to get error\u00a00x800CCC0F (&#8220;The connection to the server was interrupted. If this problem continues, contact your server administrator or Internet service provider (ISP).&#8221;) for the same reason.<\/p>\n<h2>What can be done?<\/h2>\n<p align=\"left\">To tweak your\u00a0auto-tune settings:<\/p>\n<p align=\"left\">Run CMD as an administrator and enter this command:<\/p>\n<pre><code>netsh interface tcp set global autotuninglevel=restricted<\/code><\/pre>\n<p>If you later wish to reverse this setting:<\/p>\n<pre>netsh interface tcp set global autotuninglevel=normal<\/pre>\n<p>To see what you&#8217;ve got right now:<\/p>\n<p><code>netsh interface tcp show global<br \/>\n<\/code><\/p>\n<p>The permited\u00a0values for the A<em>utoTuningLevel<\/em> parameter are:<\/p>\n<p><strong>disabled<\/strong><br \/>\nSets the receive window at the default value.<br \/>\n<strong>highlyrestricted<\/strong><br \/>\nLets the receive window grow beyond the default value, but does so very conservatively.<br \/>\n<strong>restricted<\/strong><br \/>\nLets the receive window grow beyond the default value, but limits such growth in some scenarios.<br \/>\n<strong>normal<\/strong><br \/>\nLets the receive window grow to accommodate most scenarios.<br \/>\n<strong>experimental<\/strong><br \/>\nLets the receive window grow to accommodate extreme scenarios.<\/p>\n<p><strong><span style=\"color: #ff0000\">N.B.<\/span><\/strong>\u00a0\u00a0The experimental value may <em>decrease<\/em> performance and\u00a0should only be used for testing.<\/p>\n<p><code>\u00a0<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>This message was appearing a little too often for my liking: In many cases\u00a0this problem is caused by a feature known as\u00a0Auto-Tuning. This is supposed to\u00a0continually adjust TCP\/IP receive window size based on the network conditions at any given moment. &hellip; <a href=\"https:\/\/blogs.it.ox.ac.uk\/nexus\/2016\/09\/09\/rdp-the-connection-has-been-lost\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":107,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-378","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/blogs.it.ox.ac.uk\/nexus\/wp-json\/wp\/v2\/posts\/378","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blogs.it.ox.ac.uk\/nexus\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.it.ox.ac.uk\/nexus\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.it.ox.ac.uk\/nexus\/wp-json\/wp\/v2\/users\/107"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.it.ox.ac.uk\/nexus\/wp-json\/wp\/v2\/comments?post=378"}],"version-history":[{"count":4,"href":"https:\/\/blogs.it.ox.ac.uk\/nexus\/wp-json\/wp\/v2\/posts\/378\/revisions"}],"predecessor-version":[{"id":383,"href":"https:\/\/blogs.it.ox.ac.uk\/nexus\/wp-json\/wp\/v2\/posts\/378\/revisions\/383"}],"wp:attachment":[{"href":"https:\/\/blogs.it.ox.ac.uk\/nexus\/wp-json\/wp\/v2\/media?parent=378"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.it.ox.ac.uk\/nexus\/wp-json\/wp\/v2\/categories?post=378"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.it.ox.ac.uk\/nexus\/wp-json\/wp\/v2\/tags?post=378"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}