
php
7*24 工作者
人有万算,不如老天一算。做人,就要坦坦荡荡;做事,就要问心无愧。
展开
-
Package ‘oniguruma‘, required by ‘virtual:world‘, not found
php8.x版本编译的时候报 Package 'oniguruma', required by 'virtual:world', not found 错误原创 2023-02-17 10:26:28 · 2664 阅读 · 1 评论 -
linux服务器上yum安装指定版本php
在很多情况下安装php是,如果通过yum安装,会导致安装的php版本比较低,如果在开发的时候用的是高版本的php,这个时候我们在服务器上安装php必须使用源码编译安装,如果在编译的时候报错了,可能需要很长的时间排错,然后重新编译安装,这样花费的时间比较长。使用yum安装指定版本的php1、下载对应的仓库## centos7 版本yum install -y https://mirrors.tuna.tsinghua.edu.cn/remi/enterprise/remi-release-7.rpm原创 2021-07-15 14:34:48 · 1690 阅读 · 6 评论 -
Encountered end of file
HTTPS无法打开:curl: (35) Encountered end of file 和 linux上安装composer$ curl -sS https://getcomposer.org/installer | phpcurl: (35) Encountered end of file原因:服务器443端口未对外开放,需要在防火墙规则中将443端口打开安装comp...翻译 2018-04-05 14:33:15 · 11137 阅读 · 0 评论 -
编译php可能遇到的问题和解决方法
在编译php7.1.13的时候,出现了一些问题,编译参数如下:[root@linux-node1 php-7.1.13]# ./configure --prefix=/usr/local/php \--disable-debug \--disable-phpdbg \--enable-mysqlnd \--enable-bcmath \--with-bz2=/usr \--en原创 2018-01-25 15:13:26 · 809 阅读 · 0 评论 -
curl error: Problem with the SSL CA cert (path access rights?) 的解决方法
这里显示的是CA问题: 首先,颁发server证书的CA是没有问题的,那么应该是curl使用的ca-bandle.crt 有问题,这很可能意味着您已经删除了/etc/pki/tls/certs/ 目录下的某些文件或设置了无效的权限。$ yum reinstall openssl ca-certificates -y$ ll /etc/pki/tls/certs/ca-bundle.crt原创 2018-01-19 16:02:23 · 13925 阅读 · 0 评论 -
Liunx PHP的GD库 添加png/jpeg image的支持
编译jpeg的模块,这个需要从官网下载[root@linux-node1 ~]# wget http://www.ijg.org/files/jpegsrc.v8b.tar.gz[root@linux-node1 ~]# tar -xf jpegsrc.v8b.tar.gz[root@linux-node1 ~]# cd jpeg-8b[root@linux-node1 jpeg-8b]#原创 2017-10-26 10:41:09 · 4665 阅读 · 0 评论 -
make: *** [sapi/cli/php] Error 1
操作系统版本:[root@linux-node1 ~]# uname -r2.6.32-504.el6.x86_64编译php的时候,make报错如下:ext/iconv/.libs/iconv.o: In function `php_iconv_stream_filter_ctor':/ext/iconv/iconv.c:2491: undefined reference to `libico原创 2017-10-26 09:54:52 · 8592 阅读 · 1 评论 -
make: *** [ssh2.lo] Error 1
在编译php模块时候,我们可能会在./configure没有报错,而make的时候出现这样的问题make: *** [ssh2.lo] Error 1这个原因一般是版本问题,需要我们将源码的版本换成稳定版本即可。原创 2017-08-07 09:25:29 · 2453 阅读 · 0 评论 -
php-fpm报502问题
搭建lnmp完lnmp环境后,测试时出现502报错,看到这个问题,我立刻想到是php-fpm没有起来,但是我用 ps -ef | grep php-fpm 截取 php-fpm 的进程,发现是有的,这时我有查看nginx的错误日志,发现错误信息是:2017/05/05 17:08:45 [crit] 3258#0: *2 connect() to unix:/tmp/php-cgi.sock fa原创 2017-05-05 10:02:31 · 14605 阅读 · 1 评论 -
thinkphp 在lnmp环境下的url重写配置
之前nginx的配置文件:user www www;worker_processes auto;error_log /home/wwwlogs/nginx_error.log crit;pid /usr/local/nginx/logs/nginx.pid;原创 2017-05-03 14:42:03 · 864 阅读 · 0 评论 -
thinkphp框架的路径问题
问题回顾: 将环境迁移后,首页可以访问,但是后面的url链接都出现问题,只要一点击就出现,无法加载模块 第一时间想到的是url的跳转问题,于是检查nginx的配置文件,但是我们这边是一级域名,这样跳转是没有问题的location / { if (!-e $request_filename) { rewrite ^/(.*)$ /index.php/$1 last;原创 2017-05-03 11:58:09 · 4604 阅读 · 0 评论 -
PHP无法启动502故障
一次打开网站,发现502,第一反应肯定是php-fpm没启动,尝试启动还是502.1.首先查询Nginx日志发现如下连接PHP失败:2017/03/02 15:56:04 [error] 23760#0: *186 connect() failed (111: Connection refused) while connecting to upstream, client: 10.8.原创 2017-04-11 10:53:02 · 3609 阅读 · 0 评论 -
php-fpm的启动脚本
#! /bin/sh### BEGIN INIT INFO# Provides: php-fpm# Required-Start: $remote_fs $network# Required-Stop: $remote_fs $network# Default-Start: 2 3 4 5# Default-Stop:原创 2017-03-29 16:45:06 · 948 阅读 · 0 评论 -
php优化
一、模块操作码缓存的优化模块 前提:yum -y install perl-devel 缓存模块(性能优化插件)二选一eaccelerator、xcache mencache客户端模块(功能性插件)memcache 和数据库连接模块(功能性插件)PDO_MYSQL扩展模块 1、编译eaccelerator/usr/local/php/bi原创 2017-03-29 15:23:55 · 821 阅读 · 0 评论