Cannot Install vim with apt-get

Jorge Castro suggested: "you can use deb mirror to have the best mirror picked for you automatically.

apt-get now supports a 'mirror' method that will automatically select a good mirror based on your location. Putting:

deb mirror://mirrors.ubuntu.com/mirrors.txt precise main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt precise-updates main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt precise-backports main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt precise-security main restricted universe multiverse

IT WORKED FOR ME! I added the above lines in

/etc/apt/sources.list

at the top and then I

sudo apt-get update

and then

sudo apt-get install vim

WORKS!


From browsing around http://pk.archive.ubuntu.com/ubuntu/ it seems that the mirror you are using is out of date. You should try changing your mirror to something different, that should then fix the error:

  • How can I get apt to use a mirror close to me, or choose a faster mirror?
  • How do you select the fastest mirror from the command line?