What to do if 80 ports are occupied when publishing a Web site

Source: Internet
Author: User

There were few problems when publishing Web sites on IIS, because the ports are configured on their own, but recently encountered such a problem, less nonsense, see Pictures:


After the launch of the site, can not start, when the error, prompting the process can not access. Find out why the port is occupied.

We used to publish the site, we will set a port, and this port is different from other ports, will not repeat, so never encountered this problem. Now what is the case, the port of the program has been set up, is the Port , we can not reconfigure the port, can only be done by the original program published as a website. This caused the port conflict, two programs using the port at the same time , the site although published, but can not start, start will report the above image error.

The root of the problem has been found, we solve the problem of the idea has come out, since the program has been released, can not be modified, then we can only modify another occupied Port of the program (so called). The first step is to find the program, the second step to kill the program or to modify its port.

Direct solution: The first step -- find The process using the port (Windows7 for example)

windows + R Open Run, enter CMD Open a command prompt, enter :

Netstat-aon|findstr "80"

then enter the key to show the following results:


It turns out that the process with ID 1780 occupies a Port, and then we'll see what this process is all about. Continue typing in the command Prompt window:

Tasklist|findstr "1780"

The following results are displayed:


The original is the httpd program occupies a Port, the program is what exactly? Baidu a bit, did not read. Then you can kill the process or change the port, I first tried to kill the process, the method is as follows: Plan one

Method 1 type directly in the command Prompt window:tskill 1772, and then restart IIS.

         Method2 Ctrl + ALT + DELKey, open Task Explorer, click View, select Columns, and tick thePID (Process Identifiers)item, and then query in the windowPIDto be1772process, then end the process and then restartIIScan be.

This method is not very good, because sometimes you will be prompted to find This process, and, after the shutdown, will not be saved, the boot again to kill the process, so it is not recommended to use this method, we use Scenario two Modify the port of this process.

          follow this process (for example, Windows7), open: Computer---CDisk--windows--apache-conffolder, and then you'll seehttpd.conffile, open it with a text editor, and then look for:Listen    , this is the port of the program, modify the port to any value, such as directly behind the addBayiinsteadListen 8081, then save, restartIIScan be.



If you still can't solve this problem, restart your computer.


What to do if 80 ports are occupied when publishing a Web site

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.