Slow user session in Windows 2016 Server with SQL Server Standard

7

1

I've recently installed a Windows 2016 Server with SQL Server 2016 Standard. The setup is being used as an IIS webserver with Reporting Services.

Anyhow, when connecting to the server via RDP, the performance is terrible - For instance, launching SQL Server Managment Console takes a couple of minutes instead of seconds, even though the overall CPU usage is about 10% or so. Also, just popping up the Startmenu could take 10 sec or so. This all while the website is performing normally.

I'm guessing that since the server is optimized for "Background services" this might have something to do with it, or that there's some new super-smart throtteling going on with interface/user sessions.

The previous server was Windows Server 2013, configured about the same, but without this issue. -- Help me Obi-Wan Kenobi, you're our only hope!

Fredrik Johansson

Posted 2017-03-10T11:04:20.627

Reputation: 73

You might check the settings as listed here: https://superuser.com/questions/1166385/remote-desktop-from-win10-windows-server-2016-slow-but-fast-the-other-way-ar ... You might also check any hardware acceleration settings and make adjustments and test applicable settings there as well. Be sure the Server 2016 videa adapters have the latest drivers as well just in case it's causing by a video driver.

– Pimp Juice IT – 2017-03-10T13:08:29.623

Thank you, but I don't think it's a latency/tcp issue since it's not screen lag but rather time to launch new UI applications that is slow :\ – Fredrik Johansson – 2017-03-10T14:57:58.923

Well at least to rule these out making simple adjustments of applicable settings and then testing is simple enough if you decide to do so just to confirm. I just wanted to kick you some quick thoughts to give you a few things to consider for potential testing to rule out in a process of elimination type scenario if you want. Good luck regardless in your troubleshooting and resolution journey!! – Pimp Juice IT – 2017-03-10T15:20:24.017

Yes, and thank you for this! Every suggestion & hint is much appreciated as I am stuck with this!! But the mystery continues :) Does anyone know if this might be an issue with SQL server w/o SP1? – Fredrik Johansson – 2017-03-14T06:32:23.373

It seems the problem with your RDP, check this for more details https://social.technet.microsoft.com/Forums/lync/en-US/6ed6500d-33f7-4f0c-89fb-8d8442c7a229/extremely-slow-rdp-session-solved?forum=winserverTS

– Ali786 – 2017-03-14T09:22:09.600

(1) Try to disable on both server and client: IPv4 Checksum Offload, Large Receive Offload, Large Send Offload, TCP Checksum Offload. (2) in Control Panel > System > Advanced System Settings > Advanced > Performance > Settings, is it set to Adjust for best performance? (3) Does netsh interface tcp show heuristics show heuristics as disabled? (4) Did you try to disable your antivirus? – harrymc – 2017-03-14T19:52:42.187

Optimized for Background Services is the appropriate setting for servers and will not cause RDP to perform poorly. – I say Reinstate Monica – 2017-03-14T19:53:56.020

Anything of interest logged in any of the Windows Event Logs? – I say Reinstate Monica – 2017-03-14T19:54:42.140

@Twisty: Right, but it would be interesting to see if Adjust for best performance changes anything. – harrymc – 2017-03-14T20:02:59.973

@harrymc I'm referring to the OPs mention of the server is optimized for "Background services" (System Properties > Advanced tab > Performance > Settings... > Advanced tab > Adjust for best performance of:). I'm not referring to the Adjust for best performance setting you're referring to on the Visual Effects tab. – I say Reinstate Monica – 2017-03-14T20:08:14.360

Thank you for all suggestions so far! I'll test them out later this week when back at the office! A strange thing is that UI performance seem to degrade over time, almost like it's a memory leak or something. Anyhow, it's an Amazon standard AMI, preinstalled with W2016 and SQL Server STD 2016, so it should be fine in that sense... – Fredrik Johansson – 2017-03-14T20:18:51.857

1When the slow-down occurs, try to see if anything is visible on the Resource Monitor or on Task Manager / Processes for the numbers of : Handles, Threads, User Objects, GDI Objects, Page Faults. – harrymc – 2017-03-14T22:17:25.313

Heuristics and FIPS was already disabled. I've configured, and disabled TCP-offloading "Windows Defender". Setup the server to optimize for Programs (I've already configured the UI for the best performance option). Page Fauls on the w3wp process is going through the roof! I'll try to diagnose this right away. – Fredrik Johansson – 2017-03-16T08:33:43.403

Assuming these are hard page faults, it's possible the I/O demand on your disk storage is greater than it can handle. If this occurs for any extended amount of time, the overall responsiveness of your system will definitely suffer. In Resource Monitor on the Disk tab look at the blue line in the graphs. That line shows % Disk Active Time. If it stays at/near 100%, you've found why the system is slow. – I say Reinstate Monica – 2017-03-16T17:43:10.120

Ah, just found out that it's almost only soft page faults. But the number seem quite high anyway - For the w3wp.exe process, the Page faults/sec delta is about 1.000-30.000 (I use Process Hacker to view this value). The total Page faults (service running for about 6-8 hours) is currently 70.000.000 and the total number of Hard faults is 1.300 - So the soft faults would be the difference). Anyhow, I'm not entirely sure how to debug this further, perhaps with dotMemory or something... – Fredrik Johansson – 2017-03-16T18:01:23.677

170M soft page faults is nothing - my mouse driver did 192M since morning and the computer is very responsive. Keep looking. – harrymc – 2017-03-17T16:19:34.553

whaha :) will do! – Fredrik Johansson – 2017-03-17T17:05:35.873

Thank you all for helping out with this; I've tried to divide the bounty between you by contacting SO -- but apparently that can't be done. The final solution to the question was however to increase the IOPS for the system drive, which is a Amazon-EBS disk. Apparently the disk speed was under provisioned. Thing is, on Amazon you have disk-speed-credit system where you have an initial bucket of credits, and accumulate credits when the disk is idle. So therefore the error only occured after the disk had been under pressure - and I never noticed it during e.g. setup. What a week. Thank you! – Fredrik Johansson – 2017-03-20T13:20:56.730

If @harrymc posts an answer, give him the bounty. He initially suggested looking at Resource Monitor and I simply elaborated on this concept by directing your attention to the possibility of disk saturation. – I say Reinstate Monica – 2017-03-21T01:38:01.897

@Twisty: I'm not sure the poster found his answer via the Resource Monitor. – harrymc – 2017-03-21T06:59:41.313

1We found it via CloudWatch - a monitoring tool built in to Amazon EC2 - that show disk usage counters online. Just an other way of viewing the metrics I guess :) – Fredrik Johansson – 2017-03-21T07:45:21.990

Answers

1

Based on your comment:

Page Faults on the w3wp process is going through the roof!

It's possible the I/O demand on your disk storage is greater than it can handle. If this occurs for any extended amount of time, the overall responsiveness of your system will definitely suffer. In Resource Monitor on the Disk tab look at the blue line in the graphs. That line shows % Disk Active Time. If it stays at/near 100%, you've found why the system is slow.

I say Reinstate Monica

Posted 2017-03-10T11:04:20.627

Reputation: 21 477