在 Ubuntu/Debian 下安装 PHP7.3 教程
2021-05-31 21:04
标签:res 查看 postgre bz2 XML ted imp 系统 完成 安装软件源拓展工具: 添加 Ond?ej Sury 的 PHP PPA 源,需要按一次回车: 更新软件源缓存: 安装软件源拓展工具: 添加 GPG 添加 sury 软件源 更新软件源缓存: 安装 PHP7.3: 安装完成后,编辑 安装好了先重启一下! 更多操作: 验证一下是否安装成功: 运行下面的命令系统就会更新所有可以更新的软件包括 PHP 上面的一条命令安装 PHP 只是安装了部分 PHP 拓展,更多的软件可见: 在 Ubuntu/Debian 下安装 PHP7.3 教程 标签:res 查看 postgre bz2 XML ted imp 系统 完成 原文地址:https://www.cnblogs.com/surplus/p/14615094.htmlUbuntu
apt -y install software-properties-common apt-transport-https lsb-release ca-certificates
add-apt-repository ppa:ondrej/php
apt update
Debian
apt -y install software-properties-common apt-transport-https lsb-release ca-certificates
wget -O /etc/apt/trusted.gpg.d/php.gpg https://mirror.xtom.com.hk/sury/php/apt.gpg
sh -c ‘echo "deb https://mirror.xtom.com.hk/sury/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list‘
apt-get update
安装软件
apt install php7.3-fpm php7.3-mysql php7.3-curl php7.3-gd php7.3-mbstring php7.3-xml php7.3-xmlrpc php7.3-zip php7.3-opcache -y
设置 PHP
/etc/php/7.3/fpm/php.ini
替换换 ;cgi.fix_pathinfo=1
为 cgi.fix_pathinfo=0
快捷命令:sed -i ‘s/;cgi.fix_pathinfo=1/cgi.fix_pathinfo=0/‘ /etc/php/7.3/fpm/php.ini
管理 PHP
systemctl restart php7.3-fpm
systemctl restart php7.3-fpm #重启
systemctl start php7.3-fpm #启动
systemctl stop php7.3-fpm #关闭
systemctl status php7.3-fpm #检查状态
查看 PHP
root@mf88.biz-service:~# php -v
PHP 7.3.0-1+ubuntu18.04.1+deb.sury.org+1 (cli) (built: Dec 6 2018 20:24:55) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.3.0-dev, Copyright (c) 1998-2018 Zend Technologies
with Zend OPcache v7.3.0-1+ubuntu18.04.1+deb.sury.org+1, Copyright (c) 1999-2018, by Zend Technologies
更新 PHP
apt update
apt upgrade -y
安装更多组件
root@mf88.biz-service:~# apt-cache search php7.3
php-amqp - AMQP extension for PHP
php-apcu - APC User Cache for PHP
php-apcu-bc - APCu Backwards Compatibility Module
php-ds - PHP extension providing efficient data structures for PHP 7
php-gearman - PHP wrapper to libgearman
php-geoip - GeoIP module for PHP
php-gmagick - Provides a wrapper to the GraphicsMagick library
php-gnupg - PHP wrapper around the gpgme library
php-http - PECL HTTP module for PHP Extended HTTP Support
php-igbinary - igbinary PHP serializer
php-imagick - Provides a wrapper to the ImageMagick library
php-mailparse - Email message manipulation for PHP
php-memcache - memcache extension module for PHP
php-memcached - memcached extension module for PHP, uses libmemcached
php-mongodb - MongoDB driver for PHP
php-msgpack - PHP extension for interfacing with MessagePack
php-oauth - OAuth 1.0 consumer and provider extension
php-propro - propro module for PHP
php-radius - radius client library for PHP
php-raphf - raphf module for PHP
php-redis - PHP extension for interfacing with Redis
php-rrd - PHP bindings to rrd tool system
php-smbclient - PHP wrapper for libsmbclient
php-solr - PHP extension for communicating with Apache Solr server
php-ssh2 - Bindings for the libssh2 library
php-stomp - Streaming Text Oriented Messaging Protocol (STOMP) client module for PHP
php-tideways - Tideways PHP Profiler Extension
php-uploadprogress - file upload progress tracking extension for PHP
php-uuid - PHP UUID extension
php-yac - YAC (Yet Another Cache) for PHP
php-yaml - YAML-1.1 parser and emitter for PHP
php-zmq - ZeroMQ messaging bindings for PHP
php-xdebug - Xdebug Module for PHP
php-lua - PHP Embedded lua interpreter
libapache2-mod-php7.3 - server-side, HTML-embedded scripting language (Apache 2 module)
libphp7.3-embed - HTML-embedded scripting language (Embedded SAPI library)
php7.3-bcmath - Bcmath module for PHP
php7.3-bz2 - bzip2 module for PHP
php7.3-cgi - server-side, HTML-embedded scripting language (CGI binary)
php7.3-cli - command-line interpreter for the PHP scripting language
php7.3-common - documentation, examples and common module for PHP
php7.3-curl - CURL module for PHP
php7.3-dba - DBA module for PHP
php7.3-dev - Files for PHP7.3 module development
php7.3-enchant - Enchant module for PHP
php7.3-fpm - server-side, HTML-embedded scripting language (FPM-CGI binary)
php7.3-gd - GD module for PHP
php7.3-gmp - GMP module for PHP
php7.3-imap - IMAP module for PHP
php7.3-interbase - Interbase module for PHP
php7.3-intl - Internationalisation module for PHP
php7.3-json - JSON module for PHP
php7.3-ldap - LDAP module for PHP
php7.3-mbstring - MBSTRING module for PHP
php7.3-mysql - MySQL module for PHP
php7.3-odbc - ODBC module for PHP
php7.3-opcache - Zend OpCache module for PHP
php7.3-pgsql - PostgreSQL module for PHP
php7.3-phpdbg - server-side, HTML-embedded scripting language (PHPDBG binary)
php7.3-pspell - pspell module for PHP
php7.3-readline - readline module for PHP
php7.3-recode - recode module for PHP
php7.3-snmp - SNMP module for PHP
php7.3-soap - SOAP module for PHP
php7.3-sqlite3 - SQLite3 module for PHP
php7.3-sybase - Sybase module for PHP
php7.3-tidy - tidy module for PHP
php7.3-xml - DOM, SimpleXML, WDDX, XML, and XSL module for PHP
php7.3-xmlrpc - XMLRPC-EPI module for PHP
php7.3-zip - Zip module for PHP
php7.3-xsl - XSL module for PHP (dummy)
php7.3 - server-side, HTML-embedded scripting language (metapackage)
上一篇:HTML(一)基本结构
下一篇:C#NULL条件运算符
文章标题:在 Ubuntu/Debian 下安装 PHP7.3 教程
文章链接:http://soscw.com/index.php/essay/89830.html