0

Port is Already in Use Error when Starting Server

When I try to start the Apache webserver on my machine, I got the following error:

how to fix that?

Apache Web Server Linux Add a comment
mason
asked Dec 07 2020

Answer

0

The reason for this error is that some other application is already using port 80. Only one application can listen to a port at a given time, However, some other applications may also block port 80. One good example is Skype.

  • Find the process blocking port 80 Open the Windows command prompt and type the following command
    netstat -o

This will Output a list of ports, along with the PID (process ID) that has that port open.

  • Open Windows Task Manager. This can be done in the Windows command prompt. Run taskmgr in the command prompt.

C:\Documents and Settings\Administrator>taskmgr

C:\Documents and Settings\Administrator>

  • Open Process Tab and Add PID (Process Identifier) to the columns displayed for the processes
  • Sort the process that is running by clicking on the PID heading. Find the PID that matches the PID using port 80 listed by netstat. The process in the Name column is the application using the port.
  • Now stop and kill the process blocking port 80.

    After that restart the apache service it will work.

Add a comment
linuxhelp
asked Dec 07 2020
Post your Answer