dpkg: error: parsing file ‘/var/lib/dpkg/available’ near line 0

Just trying to upgrade the server (sudo apt-get upgrade) and it says:

dpkg: error: parsing file ‘/var/lib/dpkg/available’ near line 0

Turns out that /var/lib/dpkg/available is broken.  To fix just run:

sudo dpkg –clear-avail

Then get the latest updates:

sudo apt-get update

One thought on “dpkg: error: parsing file ‘/var/lib/dpkg/available’ near line 0

Leave a Reply