Nginx无法启动 -10013: An attempt was made to access a socket in a way forbidden by its access permission

Nginx无法启动

使用nginx -t 发成Nginx无法启动;

错误提示:10013: An attempt was made to access a socket in a way forbidden by its access permissions

错误原因: Nginx conf 文件里面的端口被占用

解决方法:
使用端口查找命令一个个找端口,确定被占用的端口

Nginx无法启动 -10013: An attempt was made to access a socket in a way forbidden by its access permission_第1张图片netstat 命令行检查 netstat -aon |findstr “3817”,一旦确认被占用,可以采用,更换端口的方式。然后继续执行
nginx -t 来检查nginx配置没有问题

最后重启一下nginx就解决问题了。


查找端口

netstat -aon |findstr “:端口号”

你可能感兴趣的:(nginx,运维,服务器)