ERROR The terminal server has exceeded the maximum number of allowed connections
June 7, 2007 — Philip Churchill
When a user establishes a Remote Desktop connection to the WHS this connection will remain active until the user selects “Log Off” from the Start Menu. If a user simply closes the remote desktop window when they’re finished, that username will still remain logged on.
The software running on the WHS to facilitate the Remote Desktop connection will only allow for up to two simultaneous sessions. Active and disconnected sessions are calculated in this connection limit as is the Administrator account also. The console session, however, does not count against the connection limit.
If a third attempt is made to login to the server, the dreaded “The terminal server has exceeded the maximum number of allowed connections” error will be shown to the user, and they will be unable to complete the login process. You can’t even connect to disconnect the old sessions BUT there is a way around this:
Simply click OK to the error message and wait for unto 30 seconds for the window to close then simply type the following in a Start - RUN or CMD Prompt on your client machine.
mstsc /v:00.00.00.00 /f -console
Replace 00.00.00.00 with your server’s IP Address or server name. e.g.SERVER
Type in your administrator password. This will then connect you to the Console Session on the server and allow you to remote control the machine again.
Once in Click Start, point to All Programs, point to Administrative Tools, and then click Terminal Services Manager.
In the left hand column you should see your server name. Click on it once. Note the Users Tab in the right pane.
You should see a list of users. You need to reset the two “Disconnected” users. You can do this by right clicking the disconnected user and selecting “Reset.” You should now be able to connect with RDP again after Start - Log Off.
When logging in under this special Console session always kill the inactive sessions first, because if you get disconnected again you will have to connect your monitor, keyboard and mouse.
Only use this session to terminate the other two sessions and not for any other use.
In future when you are done with a Remote Desktop session on WHS, you should always use “Log Off” rather than disconnecting by closing the RD window with the X as this will disconnect from the session but leave it active.

P.S. You could also use the easy option and just reboot the Windows Home Server.




















August 10, 2007 at 11:24 pm
Is it possible to increase the number of allowed connections to a higher number, e.g. 5 to decrease the liklihood that you would have to perform this reset proceedure?
August 11, 2007 at 10:46 am
Hi markvader,
Unfortunately it is not possible to increase the number of allowed connections to a higher number. I am afraid with are stuck with 2 only.
September 5, 2007 at 7:38 am
Brilliant! It works!
September 5, 2007 at 9:51 am
Hi Mike Oesch,
Glad I could be of service.
September 19, 2007 at 9:12 am
Thanks a lot. You saved my life.
September 19, 2007 at 10:40 am
Hi Waqas Murtaza Butt,
I’m glad I could help you.
October 17, 2007 at 3:26 am
Hi Philip,
Nice work. Got a related query if you can help. If a user receives the “exceeded the maximum number of allowed connections” message, does it get logged to any event log?
It’s not really a login failure, so I can’t seem to find it in security logs. Am I looking in the wrong place?
October 18, 2007 at 8:59 am
Hi Jeff,
The only places I could find on the server that has logged info is in Event Viewer, Security items and in Terminal Services Manager, This Computer branch, “your server name”, and on the right hand side the Sessions tab.
October 19, 2007 at 9:16 am
This info is very helpful! Especially in a multi windows server environment like our office and the sys administrator is always missing in action hahahaha, Thanks a lot!
October 19, 2007 at 10:01 am
Hi ian nix,
Glad we could be of service. Sys administrator, who are they lol.
November 30, 2007 at 7:34 am
Thanks for the great info it works fine
thanks a lot one more time thanks MR.Philip Churchill
November 30, 2007 at 9:19 am
Hi bharathy,
Glad we could help.
December 13, 2007 at 10:06 pm
you are the man, this saved me
December 16, 2007 at 5:12 pm
Hi Ed,
Glad we could help.
January 16, 2008 at 2:43 am
really just want to say big thank you. you save my time of traveling to office from home just to physically logging the server to kill those inactive user before I can logging from home again. Thanks again.
January 25, 2008 at 2:38 am
Add me to the list…
ditto ditto ditto
Thank You for posting this for all of us…
March 21, 2008 at 2:02 pm
Bingo.. this is exactly what I needed.. Very well written.. thanks Philip..
March 24, 2008 at 3:41 am
Thanks man.
Help me to resolve the 2 connection limits and find out who is hogging the connection~!
March 25, 2008 at 1:04 am
Thanks a ton! This was awesome.
April 16, 2008 at 5:43 pm
Nice! And as an added bonus, I got to make it look like I knew something the boss didn’t.
April 26, 2008 at 9:16 pm
Thanks Philip. Big help!
April 29, 2008 at 12:02 pm
This is some useful info, as the users have a habit of simply closing the connection as opposed to logging off.
Wish the number could be increased though.
Thx alot.
May 7, 2008 at 1:16 pm
Good tip! Before I knew this I used the free service of http://www.logmein.com to log in as administrator to log off the inactive users.
May 16, 2008 at 6:54 am
Please Philip Churchill
maybe there is a way to increase the connections more than 2?
because there is a teb (unlimited connections)
can you help me
Haider
May 23, 2008 at 7:27 pm
The way remote desktop for administration works in terminal services is that you are allowed: 1 console session for admin purposes and 2 rd sessions for users. The only way to increase this number is to install terminal server and add some cals to the server. Once you install terminal server and switch to remote desktop for apps instead of administration, you will be given a grace period, something like 90 or 180 days, before having to setup the licensing. Hoever, this is only meant for giving you time to set this up, it isn’t intended soley as a free grace period.
June 3, 2008 at 6:53 am
[...] your server??s IP … point to Administrative Tools, and then click Terminal Services Manager. …http://mswhs.com/2007/06/07/error-the-terminal-server-has-exceeded-the-maximum-number-of-allowed-con…Lost &amp FoundMstsc. Updated: September 28, 2007 … that were created with Client Connection [...]
June 3, 2008 at 10:34 pm
[...] maximum number of allowed connections נכנס ל start/ Run ונזין את הפקודה הבאה: mstsc /v:00.00.00.00 /f -console כשבמקום האפסים נכניס את כתובת ה- IP הגדרת (remote desktop) [...]
June 5, 2008 at 9:03 am
Hi Philip,
i did, as you have explained, but still got the same error message of - the terminal server has exceeded the maximum number of allowed connections. any solution for the same. Thanks.
June 6, 2008 at 8:23 pm
This doesn’t seem to work on a Windows 2000 server. Any ideas (other then upgrading of course).