How to solve the remote connection "the maximum number of connections allowed by the terminal server has been exceeded"

Source: Internet
Author: User
Tags mstsc

1. Find a Windows2003 machine that can be connected to the network

2. Start-run-Enter "tsmmc. msc" to jump out of a remote desktop console.

3. Right-click "Remote Desktop" on the left, select "New Remote Desktop", enter the IP address, user name, password, and domain name of the VM to be connected as required, and then click "OK"

4. Click the new remote desktop to log on to the remote VM.

Tail scanning:

1. log on to the remote virtual host, open "Task Manager", select "user", and kill the two users that are in the system.

2. Start-run-gpedit. MSC-Computer Configuration-management template-Windows Components-Terminal Services-session, select "set time limit for Disconnected Sessions" in the right window, select Enabled, and set a time

W

In2k/win2003 Terminal Server exceeds the maximum number of connections allowed

Manage a server today. After Entering the account and password during the remote connection, click Connect and a "Terminal Server exceeds the maximum allowed connections" will pop up ". I checked it online. It comes down to this:

Causes and solutions.

Cause: When you log on to the terminal server through a Remote Desktop Connection, you may encounter an error such as "the maximum number of connections allowed on the terminal server is exceeded ."

The cause of this problem is that there are two links missing from the terminal service, and if the remote desktop window is closed directly after you log on to the Remote Desktop

In fact, the session is not released, but is retained on the server. This will occupy the total number of connections. When the maximum number is reached, the above prompt will appear.

How to avoid it?

1. log out of the Remote Desktop instead of closing the window directly.

2. Restrict the time For Disconnected Sessions

1. Modify from terminal service configuration

Run-TSCC. MSC (terminal service configuration)-connection-double-click RDP-TCP or right-click-properties-session-select the first replacement user setting (o) -end a disconnected session [set the default value to"

Change from "to" an appropriate time, such as 30 minutes]

2. Modify the slave Group Policy

Start-run-gpedit. MSC-Computer Configuration-management template-Windows Components-Terminal Services-session

In the window on the right, set the time limit for Disconnected Sessions-select Enabled and select a time

3. Increase the maximum number of links

1. Modify from terminal service configuration: Run-TSCC. MSC (terminal service configuration)-connection-double-click RDP-TCP or right-click Properties, select the "Nic" tab-modify "Max connections"

Change to the value you need. Of course, this value cannot be too large, otherwise it will occupy a large amount of system resources. However, the modified value does not seem to work. If it is set to no limit, the current file will still appear.

Description.

2. The group policy level is higher than the terminal service configuration. When the Group Policy is enabled, the corresponding options in the terminal service configuration become gray and unchangeable.

Run-gpedit. MSC-Computer Configuration-management template-Windows Components-Terminal Service

Double-click "Limit connections" on the right, select "enabled", and enter the maximum number of connections allowed.

4. Change the Remote Terminal Mode

Open "Control Panel", double-click "add delete program", click "add Delete Windows component", and "component". In the Windows component wizard dialog box, select "Terminal Service" and"

Next "," Application Server "," Next ", and then follow the prompts to change the terminal service mode.

Windows 2000 Terminal Services have two operating modes: Remote Management Mode and Application Server mode. The remote management mode allows the system administrator to remotely manage the server, and only two

The terminal session is used to log on to the terminal server at the same time. The Application Server mode allows you to run more than one application and allow multiple users to log on to the server from the terminal. However, the application terminal

The service user must have terminal service authorization, that is, the terminal service authorization server must be set in this domain or working group within 90 days. Otherwise, the user must delete the application and re-install the application.

Installation.

5. modify local security policies

Control Panel> Administrative Tools> Local Security Policies> Local Policies> Security Options>

1. First find> Microsoft network server: The Idle Time Required Before the session is suspended

The default value is 15 minutes, which is changed to the time required by the user (that is, the user is automatically disconnected after no action is idle after login)

