㈠ 阿里云上的centos 7.2怎么yum安装php 5.6
阿里云Centos配置php环境方法/步骤打开putty工具,在主机名称中输入阿里云ecs的IP地址和端口。输入好后,点击“打开”进入。进入putty界面后,输入系统账号和密码。提示一下密码是暗文的,输入密码时不简首会显示在屏幕上的拦睁数。进入系统后,输入命令进行安装。安装apache:yum install httpd httpd-devel 启动apache:/etc/init.d/httpd start此时输入服务器的IP地址,应该看到apache的服务页面,端口不用输,apache默认就是使用80端口安装mysql:yum install mysql mysql-server启动mysql:/etc/init.d/mysqld start安装phpyum install php php-devel重启apache使php生效/etc/init.d/httpd restart安装php的扩展yum install php-mysql php-gd php-imap php-ldap php-odbc php-pear php-xml php-xmlrpc安装完扩展之后需要再次重启apache/etc/init.d/httpd restart最后在目录:/var/www/html/下建立一个PHP文件代码内容如下:<?php phpinfo(); ?>当你访问这个文件时,就能看到php版本以及所安装的插件信息了。4安装完所有的软件后,安装VPSMate面板。它提供界面化操作文件和控制软件。本数据来源于网络地图,最终结果以网络地图最新数据为准。我现在使早御用的是小鸟云。他们官网最近有活动蛮优惠,可以去看看!
㈡ 阿里云上的centos 7.2怎么yum安装php 5.6
因之前通过网易的 centos 镜像,将阿里云的 centos 升级到最新版了,乘自己的项目尚未开始正式开发,遂将所有的相应环境都升级到最高。查看 centos 版本:[[email protected] ~]# cat /etc/centos-releaseCentOS linux release 7.2.1511 (Core)1、删除之前的 php 版本:[[email protected] ~]# yum remove php* php-commonLoaded plugins: langpacksRepository base is listed more than once in the configurationRepository updates is listed more than once in the configurationRepository extras is listed more than once in the configurationRepository centosplus is listed more than once in the configurationNo Match for argument: php-5.4.16No Match for argument: php-5.4.16.tar.gzNo Match for argument: php-7.0.1RC1No Match for argument: php-7.0.1RC1.tar.gzNo Match for argument: phpMyAdmin-4.4.0.tar.gzNo Match for argument: php-commonNo Packages marked for removal2、rpm 安装 Php7 相应的 yum源:[[email protected] ~]# rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpmRetrieving https://mirror.webtatic.com/yum/el7/webtatic-release.rpmwarning: /var/tmp/rpm-tmp.LhJKKR: Header V4 RSA/SHA1 Signature, key ID 62e74ca5: NOKEYPreparing… ################################# [100%]package webtatic-release-7-3.noarch is already installed3、 直接yum安装php7:[[email protected] ~]# yum install php70wLoaded plugins: langpacksRepository base is listed more than once in the configurationRepository updates is listed more than once in the configurationRepository extras is listed more than once in the configurationRepository centosplus is listed more than once in the configurationResolving Dependencies–> Running transaction check。。。 【省略】Warning: RPMDB altered outside of yum.Installing : php70w-common-7.0.0-1.w7.x86_64 1/3Installing : php70w-cli-7.0.0-1.w7.x86_64 2/3Installing : php70w-7.0.0-1.w7.x86_64 3/3Verifying : php70w-7.0.0-1.w7.x86_64 1/3Verifying : php70w-common-7.0.0-1.w7.x86_64 2/3Verifying : php70w-cli-7.0.0-1.w7.x86_64 3/3Installed:php70w.x86_64 0:7.0.0-1.w7Dependency Installed:php70w-cli.x86_64 0:7.0.0-1.w7 php70w-common.x86_64 0:7.0.0-1.w7Complete!4、检查 php 版本:[[email protected] ~]# php -vPHP 7.0.0 (cli) (built: Dec 2 2015 20:42:32) ( NTS )Copyright (c) 1997-2015 The PHP GroupZend Engine v3.0.0, Copyright (c) 1998-2015 Zend Technologies[[email protected] ~]#以上显示安装成功!5、重启 Apache,查看 phpinfo :[[email protected] ~]# systemctl restart httpd.service检查phpinfo:PHP Version 7.0.0SystemLinux iZ23d 3.10.0-229.11.1.el7.x86_64 #1 SMP Thu Aug 6 01:06:18 UTC 2015 x86_64Build DateDec 2 2015 20:43:38Server APIApache 2.0 HandlerVirtual Directory SupportdisabledConfiguration File (php.ini) Path/etcLoaded Configuration File/etc/php.iniScan this dir for additional .ini files/etc/php.dAdditional .ini files parsed/etc/php.d/bz2.ini, /etc/php.d/calendar.ini, /etc/php.d/ctype.ini, /etc/php.d/curl.ini, /etc/php.d/exif.ini, /etc/php.d/fileinfo.ini, /etc/php.d/ftp.ini, /etc/php.d/gettext.ini, /etc/php.d/gmp.ini, /etc/php.d/iconv.ini, /etc/php.d/json.ini, /etc/php.d/phar.ini, /etc/php.d/shmop.ini, /etc/php.d/simplexml.ini, /etc/php.d/sockets.ini, /etc/php.d/tokenizer.ini, /etc/php.d/xml.ini, /etc/php.d/zip.iniPHP API20151012PHP Extension20151012Zend Extension320151012Zend Extension BuildAPI320151012,NTSPHP Extension BuildAPI20151012,NTSDebug BuildnoThread SafetydisabledZend Signal HandlingdisabledZend Memory ManagerenabledZend Multibyte SupportdisabledIPv6 SupportenabledDTrace SupportenabledRegistered PHP Streamshttps, ftps, compress.zlib, php, file, glob, data, http, ftp, compress.bzip2, phar, zipRegistered Stream Socket Transportstcp, udp, unix, udg, ssl, sslv3, sslv2, tls, tlsv1.0, tlsv1.1, tlsv1.2Registered Stream Filterszlib.*, string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, dechunk, bzip2.*, convert.iconv.*This program makes use of the Zend Scripting Language Engine:Zend Engine v3.0.0, Copyright (c) 1998-2015 Zend TechnologiesConfigurationapache2handlerApache VersionApache/2.4.6 (CentOS)Apache API Version20120211Server [email protected]Hostname:Portxxxx.xxxxx.xxx:0User/Groupapache(48)/48Max RequestsPer Child: 0 – Keep Alive: on – Max Per Connection: 100TimeoutsConnection: 60 – Keep-Alive: 15Virtual ServerYesServer Root/etc/httpdLoaded Molescore mod_so http_core mod_access_compat mod_actions mod_alias mod_allowmethods mod_auth_basic mod_auth_digest mod_authn_anon mod_authn_core mod_authn_dbd mod_authn_dbm mod_authn_file mod_authn_socache mod_authz_core mod_authz_dbd mod_authz_dbm mod_authz_groupfile mod_authz_host mod_authz_owner mod_authz_user mod_autoindex mod_cache mod_cache_disk mod_data mod_dbd mod_deflate mod_dir mod_mpio mod_echo mod_env mod_expires mod_ext_filter mod_filter mod_headers mod_include mod_info mod_log_config mod_logio mod_mime_magic mod_mime mod_negotiation mod_remoteip mod_reqtimeout mod_rewrite mod_setenvif mod_slotmem_plain mod_slotmem_shm mod_socache_dbm mod_socache_memcache mod_socache_shmcb mod_status mod_substitute mod_suexec mod_unique_id mod_unixd mod_userdir mod_version mod_vhost_alias mod_dav mod_dav_fs mod_dav_lock mod_lua prefork mod_proxy mod_lbmethod_bybusyness mod_lbmethod_byrequests mod_lbmethod_bytraffic mod_lbmethod_heartbeat mod_proxy_ajp mod_proxy_balancer mod_proxy_connect mod_proxy_express mod_proxy_fcgi mod_proxy_fdpass mod_proxy_ftp mod_proxy_http mod_proxy_scgi mod_proxy_wstunnel mod_ssl mod_systemd mod_cgi mod_perl mod_php7以上显示 php7 安装成功!
㈢ 如何在CentOS 6.5上升级PHP版本
在更新PHP之前,先查看下当前PHP版本,避免重复的更新# php -v如何在CentOS 6.5上升级PHP检查当前PHP的安装包# yum list installed | grep php如何在CentOS 6.5上升级PHP移除当前PHP的安装包,否则容易起冲突# yum remove php*如何在CentOS 6.5上升级PHP由于默认的YUM源无法升级PHP,所以需要添加第三方的YUM源,此处用到webtatic。因为是CentOS 6.5,所以用以下URL# rpm -Uvh http://mirror.webtatic.com/yum/el6/latest.rpm如果是CentOS 7.xrpm -Uvh https://mirror.webtatic.com/yum/el7/epel-release.rpmrpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm如何在CentOS 6.5上升级PHP查看YUM源上能用PHP安装包# yum list php*如何在CentOS 6.5上升级PHP安装PHP5.5及需要的扩展# yum install php55w php55w-devel php55w-common php55w-mysql php55w-pdo php55w-opacache php55w-xml如何在CentOS 6.5上升级PHP再次查看PHP版本,以确认安装是否成功如何在CentOS 6.5上升级PHP对了,如果你的PHP要用到Redis,请别忘了安装php-redis 扩展# yum install php-redis如何在CentOS 6.5上升级PHP
㈣ yum 安装的php56怎么配置
action直接空,直接用submit按钮,点击不就提交到当前页面了额,<input id="submit1" name="submit1" type="button">你这个地方干嘛用button,用submit按钮专额如果楼主还是不清楚属,楼主可以去后盾人学习,我就是在哪里学习
㈤ 如何在CentOS 6.5上升级PHP版本
在更新PHP之前,先查看下当前PHP版本,避免重复的更新# php -v如何在CentOS 6.5上升级PHP检查当前PHP的安装包# yum list installed | grep php如何在CentOS 6.5上升级PHP移除当前PHP的安装包,否则容易起冲突# yum remove php*如何在CentOS 6.5上升级PHP由于默认的YUM源无法升级PHP,所以需要添加第三方的YUM源,此处用到webtatic。因为是CentOS 6.5,所以用做衡以下URL# rpm -Uvh http://mirror.webtatic.com/yum/el6/latest.rpm如果是CentOS 7.xrpm -Uvh https://mirror.webtatic.com/yum/el7/epel-release.rpmrpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm如何在CentOS 6.5上升级PHP查看YUM源上能用PHP安装包# yum list php*如何在CentOS 6.5上升级PHP激胡激安装PHP5.5及需要的扩展# yum install php55w php55w-devel php55w-common php55w-mysql php55w-pdo php55w-opacache php55w-xml如何在明袜CentOS 6.5上升级PHP再次查看PHP版本,以确认安装是否成功如何在CentOS 6.5上升级PHP对了,如果你的PHP要用到Redis,请别忘了安装php-redis 扩展# yum install php-redis
㈥ linux系统的服务器上如何将php软件进行升级
|rpm -Uvh http://ftp.iij.ad.jp/pub/linux/fedora/epel/6/x86_64/epel-release-6-8.noarch.rpmrpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpmyum list –enablerepo=remi –enablerepo=remi-php56 | grep phpyum install –enablerepo=remi –enablerepo=remi-php56 php php-opcache php-devel php-mbstring php-mcrypt php-mysqlnd php-phpunit-PHPUnit php-pecl-xdebug php-pecl-xhprofphp –version
㈦ yum 安装lamp怎么升级php
centos6.51.yum安装和源代码编译在使用的时候没啥区别,但是安装的过程就大相径庭了,yum只需要3个命令就可以完成,源代码需要13个包,还得加压编译,步骤很麻烦,而且当做有时候会出错,源代码编译安装大概需要2个小时,好处在于可以自己配置地址等一些亏搜饥参数,yum安装半个小时搞定,一般不漏姿会出错,更新也很方便。2.我的机器是centosrelease5.964为的系销返统,一般机器都带yum命令,并且yum包源都是可以用的,就是说不用你自己下载东西,直接yum-yinstall后面加上你所需要安装的软件,他会自动下载自动安装,非常方便。例如yum-yinstallhttpd自动下载并安装apache服务器。lamp环境只需要安装httpd,MySQL,PHP3.首先更新一下yum-yupdate4.用yum安装Apache,Mysql,PHP.4.1安装Apacheyuminstallhttpdhttpd-devel安装完成后,用/etc/init.d/httpdstart启动apache设为开机启动:chkconfighttpdon4.2安装mysqlyuminstallmysqlmysql-servermysql-devel同样,完成后,用/etc/init.d/mysqldstart启动mysql4.3设置mysql密码mysql>;USEmysql;mysql>;UPDATEuserSETPassword=PASSWORD('newpassword')WHEREuser='root';mysql>;FLUSHPRIVILEGES;设置mysql密码还可以用:mysql_secure_installation命令4.4允许远程登录mysql-uroot-pEnterPassword:<yournewpassword>mysql>GRANTALLPRIVILEGESON*.*TO'用户名'@'%'IDENTIFIEDBY'密码'WITHGRANTOPTION;完成后就能用mysql-front远程管理mysql了。设为开机启动chkconfigmysqldon5PHP5.4安装rpm-Uvhhttp://mirror.webtatic.com/yum/el6/latest.rpm(下载最新的源)yuminstallphp54wphp54w-bcmathphp54w-cliphp54w-commonphp54w-develphp54w-fpmphp54w-gdphp54w-imapphp54w-ldapphp54w-mbstringphp54w-mcryptphp54w-mysqlphp54w-odbcphp54w-pdophp54w-pearphp54w-pecl-igbinaryphp54w-xmlphp54w-xmlrpcphp54w-opcachephp54w-intlphp54w-pecl-memcache安装PHP对应的各种扩展;使用yum安装就是各种方便,用源码安装试了十几次,各种bug无法解决
㈧ php5.3如何升级到php5.6
升级很容易,先卸载 php 5..=3 yum remove php* 然后安装 yum install php56* 就可以了如果轮历含我的回答没烂肢能帮助您,请腊笑继续追问。
㈨ centos6.5的php5.3.3这个版本怎么升级到5.6
简单介绍一下,如何在CentOS上安装PHP5.6。
配置yum源
追加CentOS 6.5的epel及remi源。
#rpm-Uvhhttp://ftp.iij.ad.jp/pub/linux/fedora/epel/6/x86_64/epel-release-6-8.noarch.rpm#rpm-Uvhhttp://rpms.famillecollet.com/enterprise/remi-release-6.rpm
以下是CentOS 7.0的源。
#yuminstallepel-release#rpm-ivhhttp://rpms.famillecollet.com/enterprise/remi-release-7.rpm
使用yum list命令查看可安装的包(Packege)。
#yumlist–enablerepo=remi–enablerepo=remi-php56|grepphp
安装PHP5.6
yum源配置好了,下一步就安装PHP5.6。
#yuminstall–enablerepo=remi–enablerepo=remi-php56phpphp-opcachephp-develphp-mbstringphp-mcryptphp-mysqlndphp-phpunit-PHPUnitphp-pecl-xdebugphp-pecl-xhprof
用PHP命令查看版本。
#php–versionPHP5.6.0(cli)(built:Sep3201419:51:31)Copyright(c)1997-2014ThePHPGroupZendEnginev2.6.0,Copyright(c)1998-2014ZendTechnologieswithZendOPcachev7.0.4-dev,Copyright(c)1999-2014,byZendTechnologieswithXdebugv2.2.5,Copyright(c)2002-2014,byDerickRethans
在这里安装的版本是PHP5.6.0,细心的用户可能已经发现ZendGuardLoader变成Zend OPcahe了。
对从PHP5.5开始PHP代码缓存从APC变成了Zend OPcache了。
更多问题可以去php中文网问答社区提问http://www.php.cn/wenda.html,大神在线帮你解决,希望对你有帮助
㈩ 如何在linux上安装php5.6,谢谢,
不知道你问的linux,是哪个发行版本,常用的如 ubntu,centos,debian等。
我列一个centos7(服务器常用这个版本)的安装方法吧
centos7默认使用yum install 来安装程序,但默认源安装的php是5.4的,版本比较低,
要安装高版本的,要么下载源代码手动编译安装,但对不熟悉的,万一出点错误,会越搞越乱。我一般使用epel源安装php,里面各个版本都有,最新的php7.3
首先安装epel
rpm -ivh http://dl.fedoraproject.org/pub/epel/7/x86_64/Packages/e/epel-release-7-11.noarch.rpm
这里面的url是目前我用的,如果提示出错,就是换url了,可以在电脑上手动打开epel源列表去检查 epel-release是哪个版本,换上对应的名字
按版本安装php
rpm-Uvhhttps://mirror.webtatic.com/yum/el7/webtatic-release.rpmyuminstallphp56wphp56w-mysqlphp56w-pdophp56w-gdphp56w-sslphp56w-mbstringphp56w-cliphp56w-xmlphp56w-bcmath
我这里列的是一些常用的php扩展,如果需要其它的,手动加上即可
如果需要安装php其它版本,把包名里的56改成对应版本即可 ,如
yuminstallphp71wphp71w-mysqlphp71w-pdophp71w-gdphp71w-sslphp71w-mbstringphp71w-cliphp71w-xmlphp71w-bcmathyuminstallphp72wphp72w-mysqlphp72w-pdophp72w-gdphp72w-sslphp72w-mbstringphp72w-cliphp72w-xmlphp72w-bcmath
可对应安装php7.1和php7.2,这种安装方法,会默认配置好对应的设置,php.ini在/etc/中查找,命令行也默认启用了 (php-cli)