Failed to fetch [... stuff, b/c of ...] Hash Sum mismatch

superwow

Dear Vsidians,

Could y'all help a brotha out?

I had an update hang several days ago. As in, in the midst of the update, everything just froze, for like 25 min. I'm not sure why or what the problem was. However, I had to ctrl+x ctrl+c to quit the apt-get update. Since that time, I have not been able to update.

I have removed the content of /var/lib/apt/lists/partial several times on advice from the intertubes. But no joy. Other solutions from the web & ubuntu/mint/debian forums all suggest removing the contents of the partial folder, or using dpkg-dev. However, I would like to figure out the 'appropriate' and 'standard' way to manage this is, rather than downloading a developer package. I'm pretty sure the answer is simple, yet I admit I am obtuse.

CLI I/O follow....including the error, my sources list, and my apt-cache policy.


superwow@grmldeb ~ % sudo apt-get update && sudo apt-get dist-upgrade                                              v61%
[sudo] password for superwow:
Hit http://http.debian.net sid InRelease
Get:1 http://http.debian.net sid/main Sources/DiffIndex [7,876 B]
Get:2 http://http.debian.net sid/contrib Sources/DiffIndex [7,819 B]
Get:3 http://http.debian.net sid/non-free Sources/DiffIndex [7,819 B]                   
Get:4 http://http.debian.net sid/main amd64 Packages/DiffIndex [7,876 B]
Get:5 http://http.debian.net sid/contrib amd64 Packages/DiffIndex [7,819 B]
Get:6 http://http.debian.net sid/non-free amd64 Packages/DiffIndex [7,819 B]                 
Get:7 http://http.debian.net sid/contrib Translation-en/DiffIndex [7,819 B]                                       
Get:8 http://http.debian.net sid/main Translation-en/DiffIndex [7,876 B]                           
Get:9 http://http.debian.net sid/non-free Translation-en/DiffIndex [7,819 B]         
Get:10 http://http.debian.net sid/main 2015-03-29-2048.27.pdiff [8,486 B]
Get:11 http://http.debian.net sid/main 2015-03-30-0247.33.pdiff [3,477 B]       
Get:12 http://http.debian.net sid/main 2015-03-30-1447.17.pdiff [5,609 B]
Get:13 http://http.debian.net sid/main 2015-03-30-2049.01.pdiff [1,097 B]
Get:14 http://http.debian.net sid/main 2015-03-30-2049.01.pdiff [1,097 B]
Fetched 89.2 kB in 4s (20.8 kB/s)
W: Failed to fetch http://http.debian.net/debian/dists/sid/main/source/SourcesIndex  Hash Sum mismatch

E: Some index files failed to download. They have been ignored, or old ones used instead.

superwow@grmldeb ~ % ls /var/lib/apt/lists                                                                         v59%
http.debian.net_debian_dists_sid_contrib_binary-amd64_Packages
http.debian.net_debian_dists_sid_contrib_binary-amd64_Packages.IndexDiff
http.debian.net_debian_dists_sid_contrib_i18n_Translation-en
http.debian.net_debian_dists_sid_contrib_i18n_Translation-en.IndexDiff
http.debian.net_debian_dists_sid_contrib_source_Sources
http.debian.net_debian_dists_sid_contrib_source_Sources.IndexDiff
http.debian.net_debian_dists_sid_InRelease
http.debian.net_debian_dists_sid_main_binary-amd64_Packages
http.debian.net_debian_dists_sid_main_binary-amd64_Packages.IndexDiff
http.debian.net_debian_dists_sid_main_i18n_Translation-en
http.debian.net_debian_dists_sid_main_i18n_Translation-en.IndexDiff
http.debian.net_debian_dists_sid_main_source_Sources
http.debian.net_debian_dists_sid_main_source_Sources.ed.2015-03-29-0250.25.gz
http.debian.net_debian_dists_sid_main_source_Sources.ed.2015-03-29-0849.19.gz
http.debian.net_debian_dists_sid_main_source_Sources.ed.2015-03-29-2048.27.gz
http.debian.net_debian_dists_sid_main_source_Sources.ed.2015-03-30-0247.33.gz
http.debian.net_debian_dists_sid_main_source_Sources.ed.2015-03-30-1447.17.gz
http.debian.net_debian_dists_sid_main_source_Sources.ed.2015-03-30-2049.01.gz
http.debian.net_debian_dists_sid_main_source_Sources.IndexDiff
http.debian.net_debian_dists_sid_non-free_binary-amd64_Packages
http.debian.net_debian_dists_sid_non-free_binary-amd64_Packages.IndexDiff
http.debian.net_debian_dists_sid_non-free_i18n_Translation-en
http.debian.net_debian_dists_sid_non-free_i18n_Translation-en.IndexDiff
http.debian.net_debian_dists_sid_non-free_source_Sources
http.debian.net_debian_dists_sid_non-free_source_Sources.IndexDiff
lock
partial

