swoft-cloud / swoft

🚀 PHP Microservice Full Coroutine Framework
https://swoft.org
Apache License 2.0
5.58k stars 788 forks source link

restart重启服务命令报端口已被占用,使用shell脚本启动服务读取不到.env配置 #344

Closed jqhph closed 6 years ago

jqhph commented 6 years ago
Q A
Bug report? yes
Feature request? no
Swoft version 1.06
Swoole version 4.03
PHP version 7.1
Runtime environment CentOS 7

Details

php swoft restart重启服务命令报端口已被占用。 另外使用shell脚本启动服务读取不到.env配置

[root@TB-WEB easysale-yxb]# php bin/swoft restart
Swoft bin/swoft is stopping ...
Swoft bin/swoft stop success!
                         Server Information                      
********************************************************************
* HTTP | host: 0.0.0.0, port: 7777, type: 1, worker: 1, mode: 3
* TCP  | host: 127.0.0.1, port: 8099, type: 1, worker: 1 (Enabled)
********************************************************************
[2018-08-14 10:35:22 @18279.0]  WARNING swSocket_bind (ERROR 502): bind(0.0.0.0:7777) failed. Error: Address already in use [98]
failed to listen server port[0.0.0.0:7777]. Error: Address already in use[98].
limingxinleo commented 6 years ago

https://github.com/swoft-cloud/swoft-component/pull/180

limingxinleo commented 6 years ago

你更新一下最新的依赖,应该不会报错了