前段时间停止了Apa che结果在打开的时候发现无法打开 80端口被占用于是win+r运行cmd
输入net stat -ano
可以看到80端口被PID4占用于是打开任务管理器-进程-查看选择列勾选PID
可以看到p id 4的被NT kerne l& System占用
在网上找了很久找到解决方案
-it-impos sible-to-insta ll-apach e-solut ion/comme nt-page-1/#comme nts
原文
翻译如下
该进程是H ttp. sys。它是http API的驱动组件 Http栈服务器。如果该端口被Http.sys占用说明一些正在使用ht tp. sys的应用程序在运行。这就是阻止Apach e运行的原因因为Htt p.sys占用着80端口。我们提供了一种应用程序的机制来帮助控制端口共享但是我需要调查导致你遇到这种困难的是什么特殊应用程序。如果你能提供给我们“netshhttp show servi cestate”这条命令的输出结果我就能找出是哪个应用程序在使用Http. sys。在你禁用H ttp. sys之前请按照下面的步骤来运行命令
1. scconfi ghttp stat = demand
2. reboo t
3. run the comma nd(netsh http show servi cestat)as admin istra tor
在你使用这个命令之前你可以按照下面步骤禁用http.sys
1. net stop http
2. Scconfi g http start=disab led
于是运行net stop http
按y确定
在运行Scconfi g http start=disab led
好了现在启动A pache可以启动了 。
在查看一下netst at -ano
发现pid 4占用了445端口
I work on Http.sys technology atMicrosoft and somebody sent me a l inkto this blog. I ama bitsurprised bythis behavioryou are seeing on Windows7 Beta and with some helpfrom you, I wi l l l ike to find out the root causeof this issue so thatwe can take theappropriate action if needed.
You are right,Http.sys uses port 80. It is the driver component for httpapi , the server httpstack(You can find more info on this technologyathttp://msdn.microsoft.com/en-us/l ibrary/aa364434(VS.85).aspx). In your case,someappl ication is running which is using http.sys to l isten on port80.This is preventingApache from using port80.We offera mechanism for appl ications to help control portsharing but I’ l l need to look into the specific appl ication that’s causing you this conflict. Ifyou can give us the output of fol lowing command“netsh http showservicestate”, then itwi l l al low me to find outwhich appl ication is using http.sys.Sinceyou have disabledhttp.sys, please fol lowthese steps l isted below before running the command:
1 .scconfig http start=demand
2.Re boot
3.Run the command(netsh http show servicestate)as administrator
After you have run this command,you can disable http.sys as fol lows:
1 . net stop http
2.Scconfig http start=disabled
Please let me knowif you face any issues in the process.
轻云互联成立于2018年的国人商家,广州轻云互联网络科技有限公司旗下品牌,主要从事VPS、虚拟主机等云计算产品业务,适合建站、新手上车的值得选择,香港三网直连(电信CN2GIA联通移动CN2直连);美国圣何塞(回程三网CN2GIA)线路,所有产品均采用KVM虚拟技术架构,高效售后保障,稳定多年,高性能可用,网络优质,为您的业务保驾护航。官方网站:点击进入广州轻云网络科技有限公司活动规则:用户购买任...
美国高防服务器提速啦专业提供美国高防服务器,美国高防服务器租用,美国抗攻击服务器,高防御美国服务器租用等。我们的海外高防服务器带给您坚不可摧的DDoS防护,保障您的业务不受攻击影响。HostEase美国高防服务器位于加州和洛杉矶数据中心,均为国内访问速度最快最稳定的美国抗攻击机房,带给您快速的访问体验。我们的高防服务器配有最高层级的DDoS防护系统,每款抗攻击服务器均拥有免费DDoS防护额度,让您...
7月4日是美国独立日,大致就是国庆节的意思吧。hostodo今年提前搞了个VPS大促销活动,4款便宜VPS,相当于7折,续费不涨价,本次促销不定时,不知道有多少货,卖完为止。VPS基于KVM虚拟,NVMe阵列,1Gbps带宽,自带一个IPv4+/64 IPv6,solusvm管理,送收费版DirectAdmin授权,VPS在用就有效! 官方网站:https://www.hostodo.com ...