无法使用终端卸载php-memcache

tomas.teicher

我使用命令从计算机上卸载了php5

sudo apt-get -y purge php.*

运行此命令将在终端显示此消息:

Errors were encountered while processing: php5-memcache php5-memcached

所以我尝试卸载memcache:

sudo apt-get remove php-memcache

它向我显示了一条消息,它找不到memcache软件包:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package php-memcache

然后进行memcached:

apt-get remove php5-memcached

它向我抛出有关php中缺少依赖项的信息:

The following packages have unmet dependencies.
php5-memcache : Depends: php5-common (>= 4.3.11) but it is not going to be installed  
      Depends: php-pear (>= 1.4.0~b1) but it is not going to be installed
      Depends: phpapi-20121212
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

跑步

apt-get -f install

再次抛出有关删除内存缓存的错误。

据我正确理解,我犯了一个错误,我没有在卸载php5之前删除memcache?我现在能做什么?我需要再次安装php吗?当我尝试安装缺少的依赖项时,我收到有关另一个缺少的软件包的消息。使用“ apt-get”时,是否应该缺少自动添加/删除的软件包?

通过谷歌搜索我发现,问题可能出在使用不适合我的系统的错误存储库。如何检测哪些存储库适合我的系统安装/卸载用于卸载Memcache的适当软件包?谢谢你的帮助

我已经将这样的php存储库添加到我的系统中:http : //ppa.launchpad.net/ondrej/php5/ubuntu http://ppa.launchpad.net/ondrej/php5/ubuntu http://ppa.launchpad.net/ ondrej / php-7.0 / ubuntu http://ppa.launchpad.net/ondrej/php-7.0/ubuntu

我尝试根据@oerdnj用dpkg删除memcache,但仍然出现一些错误:

tomas@Toshiba ~ $ sudo dpkg --purge php5-memcache
(Reading database ... 275094 files and directories currently   installed.)
Removing php5-memcache (3.0.8-4build1) ...
/var/lib/dpkg/info/php5-memcache.prerm: 9: /var/lib/dpkg/info/php5-  memcache.prerm: php5dismod: not found
dpkg: error processing package php5-memcache (--purge):
subprocess installed pre-removal script returned error exit status 127
Errors were encountered while processing:
php5-memcache

我还尝试了线程解决方案如何删除/安装未完全安装的软件包?但它向我显示了相同的错误:

tomas@Toshiba ~ $ sudo apt-get install --reinstall dpkg
[sudo] password for tomas: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies.
php5-memcache : Depends: php5-common (>= 4.3.11) but it is not going      to be installed
Depends: php-pear (>= 1.4.0~b1) but it is not going to be installed
             Depends: phpapi-20121212
php5-memcached : Depends: libmemcached10 but it is not going to be installed
              Depends: php5-common (>= 5.2.0) but it is not going to be installed
              Depends: php5-common (< 6.0.0) but it is not going to be installed
              Depends: php-pear (>= 1.4.0~b1) but it is not going to be installed
              Depends: phpapi-20121212
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
Oerdnj

如果您的系统处于apt-get几乎无法使用的状态,则可以尝试使用dpkg来删除受影响的软件包,在这种情况下,请尝试:

sudo dpkg --purge php5-memcache

dpkg 是一种用于处理软件包的低级工具,它并没有尽力使所有软件包保持一致的状态。

由于php5dismod您的系统缺少该文件,因此我建议您手动删除/var/lib/dpkg/info/php5-memcache.prerm/var/lib/dpkg/info/php5-memcache.postrm文件,并/etc/php5/手动清理内存缓存配置的痕迹(可能会在此处找到主要的memcache.ini符号链接20-memcache.ini)。

注意:如果您不完全了解自己在做什么,请不要尝试从Internet上尝试其他随机事情,否则可能会破坏系统。

本文收集自互联网,转载请注明来源。

如有侵权,请联系[email protected] 删除。

编辑于
0

我来说两句

0条评论
登录后参与评论

相关文章

来自分类Dev

PHP:Pthread + Memcache问题

来自分类Dev

在IAsyncActionFilter中使用MemCache

来自分类Dev

如何使用Memcache协议

来自分类Dev

找不到php Memcache类别

来自分类Dev

PHP Memcache延长数据时间

来自分类Dev

php-memcache中的memcache.dbpath究竟设置了什么?

来自分类Dev

PHP Memcache无法写入会话数据

来自分类Dev

使用Memcache的PDO存储阵列

来自分类Dev

在CentOS上使用PHP 7的Memcache扩展无法安装

来自分类Dev

PHP会话锁定并使用Memcache存储会话

来自分类Dev

PHP Memcache使用“ true”获取值的问题

来自分类Dev

memcache php存储超过1MB

来自分类Dev

使用Memcache进行棘轮会话数据同步

来自分类Dev

PHP的Memcache扩展-XAMPP Windows无法正常工作

来自分类Dev

PHP - memcache 随机失败 - 无法分配请求的地址 (99)

来自分类Dev

如何在PHP中使用memcached(而非memcache)

来自分类Dev

PHP Memcached是否完全向后兼容Memcache?

来自分类Dev

为什么PHP Sessions Memcached可以工作,但Memcache不能工作?

来自分类Dev

如何在Windows上安装PHP 7扩展“ memcache”

来自分类Dev

为什么PHP Sessions Memcached可以工作,但Memcache不能工作?

来自分类Dev

如何在PHP中连接到Memcache服务器?

来自分类Dev

session_start():在yii2中启用memcache时,无法初始化存储模块:memcache(路径:/ tmp)

来自分类Dev

在yii2中使用memcache缓存值

来自分类Dev

如何在Yii中使用CFileCache和Memcache

来自分类Dev

Memcache在使用acts_as_cached插件时获取错误的值

来自分类Dev

如何使用在App Engine中导入Memcache的库

来自分类Dev

如何在Gae,NDB中使用Memcache缓存分页查询?

来自分类Dev

如何使用Rails.cache.fetch和memcache存储零?

来自分类Dev

在yii2中使用memcache缓存值

Related 相关文章

热门标签

归档