如果有些许不同,从源代码构建并不容易,我在一些目录和配置选项上遇到了困难。我在网上四处寻找,直到我找到这个从中文翻译过来的网站。没有其他人有解决方案。直到我更改目录(项目 2.ERROR: Unable to globalize),我才能启动 php fpm。我列出了其他问题,但我能够解决它们。请不要删除此内容,这是非常有用的信息。
原始站点(它是中文的,不是我的站点,但我想表示感谢)
(那里还有更多内容,您可以访问该站点)
blog.dream1987.top/?paged=2
安装问题
1. configure: error:. Xml2-config not found 请检查您的 libxml2 安装。
解决方案
apt-get install libxml2-dev
2.Warning: Declaration of PEAR_Installer :: download () should be compatible with & PEAR_Downloader :: download ($ params) in phar: ///root/php-7.0.0alpha1/pear/install-pear-nozlib.phar/PEAR /Installer.php on line 43
Warning: Declaration of PEAR_PackageFile_Parser_v2 :: parse () should be compatible with PEAR_XMLParser :: parse ($ data) in phar: ///root/php-7.0.0alpha1/pear/install-pear-nozlib.phar/PEAR/PackageFile/ Parser / v2.php on line 113
[PEAR] Archive_Tar - already installed: 1.3.13
[PEAR] Console_Getopt - already installed: 1.3.1
[PEAR] Structures_Graph- already installed: 1.0.4
Warning: Declaration of PEAR_Task_Replace :: init () should be compatible with PEAR_Task_Common :: init ($ xml, $ fileAttributes, $ lastVersion) in phar: ///root/php-7.0.0alpha1/pear/install-pear-nozlib. phar / PEAR / Task / Replace.php on line 31
[PEAR] XML_Util - already installed: 1.2.3
Warning: Declaration of PEAR_Task_Windowseol :: init () should be compatible with PEAR_Task_Common :: init ($ xml, $ fileAttributes, $ lastVersion) in phar: ///root/php-7.0.0alpha1/pear/install-pear-nozlib. phar / PEAR / Task / Windowseol.php on line 76
Warning: Declaration of PEAR_Task_Unixeol :: init () should be compatible with PEAR_Task_Common :: init ($ xml, $ fileAttributes, $ lastVersion) in phar: ///root/php-7.0.0alpha1/pear/install-pear-nozlib. phar / PEAR / Task / Unixeol.php on line 76
[PEAR] PEAR - already installed: 1.9.5
解决方案
未找到解决方法 (http://pear.php.net/bugs/bug.php?id=20554)
3. 启动 php-fpm
1.ERROR: failed to open configuration file '/usr/local/etc/php-fpm.conf': No such file or directory (2)
ERROR: failed to load configuration file '/usr/local/etc/php-fpm.conf'
ERROR: FPM initialization failed
解决方案
将 php-fpm.conf 文件从源文件复制到该位置。
cp /root/php-7.0.0alpha1/sapi/fpm/php-fpm.conf /usr/local/etc/php-fpm.conf
2.ERROR: Unable to globalize '/usr/local/NONE/etc/php-fpm.d/*.conf' (ret = 2) from /usr/local/etc/php-fpm.conf at line 125.
ERROR: failed to load configuration file '/usr/local/etc/php-fpm.conf'
ERROR: FPM initialization failed
解决方案
编辑 /usr/local/etc/php-fpm.conf 文档引入了 * .conf 部分,更改为正确的路径 include = / usr / local / etc / php-fpm.d / *. Conf
如果没有 /usr/local/etc/php-fpm.d 目录,请创建该目录。
3.WARNING: Nothing matches the include pattern '/usr/local/etc/php-fpm.d/*.conf' from /usr/local/etc/php-fpm.conf at line 125.
ERROR:. No pool defined 至少必须在配置文件中指定一个池部分
ERROR: failed to post process the configuration
ERROR: FPM initialization failed
解决方案
cp www.conf.default www.conf
4.ERROR: [pool www] can not get gid for group 'nobody'
ERROR: FPM initialization failed
解决方案
打开 www.conf 文件,将用户和组用户更改为 nginx 默认设置,通常默认为 www-data。