Quick Fix for the ‘Size Mismatch’ When Updating Ubuntu Linux

This is just a short “quick fix” post.

For those who need it, here’s a quick fix when you get an error message like this:

“W: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/f/ffmpeg/libpostproc1d_0.cvs20070307-5ubuntu7.2_amd64.deb Size mismatch”

It’s an error I received when the auto update feature was working in Ubuntu Linux. I double checked my sources.list file, but it was okay.

After a bit of tinkering, here’s how to fix that.

Open a terminal and enter the following command:

sudo aptitude  clean

And then:

sudo aptitude update

After this the updates re-downloaded and everything worked. If you prefer “apt-get” you can substitute it in place of the “aptitude” command.

The logic behind this was that perhaps the downloaded files themselves, were corrupt. If they are already in the local repository, they will not download again. Hence the “clean” option. “Clean” empties the local repository of downloaded packages (but it does not delete the lock file). Using the clean option occasionally can be helpful in conserving disk space.

The second command that featured the “update” option, resynchronized the package files from their sources. This means that the .gz files (at the source) were scanned for new and updated information – if any is available. When making changes to the sources.list file, this command (update) should be run before doing any upgrading.

Hope this helps some of you out there! :)

This entry was posted in How To and tagged , , , , , , , , . Bookmark the permalink.

2 Responses to Quick Fix for the ‘Size Mismatch’ When Updating Ubuntu Linux

  1. Pingback: HowtoMatrix » Quick Fix for the ‘Size Mismatch’ When Updating Ubuntu Linux

  2. def says:

    it works thank you

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>