So I’m working on some guys’ server via RDC (Remote Desktop Connection) from the comfort of my couch and suddenly my wireless connection drops because the neighbor uses his Microwave from hell. After reconnecting I get the dreaded ‘Terminal server has exceeded it’s maximum number of allowed connections’ message. Here’s how to get back in.
[step 1] Click Start->Run and enter:
mstsc -v:<servername> /f -console
Where <servername> is the name or IP address of the machine you’re locked out of.
[step 2] Open the Terminal Services Manager and disconnect at least one of the connections and then reset it. NOTE: This can take a minute, but when it’s done you’re ready to try connecting via RDC again.
To prevent the problem in the future you can also adjusted the Terminal Services Configuration so that disconnected sessions automatically end after a period of time. That way worst case scenario, I’d have to wait a few minutes before connecting via RDC again.