我刚刚开始使用MacOS Sierra v10.12.1中的nginx。
在安装了之后,浏览器拒绝连接,并显示以下消息:This site can’t be reached. localhost refused to connect.
我刚刚试着用nginx -t调试我的nginx,它显示缺少nginx.pid:
nginx: the configuration file /usr/local/etc/nginx/nginx.conf syntax is ok
nginx: [emerg] open() "/usr/local/var/run/nginx.pid" failed
我有这样一个.file,并希望将其转换为JSON格式。
2022/01/22 21:27:56 [notice] 40#40: signal process started
2022/01/22 21:27:56 [error] 40#40: open() "/run/nginx.pid" failed (2: No such file or directory)
2022/01/22 21:28:04 [notice] 42#42: signal process started
2022/01/22 21:28:04 [error] 42#42: open() "/r
你好,我有一个安装了nginx流的服务器,我确实停止了nginx,然后重新加载了它,但它显示了下面的错误,并且没有启动:
nginx -s stop
nginx: [error] open() "/usr/local/var/run/nginx.pid" failed (2: No such file or directory)
我做了下面的命令,但什么也没做:
sudo nginx
nginx: [emerg] open() "/usr/local/var/run/nginx.pid" failed (2: No such file or dir
使用Salt我应用了安装和运行NGINX (1.14.0-0ubuntu1.7)作为服务的状态。服务的状态是活动的,但systemctl reload nginx一直失败,因此无法应用更新的配置。
完整日志:
systemd[1]: nginx.service: Can't open PID file /run/nginx.pid (yet?) after reload: No such file or directory
systemd[1]: Reloaded A high performance web server and a reverse proxy server.
sys
我有配置错误,我已经在网上搜索过了,但我不太确定问题是什么。我想在os x 10.7.5操作系统上安装PHP和Nginx。每当我尝试启动或停止服务器时,我都会得到以下错误:
tone$ nginx
nginx: [warn] 1024 worker_connections exceed open file resource limit: 256
alcfwl128:~ tolbert$ nginx: [emerg] open() "/usr/local/Cellar/nginx/1.4.3/logs/nginx.pid" failed (2: No such file or d
我正在运行LinuxMint19.2 Tina,它应该相当于Ubuntu18.04。
当我发出sudo systemctl stop nginx.service命令时,systemctl start nginx.service经常会出错
Job for nginx.service failed because the control process exited with error code.
See "systemctl status nginx.service" and "journalctl -xe" for details.
和
nginx: [err
为什么我得到了的这一页,这个站点无法到达,但我的终端上似乎没有错误?
当我通过IP地址访问服务器时,很好:
但是使用域名,我得到了以下内容:
$ sudo systemctl status nginx
● nginx.service - A high performance web server and a reverse proxy server
Loaded: loaded (/usr/lib/systemd/system/nginx.service; enabled; vendor preset: disabled)
Active: active (run
我在服务器上运行一个Symfony网站,使用配置了Let's Encrypt的Nginx。当我启动服务器(总是使用sudo service nginx start / restart)时,一切都很顺利。
但每三个月,我注意到网站已经关闭。当我检查日志时,总是一样的:
2018/12/23 00:23:53 [notice] 22167#22167: signal process started
2018/12/23 00:23:53 [error] 22167#22167: open() "/run/nginx.pid" failed (2: No such file
目前,我已经用nginx设置了一个nextcloud服务器,并使用sudo systemctl enable nginx.service启用了它。当我重新启动时,我会收到一条错误消息,它抱怨代理服务器,如果我查看一下sudo systemctl status nginx.service,就会得到以下信息:
nginx.service - A high performance web server and a reverse proxy server
Loaded: loaded (/etc/systemd/system/nginx.service; enabled; vendor p
我已经从linuxserver/letsencrypt,构建并运行了一个对接映像,我在/config/nginx/site-confs/default中使用了自己的nginx配置,它与我的nginx配置一起正常工作。
现在我想看到nginx日志,但是/var/logs/nginx/access.log是空的,/var/log/nginx/error.log只包含以下一行:
[emerg] 479#479: open() "/run/nginx/nginx.pid" failed (2: No such file or directory)
我不知道这个错误是否导致了什么原因,因
我不知道出了什么问题,但是突然我的nginx本地主机服务器在我所有的本地主机站点上给了我404错误。
通过运行nginx -t,我得到了这个
nginx -t
nginx: [alert] could not open error log file: open() "/var/log/nginx/error.log" failed (13: Permission denied)
2017/02/07 22:53:36 [warn] 9580#0: the "user" directive makes sense only if the master proce
我正在尝试重新安装nginx,但我有这个
nginx -t
nginx: [alert] could not open error log file: open()
"/var/log/nginx/error.log" failed (2: No such file or directory)
2015/01/25 16:18:01 [emerg] 1400#0: open() "/etc/nginx/nginx.conf"
failed (2: No such file or directory)
nginx: configuration fi
我一直在尝试建立一个本地的码头容器来承载NGINX服务器。首先,这里是我的Dockerfile:
# Set nginx base image
FROM nginx
# File Author / Maintainer
MAINTAINER myuser "myemail@mydomain.com"
# Copy custom configuration file from the current directory
COPY nginx.conf /etc/nginx/nginx.conf
我确实使用docker命令构建了这个文件,当我列出这些图像时,我可以在列表中看到这
我已经购买了谷歌爸爸vps服务器,在上面我想安装nginx,laravel和php。
我尝试安装nginx时遇到问题:
nginx: [alert] could not open error log file: open() "/var/log/nginx/error.log" failed (2: No such file or directory)
1. List item
2017/11/21 03:52:00 [emerg] 23590#0: open() "/etc/nginx/nginx.conf" failed (2: No such fil
我完成了我的第一个nginx服务器的设置,我在nginx t命令中注意到以下错误。 错误消息: nginx: [alert] could not open error log file: open() "/var/log/nginx/error.log" failed (13: Permission denied)
2020/12/12 19:25:26 [warn] 1498#1498: the "user" directive makes sense only if the master process runs with super-user privi
我有一个django应用程序,主页路由正确,但当我尝试点击任何链接时,我得到一个404错误。我查看了日志,发现:
*1 open() "/usr/share/nginx/html/pricing" failed (2: No such file or directory)
这告诉我,nginx没有查看我的项目文件夹,而是看起来是默认设置。我使用centos,所以我必须手动设置站点-可用和启用站点,我已经使用这些站点来使主页正常工作。因此,没有要禁用的默认配置。我不确定如何让nginx路由到我的路径,而不是默认路径。我的nginx.conf文件如下所示:
user so_dev;
我正在尝试在我的容器中安装nginx (然后是nodejs)。我在nginx/文件夹中有自己的nginx配置文件:
# --- Release with Alpine ----
FROM phusion/baseimage:0.10.1
# Create app directory
WORKDIR /app
RUN apt-get update \
&& apt-get -y install nginx
RUN ls /etc/nginx
COPY nginx/nginx.conf /etc/nginx/nginx.conf
RUN ls /etc/nginx
我试图在一个非常精简的linux上运行nginx,当我尝试运行它时,我得到了
[emerg] 4905#0: open() "/etc/nginx/nginx.conf" failed (2: No such file or directory)
和
[alert] could not open error log file: open() "/var/log/nginx/error.log" failed (2: No such file or directory)
现在,我的问题是/etc位于只读文件系统上,所以我无法创建该目录,也不能将其符号链接到它。所有
我的nginx从/usr/sbin/nginx -c /etc/nginx/nginx.conf命令行开始很好,但是当我尝试以以下方式启动它时:
# systemctl start nginx
然后挂起直到超时。
我的系统单元如下所示:
[Unit]
Description=A high performance web server and a reverse proxy server
Documentation=man:nginx(8)
After=network.target
[Service]
Type=forking
PIDFile=/var/run/nginx/nginx.pid
我在一个共享主机上,有权继承nginx根安装并重写它的配置文件(注意:我不想在我的主目录中编译我自己的nginx )。
我编写了一个开始/重新加载/停止脚本,这个脚本工作得很好,但是我一直在下面看到错误
启动脚本
#!/bin/bash
# Set this to your nginx configuration file and PID
CONFIG=~/nginx/nginx.conf
PIDFILE=~/nginx/nginx.pid
# Do not change anything below unless you know what you do
DAEMON=/usr/l