zoukankan      html  css  js  c++  java
  • The terminal server has exceeded the maximum number of allowed connections

    When a user tries to connect to a machine using Remote Desktop connection, they might come across this error message.

    The terminal server has exceeded the maximum number of allowed connections

    This is because Windows Server only allows two connections through RDP, and you’ve either got two people already logged on to that machine, or you’ve got disconnected sessions that still thinks they are active. If a user simply closes the remote desktop window when they’re finished, that user will still remain logged on, unless there is a time out configured in Terminal Services Configuration as follows

    Terminal Services Configuration

    Terminal Services Configuration

    If the Session time out is not configured, or the logged on users are not available, you wont be able to logon to the machine. To overcome this limitation, follow the steps as below.

    open a command prompt or type in the RUN prompt

    mstsc /v:[00.00.00.00/SERVERNAME] /f -console

    eg: mstsc /v:192.168.1.10 /f -console
    mstsc /v:ADSURF /f -console

    This will connect to the physical console session on the server (also known as “session zero”). You will then be prompted with the login box and provide the administrator details. Then you will be connected to the Console Session on the server. Now you can reset the disconnected user sessions from Terminal Services Manager. Please note that if you get disconnected from this console session, you will have to go physically to the machine.

    More info on mstsc at Technet

    UPDATE:
    If you have Windows Vista with SP1 or Server 2008, use the following syntax:

    mstsc /admin

    If you use the old switch “/console”, it will just ignore that and proceed connecting. In Windows Server 2008, the /console switch doesn’t exist anymore because “session 0″ is a non-interactive session that is reserved for services. Difference between admin and console swtich are here.

    Another workaround:

    You can also query the sessions on the remote machine as an administrator of that machine. Open a command prompt as a domain administrator that the remote machine is set to or map a drive of that remote machine.

    Then in the command prompt, type as below:

    query session /server:servername

    Replace servername with the remote machine name or IP address.

    Now we have the information of all the users/sessions that are active/disconnected on the remote machine. We can now reset one of the session with the following command.

    reset session [ID] /server:servername

    Replace [ID] with the number from the prevoius output and servername with the remote machine name or IP address. This will reset the session and now you can login using Remote Desktop connection.

  • 相关阅读:
    React生命周期及事件详解
    系统重装后常见的环境变量配置
    Java 字符串格式化
    React Native实战系列教程之自定义原生UI组件和VideoView视频播放器开发
    java-json与js-json转化
    RN项目中缩进处理
    React Native 常用学习链接地址
    React-Native 常用组件学习资料链接
    Swift-继承、构造器、类型转换(嵌套)、类扩展、泛型、协议
    CallKit详解(来电提醒+骚扰拦截)
  • 原文地址:https://www.cnblogs.com/zhaobin/p/1971140.html
Copyright © 2011-2022 走看看