Score:0

dpkg problem lock file

cn flag
DDS

While installing a package I have got a dpkg error. When I try to:

       sudo dpkg --configure -a: 
       dpkg: error: unable to access the dpkg database directory /var/lib/dpkg: Read-only file system
       sudo rm /var/lib/dpkg/lock    
       cannot remove '/var/lib/dpkg/lock': Read-only file system     
       sudo chmod +w /var/lib/dpkg/lock
       chmod: changing permissions of '/var/lib/dpkg/lock': Read-only file system

The problem is that anytime I try to use a fsck, ps, gedit I get:

       -bash: /usr/bin/ps: Input/output error
        

I am using WSL2 with Ubuntu 22.04. pls save me from the evil

uz flag
Jos
Please use the `mount` command to verify that your root file system is mounted read-only. If so, try to remount it read-write.
Raffa avatar
jp flag
It’s most likely certainly not a `dpkg` lock file issue … The issue appears to be that your root filesystem is mounted read-only which prevents your applications from doing their required file-writing operations … Remounting your root filesystem read and write should resolve that.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.