Ubuntu 12.04: Why does apt-get update fail?

1,708

Just remove the content of /var/lib/apt/lists directory:

sudo rm -fR /var/lib/apt/lists/*

then run:

sudo apt-get update

Source: Lorem's answer on Trouble downloading packages list due to a “Hash sum mismatch” error

Share:
1,708
Pei Chuang
Author by

Pei Chuang

Updated on September 18, 2022

Comments

  • Pei Chuang
    Pei Chuang almost 2 years

    i want to make one list split into list of lists, and skip the 'solid' and separate the list into sublist.

    the input and output is below

    split_s([A,B,C,solid,D,E,F],X).
    X = [[A,B,C],[D,E,F]].
    

    Can anyone help me?

    • Anam Ahmed
      Anam Ahmed over 11 years
      I had this problem before, fixed it by changing the protocol to ftp. try a mirror that supports ftp access. and if you are already using ftp, try a http mirror.
    • Peter Hackman
      Peter Hackman over 11 years
      Can you please post me the apt sources list which you have used for it
    • Peter Hackman
      Peter Hackman over 11 years
      I have tried with a changing the mirror to an ftp. but it fails, hope there could be some other work around
    • Admin
      Admin over 11 years
      What modifications have you made to the OS? Your prompt looks a bit "different". Why are you trying to download both i386 and amd64 packages? Where did you get your .iso from?
    • Peter Hackman
      Peter Hackman over 11 years
      apt-get failes due to the issue in wget. wget fails to download files. It downloads the files with 0 bytes. Anyone knows what could be the issue..
    • CapelliC
      CapelliC over 9 years
      try ?- append([X,[solid],Y],[a,b,c,solid,d,e,f]).
    • lurker
      lurker over 9 years
      Please show an attempt at a solution.
  • Frederik Spang
    Frederik Spang about 10 years
    You're very welcome!
  • false
    false over 9 years
    possible duplicate of filter list into separate lists
  • halfbit
    halfbit over 9 years
    @false: Oops thank you, should have seen that. See edit.
  • Pei Chuang
    Pei Chuang over 9 years
    How can i get rid of the empty list in the result? @halfbit
  • Bakuriu
    Bakuriu over 8 years
    You have to properly attribute the answer. You have copy & pasted from here and according to SO license you have to 1) link to the original answer (which you have done) AND 2) attribute the original author with a link to its profile (which is missing).
  • Frederik Spang
    Frederik Spang over 8 years
    Hi Bakuriu - If you actually look at, and read my answer, I have done exactly that.
  • Scott Stensland
    Scott Stensland about 8 years
    this suggestion fails to help at all