apt-get unable to parse status file
I installed a package via dpkg, and now when I try to use apt-get/apt-cache I get the error: > root@g [/var/lib/dpkg]# apt-get autoclean
Reading Package Lists… Error!
E: Unable to parse package file /var/lib/dpkg/status (1)
E: The package lists or status file could not be parsed or opened.
This error occurs with any apt-get or apt-cache command that I've tried.
I've tried rebooting my linode, no luck. I also tried swapping status and status-old, still no luck. I've been searching around but haven't found a solution to this issue. Any ideas?
8 Replies
> root@g [/var/lib/dpkg]# apt-get update
Hit
http://mirrors.kernel.org stable/main PackagesHit
http://mirrors.kernel.org stable/main ReleaseHit
http://mirrors.kernel.org stable/contrib PackagesHit
http://mirrors.kernel.org stable/contrib ReleaseHit
http://mirrors.kernel.org stable/non-free PackagesHit
http://mirrors.kernel.org stable/non-free ReleaseHit
http://mirrors.kernel.org stable/main SourcesHit
http://mirrors.kernel.org stable/main ReleaseHit
http://mirrors.kernel.org stable/contrib SourcesHit
http://mirrors.kernel.org stable/contrib ReleaseHit
http://mirrors.kernel.org stable/non-free SourcesHit
http://mirrors.kernel.org stable/non-free ReleaseHit
http://security.debian.org stable/updates/main PackagesHit
http://security.debian.org stable/updates/main ReleaseHit
http://security.debian.org stable/updates/contrib PackagesHit
http://security.debian.org stable/updates/contrib ReleaseHit
http://security.debian.org stable/updates/non-free PackagesHit
http://security.debian.org stable/updates/non-free ReleaseReading Package Lists… Error!
E: Unable to parse package file /var/lib/dpkg/status (1)
E: The package lists or status file could not be parsed or opened.
if that doesn't work, i think you're pretty much SOL.
Where did you get the .deb you installed with dpkg?
@OverlordQ:
http://www.debian.org/doc/manuals/refer … #s-recover">http://www.debian.org/doc/manuals/reference/ch-package.en.html#s-recover if that doesn't work, i think you're pretty much SOL.
Where did you get the .deb you installed with dpkg?
s-recover does not seem to be a valid section. Do you have the numbered section that link refers to?
As far as the deb, it was built from an rpm using alien. Could be part of the problem, but imho it shouldn't cause a failure such as this. But I do accept that this could just be a situation where playing with fire can cause issues
Now for the shameless plug: The package was the Kerio MailServer, for whom which I work for (Technical Support Engineer). At the current time we do not support Debian, we only provide rpm packages on the Linux side, although I managed to get it working on my Debian system by using alien and building a custom init script
If you could post that status file (the 'corrupted' one) or even the .deb I could probably tell you why it's not working, there's a certain bug i'm thinking that's causing this.
@OverlordQ:
http://www.debian.org/doc/manuals/refer … ver-status">http://www.debian.org/doc/manuals/reference/ch-package.en.html#s-recover-status If you could post that status file (the 'corrupted' one) or even the .deb I could probably tell you why it's not working, there's a certain bug i'm thinking that's causing this.
Looks like we can't attach files to our posts here, so I have tar'ed up the bad status file, and the one I'm currently using, which was copied from /var/backups/dpkg.status (so that you can do a diff on them if you want which should list what changed)
If you end up needing the deb, let me know.