How do I fix a "Problem with MergeList" or "status file could not be parsed" error when trying to do an update?
These terminal commands should solve your problem:
First remove the Merge List by opening a terminal (Press Ctrl+Alt+T to launch) and run this command*:
sudo rm -vf /var/lib/apt/lists/*
Next, generate a new one by running a simple update:
sudo apt-get update
Here is the bug report (and another) for this problem, which is now fixed so it shouldn't create new malformed files, however if you already have the malformed files you need to remove them as explained in this post.
*The options used for rm are -v
verbose
-v, --verbose explain what is being done
and -f
force
-f, --force ignore nonexistent files and arguments, never prompt
If you are ever unsure about a command line or the options being used always refer to the manual page for the command. These can be accessed on the internet by searching for man and the command for example man rm
or you can access the same information by typing exactly the same command in the terminal for example man rm
instructions for quitting the page will be at the bottom of the terminal like this
Open a Terminal and run the following commands one at a time:
sudo rm /var/lib/apt/lists/* -vf
sudo apt-get update
See also:
- https://help.ubuntu.com/community/PackageManagerTroubleshootingProcedure
You screwed up when you edited /var/lib/dpkg/status
. Restore it from the backup that you made before editing it. Of course, you made a backup, right?
Since you didn't make a backup, edit it again, carefully. Try not to cause more damage.
You can use /var/lib/dpkg/status.old
as a reference point. This is a backup of the status
file from before the last time dpkg
was run. Run
diff /var/lib/dpkg/status.old /var/lib/dpkg/status
to see the differences. Undo the changes that you made manually, and keep the changes that were made by the last dpkg
run.
If you really can't manage to repair the file, copy /var/lib/dpkg/status.old
over /var/lib/dpkg/status
. You will get a well-formed, but out-of-date package database.
You never need to edit /var/lib/dpkg/status
in normal operation. Even whe things go seriously wrong, /var/lib/dpkg/status
is not something that tends to require administrator intervention. Whatever your problems with crossplatformui
were, there is probably a better way of solving them. The only time I've ever needed to edit /var/lib/dpkg/status
was when an upstream Packages
file was broken.