修復 Ubuntu 中 “E: The package cache file is corrupted, it has the wrong hash”
今天,我嘗試更新我的 Ubuntu 18.04 LTS 的倉庫列表,但收到了一條錯誤訊息:“E: The package cache file is corrupted, it has the wrong hash”。這是我在終端執行的命令以及輸出:
$ sudo apt update
示例輸出:
Hit:1 http://it-mirrors.evowise.com/ubuntu bionic InRelease
Hit:2 http://it-mirrors.evowise.com/ubuntu bionic-updates InRelease
Hit:3 http://it-mirrors.evowise.com/ubuntu bionic-backports InRelease
Hit:4 http://it-mirrors.evowise.com/ubuntu bionic-security InRelease
Hit:5 http://ppa.launchpad.net/alessandro-strada/ppa/ubuntu bionic InRelease
Hit:7 http://ppa.launchpad.net/leaeasy/dde/ubuntu bionic InRelease
Hit:8 http://ppa.launchpad.net/rvm/smplayer/ubuntu bionic InRelease
Ign:6 https://dl.bintray.com/etcher/debian stable InRelease
Get:9 https://dl.bintray.com/etcher/debian stable Release [3,674 B]
Fetched 3,674 B in 3s (1,196 B/s)
Reading package lists... Done
E: The package cache file is corrupted, it has the wrong hash
Ubuntu 中的 “The package cache file is corrupted, it has the wrong hash” 錯誤
經過一番谷歌搜尋,我找到了解決此錯誤的方法。
如果你遇到過這個錯誤,不要驚慌。只需執行下面的命令修復。
在執行命令之前,請再次確認你在最後加入了 *
。在命令最後加上 *
很重要。如果你沒有新增,它會刪除 /var/lib/apt/lists/
*目錄,而且無法恢復。我提醒過你了!
$ sudo rm -rf /var/lib/apt/lists/*
現在我再次使用下面的命令更新系統:
$ sudo apt update
現在好了!希望它有幫助。
相關文章
- 修復已經CORRUPTED的資料塊
- 解決Ubuntu報錯 E: Unable to locate package yumUbuntuPackage
- 解決E: Package ‘libmysqlclient-dev‘ has no installation candidate報錯PackageIBMMySqlclientdev
- library cache及buffer cache中如何利用hash演算法得到hash值演算法
- Canonical 修復 Ubuntu 13.04 中 Linux 核心漏洞UbuntuLinux
- Ubuntu 更新錯誤修復大全Ubuntu
- Element package.json 中的 scripts 分析 —— "build:file"PackageJSONUI
- 如何修復ubuntu的系統引導Ubuntu
- 如何在 Linux 中修復“fatal error: x264.h: No such file or directoLinuxError
- File hash GET parameters for Django staticfilesDjango
- 利用easybcd修復Ubuntu的grub啟動項Ubuntu
- 修復Ubuntu 14.04中Chromium的Adobe Flash Player的問題Ubuntu
- centos Vmware虛擬機器 Oh no,something has gone wrong! 解決方法CentOS虛擬機Go
- 討論:關於The REBIND utility and the FLUSH PACKAGE CACHEPackage
- ubuntu linux無法啟動的修復(轉)UbuntuLinux
- module ‘h5py‘ has no attribute ‘File‘H5
- 解決The jar file has no source attachment問題JAR
- R安裝package報ERROR: a 'NAMESPACE' file is requiredPackageErrornamespaceUI
- 關於Jive論壇中CACHE Hash機制的一個疑問
- 不重灌也能修復損壞的 Ubuntu 系統Ubuntu
- lenovo e595中win10移動熱點自動關閉怎麼修復Win10
- 如何修復Java中的VirtualMachineErrorJavaMacError
- Trouble shooting(問題解決):centos 7 gnome show someting has gone wrong.CentOSGo
- CF 39E What Has Dirichlet Got to Do with That? (博弈)Go
- 【構建Android快取模組】(二)Memory Cache & File CacheAndroid快取
- 1104File Space Bitmap Block損壞能修復嗎BloC
- Ubuntu 安裝包時提示錯誤E: Unable to locate package mysql-server錯誤 解決辦法UbuntuPackageMySqlServer
- ubuntu更新報錯Hash Sum mismatchUbuntu
- ORA-04063: package body "SYS.DBMS_EXPORT_EXTENSION" has errorsPackageExportError
- ORA-04063: package body "EXFSYS.DBMS_EXPFIL_EXP" has errorsPackageError
- ORA-04063: package body "SYS.LT_EXPORT_PKG" has errorsPackageExportError
- ORA-01578 data block corrupted 資料檔案損壞 與 修復 (多為借鑑 linux)BloCLinux
- 轉淘寶流雲dbms_file_transfer package usagePackage
- DBMS_FILE_TRANSFER Package in Oracle Database 10gPackageOracleDatabase
- 一個簡單的方法修復ubuntu引導損壞Ubuntu
- Ubuntu釋出PHP重要補丁修復多個PHP漏洞UbuntuPHP
- squid!Your cache is running out of fileUI
- What is wrong?