linux centos7.6 下安装 php7.2.18

 1  ifconfig

    2  ip addr show

    3  service

    4  cd /etc/sysconfig/network-scripts/

 

    8  vim ifcfg-ens33 

    9  vi ifcfg-ens33 

   10  service network restart

   11  ifconfig

   12  ip addr show

   13  systemctl stop firewalld

   14  systemctl diable firewalld

   15  systemctl disable firewalld

   16  firewall-cmd --state

   17  ping www.baidu.com

   18  ls

   19  vi ifcfg-ens33 

   20  service network restart

   21  ping www.baidu.com

   22  ip addr show

   23  cd /etc/sysconfig/network-scripts/ifcfg-ens33 

   24  cd /etc/sysconfig/network-scripts/

   25  ls

   26  vi ifcfg-ens33 

   27  systemctl restart network.service

   28  ping www.baidu.com

   29  vi ifcfg-ens33 

   30  uname -a

   31  lsb_release -a

   32  find docker

   33  find dock

   34  where dock

   35  history

   36  php -m

 

   43  mkdir Down

 

   47  ping www.baidu.com

   48  scp root@192.168.1.129:/Down/php-7.2.18.tar.xz ./Down

   49  ls

   50  cd Down 

   51  scp root@192.168.1.129:/Down/php-7.2.18.tar.xz ./

 

   55  tar -xvf php-7.2.18.tar.xz 

   56  ls

   57  cd php-7.2.18

 

   59  yum -y install libxml2 libxml2-devel

 

   61  yum install -y openssl openssl-devel

   62  gcc -v

   64  yum install -y jpeglib jpeglib-devel

   65  yum -y install libjpeg-devel

   67  yum -y install libpng-devel

   69  yum -y install libxslt-devvel

   70  yum -y install libxslt-devel

 

   72  yum -y install libzip-devel

   74  cd ..

   75  yum remove -y libzip

   76  wget https://nih.at/libzip/libzip-1.2.0.tar.gz

   77  yum install wget

   78  wget https://nih.at/libzip/libzip-1.2.0.tar.gz

   79  ls

   80  tar -xvf libzip-1.2.0.tar.gz 

   81  ls

   82  cd libzip-1.2.0

   83  ls

   84  ./configure

   85  make

   86  make install

 

   89  cd php-7.2.18

   90  ls

 

   94  vim /etc/ld.so.conf

添加如下几行

/usr/local/lib64

/usr/local/lib

/usr/lib

/usr/lib64 

#保存退出

:wq

ldconfig -v # 使之生效

 

   95  ldconfig -v

   96  ./configure --enable-fpm --prefix="/alidata/server/php7.2.18" --with-config-file-path="/alidata/server/php7.2.18/etc" --with-gd --with-gettext --with-iconv-dir --with-kerberos --with-libdir=lib64 --with-libxml-dir --with-mysqli --with-openssl --with-pcre-regex --with-pdo-mysql --with-pdo-sqlite --with-pear --with-png-dir --with-jpeg-dir --with-xmlrpc --with-xsl --enable-zip --with-zlib-dir=DIR --with-pcre-dir --with-libzip=DIR --with-openssl --enable-fpm --enable-bcmath --enable-libxml --enable-inline-optimization --enable-mbregex --enable-mbstring --enable-opcache --enable-pcntl --enable-shmop --enable-soap --enable-sockets --enable-sysvsem --enable-xml --enable-zip

   97  make

   98  cp /usr/local/lib/libzip/include/zipconf.h /usr/local/include/zipconf.h

   99  make clean

  100  make

  101  make test

  102  make install

  103  cp php.ini-development /alidata/server/php7.2.18/etc/php.ini

  104  cp php.ini-development /alidata/server/php7.2.18/bin/php.ini

  105  cd /alidata/server/php7.2.18/

  106  ls

  107  cd etc

  108  ls

  109  cp php-fpm.conf.default php-fpm.conf

  110  cd php-fpm.d/

  111  cp www.conf.default www.conf

  112  service php-fpm start

  113  systemctl php-fpm start

 

  117  cd /alidata/server/

 

  127  ./php -v

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值