查看: 243|回复: 11

nginx怎么就启动不了呢,

[复制链接]

552

主题

4154

回帖

1万

积分

论坛元老

积分
10096
发表于 2018-2-2 11:46:54 | 显示全部楼层 |阅读模式
CentOS 6 x86系统
应该是apache2的锅,可就关不掉


[root@dd ~]# service httpd stop
Stopping httpd:                                            [  OK  ]
[root@dd ~]# sudo service nginx start
Starting nginx: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] still could not bind()
                                                           [FAILED]
[root@dd ~]# netstat -ltunp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address               Foreign Address             State       PID/Program name   
tcp        0      0 0.0.0.0:22                  0.0.0.0:*                   LISTEN      1068/sshd           
tcp        0      0 127.0.0.1:25                0.0.0.0:*                   LISTEN      1277/sendmail      
tcp        0      0 0.0.0.0:80                  0.0.0.0:*                   LISTEN      1468/httpd         
tcp        0      0 :::22                       :::*                        LISTEN      1068/sshd
[root@dd ~]# /etc/init.d/apache2 stop
-bash: /etc/init.d/apache2: No such file or directory
[root@dd ~]# sudo /etc/init.d/apache2 stop
sudo: /etc/init.d/apache2: command not found
回复

使用道具 举报

117

主题

4292

回帖

9101

积分

论坛元老

积分
9101
发表于 2018-2-2 11:47:55 | 显示全部楼层
Address already in use
回复

使用道具 举报

18

主题

211

回帖

550

积分

高级会员

积分
550
发表于 2018-2-2 11:51:00 | 显示全部楼层

坐怀不乱西门庆 发表于 2018-2-2 11:53

[root@dd ~]# kill -9 1468
-bash: kill: (1468) - No such process
[root@dd ~]# sudo service nginx st ...

killall -9 httpd
回复

使用道具 举报

0

主题

1

回帖

4

积分

新手上路

积分
4
发表于 2018-2-2 11:51:00 | 显示全部楼层
错了  编辑掉我猜楼主用的阿里云
回复

使用道具 举报

247

主题

2700

回帖

6277

积分

论坛元老

积分
6277
发表于 2018-2-2 11:51:23 | 显示全部楼层
kill -9 1468
回复

使用道具 举报

552

主题

4154

回帖

1万

积分

论坛元老

积分
10096
 楼主| 发表于 2018-2-2 11:53:00 | 显示全部楼层

分享吧 发表于 2018-2-2 11:51

kill -9 1468

好了,这个id一直在变,杀不掉
回复

使用道具 举报

552

主题

4154

回帖

1万

积分

论坛元老

积分
10096
 楼主| 发表于 2018-2-2 11:53:06 | 显示全部楼层

分享吧 发表于 2018-2-2 11:51

kill -9 1468

[root@dd ~]# kill -9 1468
-bash: kill: (1468) - No such process
[root@dd ~]# sudo service nginx start
Starting nginx: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] still could not bind()
                                                           [FAILED]
[root@dd ~]# netstat -ltunp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address               Foreign Address             State       PID/Program name   
tcp        0      0 0.0.0.0:22                  0.0.0.0:*                   LISTEN      1068/sshd           
tcp        0      0 127.0.0.1:25                0.0.0.0:*                   LISTEN      1277/sendmail      
tcp        0      0 0.0.0.0:80                  0.0.0.0:*                   LISTEN      1830/httpd         
tcp        0      0 :::22                       :::*                        LISTEN      1068/sshd         
回复

使用道具 举报

56

主题

866

回帖

1942

积分

金牌会员

积分
1942
发表于 2018-2-2 11:53:50 | 显示全部楼层
/etc/init.d/apache2 stop 这个不存在的话, 你不是用脚本安装的吧.
回复

使用道具 举报

249

主题

1966

回帖

4817

积分

论坛元老

积分
4817
发表于 2018-2-2 11:56:12 | 显示全部楼层
看错,是不有什么守护进程
回复

使用道具 举报

149

主题

1929

回帖

4433

积分

论坛元老

积分
4433
发表于 2018-2-2 12:12:09 | 显示全部楼层
我以为楼主是那个卖1024码的西门庆
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

关注公众号

相关侵权、举报、投诉及建议等,请发 E-mail:admin@discuz.vip

Powered by Discuz! X5.0 © 2001-2026 Discuz! Team.

在本版发帖
关注公众号
返回顶部