2. Find> Network Security: log out after the logon time is exceeded. The default value is disabled. Make sure to change to: enabled.

If a solution already exists:

1. First, you can telnet to the host (no matter which method you use). Of course, it is better to operate the machine directly, but you do not need to use the command line for direct operations, of course, machine super

You can use opentelnet to open the telnet port of the remote server.

2. After telnet, check the login user first:

Enter the command: Query user

System return:

C:> query user

Username? Sessionname? ID? State? Idle Time? Logon Time

K12update? Console? 1? Running?

At this time, we can see that the possible differences are different, depending on the specific situation.

Users with ID 0 are locally logged on, and users with ID 1 and ID 12 are 3389 logged on. The former is running, and the latter is disconnected, however, if it is disconnected, it still occupies system resources and channels.

It is kicked out. Perform the following operations.

Enter the command: logoff 1

3. If the Telnet function is disabled on the server (this is the default one), you can also extend the stored procedure through SQL Server's xp_mongoshell in the format of master. DBO. xp_mongoshell'

Command content '. For more information, see Step 2. This method requires the permission to access xp_mongoshell.

The above solution is basically useless. When I used the Server Terminal Server to exceed the maximum number of allowed connections, I used to consider using a cold start server. But in this case, I had to go to the IDC.

The best way is to enter mstsc/console/V: Your Server IP Address: Remote port in the "run" command line.

"Scenario description 』
1. When you log on to the remote Windows server, the error "the maximum number of allowed connections is exceeded on the terminal server" occurs. As a result, the administrator cannot log on to the server for remote management.
2. servers are centrally managed in the company's information center without external monitors. Therefore, it is best to remotely manage and solve the problem.

---- ==== Very attractive split line ===------- =================------ very attractive split line ------ ======= ------

"Solution Process 』
1. The first thing that comes to mind is the search engine. Google's results are as follows:

The following content is from the Internet and copyright belongs to the original author.

A similar problem occurs because Remote Desktop for administrator is set to two connections by default. If Remote Desktop is disabled without logout after remote logon, the session is still on the server, therefore, the above prompt is easily displayed when you connect again. If you use terminal to log on, log on to the console and the remote logon user is automatically logged out. Solution 1: Use logout to disable remote desktop, limit the time of Disconnected Sessions, and increase the number of connections.

The last two methods can be modified in two ways. For detailed steps, refer to the following information:

Method 1. Modify the Terminal Services Configuration
1. Click Start \ Control Panel \ Administrative Tools \ Terminal Services Configuration
2. Select connections on the left and double-click RDP-TCP on the right to open the attribute Setting dialog box.
3. select the sessions tab, select the first override user settings, and modify the end a disconnected session time, for example, 30 minutes. In this way, if the connection is not reconnected within 30 minutes after the connection is disconnected, the system automatically ends the session.
4. Select the network adapter and modify maximum connections. The default value is 2. Change it to the number you want, but it should not be too large. Otherwise, the system resources will be too large.

Method 2. Modify Group Policy
1. Click Start \ Run \ gpedit. MSC
2. Computer Configuration \ Administrative Templates \ Windows Components \ Terminal Services
3. Double-click limit number of connections. In the displayed dialog box, select Enabled and add the maximum number of connections to ts maximum connections allowed.
4. Terminal Services \ sessions on the left
5. Double-click set time limit for Disconnected Sessions, select Enabled, and select time in end a disconnected session

2. The above settings are correct, but now I cannot remotely log on to the remote system or directly log on to the server. Therefore, none of the above operations can be performed. Bytes

3. Continue searching and finally find the solution, which is described as follows:

---- ==== Very attractive split line ===------- =================------ very attractive split line ------ ======= ------

"Solution 』

Use the following command to solve the problem of exceeding the maximum number of connections:
Run mstsc/V: IP/console, such

Mstsc/V: 211.211.0.5/console

You can connect to a remote system session.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.