Unable to install any package

Archived topics about LMDE 1 and LMDE 2
Locked
suryadharani

Unable to install any package

Post by suryadharani »

when i try to install ANY application through terminal, i get this error
"""
Reading package lists... Error!
E: Read error - read (21: Is a directory)
E: The package lists or status file could not be parsed or opened.
"""


And software center is also not opening.
Neither synaptic manager. It gives the following error when i try to optn it.
"""
E: Read error - read (21: Is a directory)
E: The package lists or status file could not be parsed or opened.
E: _cache->open() failed, please report.
"""
---Solutions i tried so far-(even they dint work out :( )
1>
sudo rm -rf /var/lib/apt/lists/archive.ubuntu.com_ubuntu_dists_precise_restricted_binary-amd64_Packages
sudo apt-get update
2>
sudo rm -rf /var/lib/apt/lists/*
sudo apt-get update
3>
Frinds, please come with your suggestions.
Am in a kind of hell, not in a position to use the "apt-get install" even..
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
kc1di
Level 18
Level 18
Posts: 8178
Joined: Mon Sep 08, 2008 8:44 pm
Location: Maine USA

Re: Unable to install any package

Post by kc1di »

Hello and welcome to Mint,

go to a terminal and type the following commands and see if it will allow you to install programs.

Code: Select all

sudo rm /var/lib/apt/lists/* -vf
sudo apt-get update
good luck,
dave
Easy tips : https://easylinuxtipsproject.blogspot.com/ Pjotr's Great Linux projects page.
Linux Mint Installation Guide: http://linuxmint-installation-guide.rea ... en/latest/
Registered Linux User #462608
viking777

Re: Unable to install any package

Post by viking777 »

The error says it is having problems with either lists or status. As you have already removed lists and it made no difference, that leaves us with 'status'.

If I run the command

Code: Select all

ls /var/lib/dpkg/
alternatives/  available-old  diversions-old  parts/        status-old
arch           cmethopt       info/           statoverride  triggers/
available      diversions     lock            status        updates/
You will see that I have a file called status and another called status-old. If you have the same I would do this:

Code: Select all

sudo mv /var/lib/dpkg/status  /var/lib/dpkg/status.broken
Followed by

Code: Select all

sudo mv /var/lib/dpkg/status-old  /var/lib/dpkg/status
finally run

Code: Select all

sudo dpkg --configure -a
And see if it works now.
Locked

Return to “LMDE Archive”