Help Center> Elastic Cloud Server> Troubleshooting> Windows ECS Issues> How Do I Troubleshoot an In-Service Port During Tomcat Startup?
Updated on 2023-03-03 GMT+08:00

How Do I Troubleshoot an In-Service Port During Tomcat Startup?

Symptom

The system prompts that the required port is being used when Tomcat is started on a Windows ECS.

This section uses Windows Server 2008 R2 and port 80 as an example describe how to resolve this issue.

Possible Causes

The port 80 required by Tomcat is being used by other programs, viruses, or Trojan horses.

  1. Run the netstat -ano | find "80" command and find that the ID of the process that is using port 80 is 4.

    Change the port number as required.

    Figure 1 Checking the process using port 80
  1. Run the tasklist /svc | find "4" command and find that the process using port 80 is the System process.

    Change the process ID as required.

    Figure 2 System process

Port 80 is used by the System process.

Solutions

Stopping the process that is using port 80 may stop the applications that are running or restart the ECS.

Solution 1:

  1. Run the cmd command as the administrator and enter net stop http.
  2. To stop the process that is using port 80, enter y.
  3. Run the sc config http start= disabled command.

Solution 2:

  1. In the cmd window, run regedit to open the registry editor.
  2. In Registry Editor, choose HKEY_LOCAL_MACHINE > SYSTEM > CurrentControlSet > Services > HTTP and change the value of Start to 0.
  3. Restart the ECS.