我有一个VPS设置与PHP的FMP和Nginx的(与SSL)。 我已经build立了Tiny Tiny RSS,而且工作得很好。 不过,我最近试图创build自己的云,并立即遇到了障碍。 我访问了索引页面进行初始设置,完全没有样式。 我看着Firefox的控制台,看到几个404错误。 仔细观察,我发现所有通往资产的途径都是错误的。 它没有要求http://mydomain.com/owncloud/some/important/component.js ,而是要求http://mydomain.com/usr/share/nginx/html/owncloud/some/important/component.js 。 这似乎是PHP在处理页面时出错了。 我用Tiny Tiny RSS没有这个问题,所以我认为它跟Owncloud的写法有关。 我假设有一个php.ini键我必须改变。 有任何想法吗? 以下是我的服务器块的内容: listen 443 ssl; ssl_certificate /var/ssl/secret/sauce.key ssl_certificate_key /var/ssl/secret/sauce.key; server_name localhost 127.0.0.1 mydomain.com; root /usr/share/nginx/html; index index.html index.htm index.php; client_max_body_size 1000M; location / { try_files $uri $uri/ @webdav =404; } location ~ \.php$ { include fastcgi_params; fastcgi_index index.php; try_files […]
我注意到,有时从客户的页面完全laggy或没有build立(错误503出现),而其他方面继续运行pipe理界面也仍然在线。 我的提供商告诉我,通过命令“顶部”我可以找出哪个客户是。 我现在也被发现,哪个用户/ WEB现在导致这些问题。 在Apache2的“default-error.log”中,我现在已经find了以下条目: Premature end of script headers: index.php, referer: https://XXX.in/index.php?rulesAgree=1&pa…n=register (104)Connection reset by peer: mod_fcgid: error reading data from FastCGI server, referer: https://XXX.in/index.php?rulesAgree=1&pa…n=register SIGUSR1 received. Doing graceful restart Apache/2.2.16 (Debian) mod_fcgid/2.3.6 mod_ssl/2.2.16 OpenSSL/0.9.8o configured — resuming normal operations mod_fcgid: can't apply process slot for /var/www/fcgi/XXX.in/php5-fcgi-starter, referer: XXX.in/index.php?page=Index 现在我想我自己有时候/ etc / apache2 / […]
我最近在Fedora的nginx + php-fpm安装程序中遇到了一些PHP应用程序的问题。 我本来就是跟Owncloud有这个问题的,创造了一个问题,没有太多的运气 ,但我意识到这是一个全球性的问题。 我今天尝试安装Drupal,并且遇到了与之前相同的问题。 我的nginx服务器块是这样的: server { listen 80; server_name domainname.com; root /var/www/whatever; index index.php; location / { try_files $uri $uri/ =404; #Recommended by Drupal docs for "Clean URLs" error_page 404 = @drupal; } location ~ \.php$ { include fastcgi_params; fastcgi_index index.php; try_files $uri =404; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_pass 127.0.0.1:9000; } #Recommended by […]
upstream django { server unix:///home/ubuntu/web/www.mysite.com/uwsgi-tutorial/mysite/mysite.sock; # for a file socket } server { listen 80; server_name mysite.com www.mysite.com; charset utf-8; client_max_body_size 75M; # adjust to taste #——–PHP PART ———————– location /blog { alias /var/www; try_files $uri =404; index index.php index.html; } location ~ /blog/.+\.php$ { include /etc/nginx/fastcgi_params; fastcgi_pass 127.0.0.1:9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME /var/www/$fastcgi_script_name; } […]
我已经在AWS Elastic Beanstalk上托pipe了我的应用程序。 该应用程序在本地环境和共享主机环境中运行,但在AWS上拒绝login。 相反,它会redirect回主页。 由于这只发生在AWS上,我怀疑EC2实例的configuration,但我不知道是什么原因造成的。 除了接受来自Elastic Beanstalk的默认设置,我已经覆盖了一些php.ini设置: files: "/etc/php.d/project.ini" : mode: "000644" owner: ec2-user group: ec2-user content: | error_reporting = E_ALL & ~E_STRICT & ~E_NOTICE & ~E_WARNING display_errors = On post_max_size = 32M enable_dl = On 什么可能会导致此行为,我可以使用什么来诊断AWS上的问题?
我想得到一些答案或build议,以我的问题。 所以我得到一个简单的错误: 2014/02/16 12:01:43 [error] 7384#0:* 1在读取来自上游的响应头时,stderr中发送的“主脚本未知”,客户端:127.0.0.1,server:localhost,request:“GET / HTTP / 1.1“,上游:”fastcgi:// unix:/var/run/php-fpm.sock:“,主机:”localhost“ 首先,我的nginxconfiguration做得很好(对我来说 – 也就是说它运行良好)。 我唯一的问题是与Linux文件/文件夹的权限。 我无法理解我所处的情况。好的,这里是一些需要的信息: 我的nginx运行良好,configuration了PHP和mysql。 一个用于nginx的用户被命名为“ nginx ” index index.php index.html index.htm (index指令的nginxconfiguration) 这是我的问题: 我有一个树,如: / home / user / 主目录是: 根: 755 根 用户目录是: 用户:用户 700 我在/home/user/index.php中创build了一个名为index.php的文件 。 Nginx说(/var/log/nginx/error.log)我没有权限。 好的,我做了“ usermod -a nginx -G用户 ”,并将“ user ”目录的权限更改为: 750 (所以现在nginx属于用户组,并且可以读取或执行用户目录的内容)。 好吧,这有效,但不是100%的方式。 如果我现在创build一个文件index.html […]
我最近把一个客户端的WordPress网站移到了新的服务器上。 他的旧服务器相当不合时宜。 这是服务器上唯一的网站。 已经过了几个星期,我在php日志中随机获取这些错误。 [notice] child pid 29281 exit signal Segmentation fault (11) 我安装了gdb并附加了父进程,然后在崩溃时执行了BT。 我得到了这个输出 (gdb) backtrace #0 0x00007f0d4208f573 in select () from /lib/x86_64-linux-gnu/libc.so.6 #1 0x00007f0d42587db5 in apr_sleep () from /usr/lib/libapr-1.so.0 #2 0x00007f0d42e65279 in ap_wait_or_timeout () #3 0x00007f0d42e72906 in ap_mpm_run () #4 0x00007f0d42e47832 in main () 不幸的是,我不知道该怎么做,或者是什么意思。 有任何想法吗?
我在LEMP(Ubuntu Linux,Nginx,MySQL,PHP)堆栈中运行了几个WordPress站点。 看看正在运行的进程,我可以看到有两个php5-fpm进程。 这是正常的还是我做了一些事情? 我更习惯于LAMP堆栈,并认为我通常只有一个PHP进程运行。
我已经安装postfixadmin 2.3.6和即时通讯使用squirrelmail休假插件。 Postfixadmin工作正常,我可以添加/编辑/删除电子邮件帐户和假期或转发/别名。 我在squirrelmail插件上遇到了xmlrpc问题。 我已经configuration如下: postfixadmin config.inc.php $CONF['xmlrpc_enabled'] = true; $CONF['vacation'] = 'YES'; $CONF['vacation_control'] ='YES'; $CONF['vacation_control_admin'] = 'YES'; 在postfixadmin squirrelmailconfiguration global $AllowVacation; $AllowVacation = true; 和是的,我有正确的url $CONF['xmlrpc_url'] = 'http://my-domain/xmlrpc.php'; 我使用PHP 5.3已经安装了xmlrpc模块,zendframework1但是当我login到squirrelmail,然后度假我可以把密码,但后来我得到 Failed to login to xmlrpc instance 这是squirrelmail存在的虚拟apache2错误日志 [Sun Mar 09 16:31:47 2014] [error] [client my-ip] PHP 2. get_xmlrpc() /home/squirrelmail/plugins/postfixadmin/postfixadmin_vacation.php:5, referer: https://my-domain/plugins/postfixadmin/postfixadmin_vacation.php [Sun Mar 09 […]
我试图在Fedora 20盒子上用PHP-FPM设置NGINX, 只有当启动php-fpm作为系统服务时,我才得到“File not found / Primary script unknown”错误。 我在默认的fastcgi.conf中使用了NGINX的默认设置。 (使用: fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; ) 这里是相关的nginx.conf: root /var/www/index; index index.html index.php index.htm; location ~ \.php$ { try_files $uri = 404; fastcgi_pass unix:/var/run/php5-fpm.sock; fastcgi_index index.php; include fastcgi.conf; } 现在,当我直接从shell(以root身份)启动php-fpm时,一切正常,但是当我使用systemctl start php-fpm.service fpm systemctl start php-fpm.service我得到“文件未find/主脚本未知”错误。 这里是php-fpm.service的定义: [Unit] Description=The PHP FastCGI Process Manager After=syslog.target network.target [Service] Type=notify […]