debian php5.4,Debian wheezy升级php 5.4到5.5

[解决了]

我有Debian Wheezy安装php 5.4.18.

我想升级到5.5.x,但是标准的程序不能正常工作.

这是我的/etc/apt/sources.list文件:

# deb cdrom:[Debian GNU/Linux 7.0.0 _Wheezy_ - Official amd64 NETINST Binary-1 20130504-14:43]/ wheezy main

deb http://ftp.pl.debian.org/debian/ wheezy main

deb-src http://ftp.pl.debian.org/debian/ wheezy main

deb http://security.debian.org/ wheezy/updates main

deb-src http://security.debian.org/ wheezy/updates main

# wheezy-updates, previously known as 'volatile'

deb http://ftp.pl.debian.org/debian/ wheezy-updates main

deb-src http://ftp.pl.debian.org/debian/ wheezy-updates main

#php 5.5

deb http://packages.dotdeb.org wheezy-php55 all

deb-src http://packages.dotdeb.org wheezy-php55 all

我更新了来源

apt-get update

并安装php5

apt-get install php5

但是在httpd重新启动后,我还是有旧的php版本.

php -v

收益:

root@xxx:/# php -v

PHP 5.4.18 (cli) (built: Aug 19 2013 04:03:40)

Copyright (c) 1997-2013 The PHP Group

Zend Engine v2.4.0, Copyright (c) 1998-2013 Zend Technologies

with Xdebug v2.2.1, Copyright (c) 2002-2012, by Derick Rethans

当我搜索php

find / -name php5

我可以看到刚刚安装的文件

root@xxx:/usr/bin# ls -l php*

lrwxrwxrwx 1 root root 21 Dec 11 00:15 php -> /etc/alternatives/php

-rwxr-xr-x 1 root root 8956912 Nov 17 02:37 php5

root@xxx:/usr/bin# ./php5 -v

PHP 5.5.19-1~dotdeb.1 (cli) (built: Nov 17 2014 01:24:08)

Copyright (c) 1997-2014 The PHP Group

Zend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies

with Zend OPcache v7.0.4-dev, Copyright (c) 1999-2014, by Zend Technologies

with Xdebug v2.2.6, Copyright (c) 2002-2014, by Derick Rethans

root@xxxx:/usr/bin# ./php -v

PHP 5.5.19-1~dotdeb.1 (cli) (built: Nov 17 2014 01:24:08)

Copyright (c) 1997-2014 The PHP Group

Zend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies

with Zend OPcache v7.0.4-dev, Copyright (c) 1999-2014, by Zend Technologies

with Xdebug v2.2.6, Copyright (c) 2002-2014, by Derick Rethans

我的phpinfo返回PHP版本5.4.18

我做错了什么?

//编辑:

我通过directadmin / custombuild更新它

root@xxxx:/usr/local/directadmin/custombuild# vim options.conf

我换行了

php1_release=5.4

php1_release=5.5

和下一个:

root@xxxx:/usr/local/directadmin/custombuild# ./build update_data

# [..]

root@xxxx:/usr/local/directadmin/custombuild# ./build php d

# [..]

现在我有php 5.5.19,我可以使用password_hash()函数;)

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值