superwow@grmldeb ~ % ls /var/lib/apt/lists/partial                                                                 v59%
http.debian.net_debian_dists_sid_main_source_Sources.diff_2015-03-30-2049.01.FAILED

superwow@grmldeb ~ % cat /etc/apt/sources.list                                                                     v55%
deb http://http.debian.net/debian sid main contrib non-free
deb-src http://http.debian.net/debian sid main contrib non-free

superwow@grmldeb ~ % apt-cache policy                                                                              v57%
Package files:
100 /var/lib/dpkg/status
     release a=now
500 http://http.debian.net/debian/ sid/non-free Translation-en
500 http://http.debian.net/debian/ sid/main Translation-en
500 http://http.debian.net/debian/ sid/contrib Translation-en
500 http://http.debian.net/debian/ sid/non-free amd64 Packages
     release o=Debian,a=unstable,n=sid,l=Debian,c=non-free
     origin http.debian.net
500 http://http.debian.net/debian/ sid/contrib amd64 Packages
     release o=Debian,a=unstable,n=sid,l=Debian,c=contrib
     origin http.debian.net
500 http://http.debian.net/debian/ sid/main amd64 Packages
     release o=Debian,a=unstable,n=sid,l=Debian,c=main
     origin http.debian.net
Pinned packages:



Is anyone else having problems updating? If not, does anyone have advice on how to fix this upgrade issue (which I am guessing is not uncommon)?

Thanks in advance to all responders!

ozitraveller

My best advice would be to wait.

Looks like the repos are being updated.

Unless someone has a better idea.

jedi

I usually do a 'up' (alias built into VSIDO to do a update && dist-upgrade) about every day.  Just ran it tonight (second time today) and it completed fine.
Here's my sources.list;


jedi@NixNut:~$ cat /etc/apt/sources.list
## Official Debian Repos ##


deb http://ftp.us.debian.org/debian/ sid main non-free contrib
deb-src http://ftp.us.debian.org/debian/ sid main non-free contrib


## Unofficial Repos ##

deb http://ftp.us.debian.org/debian/ experimental main non-free contrib
deb http://www.deb-multimedia.org sid main non-free
deb http://mozilla.debian.net/ experimental iceweasel-aurora
# deb http://oscar.aptosid.com/debian/ sid main fix.main
# deb http://ignorantguru.github.com/debian/ unstable main


jedi@NixNut:~$


Not sure how to tell you to proceed.
Forum Netiquette

"No matter how smart you are you can never convince someone stupid that they are stupid."  Anonymous

PackRat

ozi's advice is usually the way to go.

You can also clean out the cache (/var/cache/apt/ and /var/apt/cache/partial )

sudo apt-get clean all

or

sudo apt-get autoclean


there is also the file /var/apt/cache/lock which might be messing you up; if your problem persists, you may need to delete that file - do a internet search on that file and see if you can get some additional info.
I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

VastOne

Sage advice from all...

I will add that along with the up alias there is also cl (for sudo apt-get autoclean) as RatMan pointed out
VSIDO      VSIDO Change Blog    

    I dev VSIDO

superwow

Thanks all for the advice. I am reporting back here for posterity, since I am sure it will happen again at some future date.

I followed the advice and


sudo apt-get clean all
sudo apt-get autoclean
sudo rm /var/lib/apt/lists/lock
sudo rm -R /var/lib/apt/lists/partial
sudo rm -fr ~/.Trash


but no joy. Again, got the same error message.

I have had trouble with ftp sources in the past failing more commonly than http sources so I did not want to change my sources list. Makes me wonder why there's no tor or vpn'd tor source list. But anyway...

So I went through the process again, repeating the steps above, because I am just a stickler for such details, but apparently not enough of a stickler. Instead of typing "sudo rm -R /var/lib/apt/lists/partial", I typed "sudo rm -R /var/lib/apt/lists" and hit enter. Strangely I saw the command execute in like slow-mo because I thought I had just issued a destruction message to my system. On other forums, the result of such a command killed the apt system. But i decided to try an update anyway. Lo and behold, it worked without hitch. Not sure about the source of the error, or why this happenstance worked.

Must learn more about apt?

Thanks for the advice.