![dpkg 问题锁定文件](https://linux22.com/image/952749/dpkg%20%E9%97%AE%E9%A2%98%E9%94%81%E5%AE%9A%E6%96%87%E4%BB%B6.png)
安装软件包时,我遇到了 dpkg 错误。当我尝试:
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
问题是,每当我尝试使用 fsck、ps、gedit 时,我都会得到:
-bash: /usr/bin/ps: Input/output error
我正在使用 WSL2 和 Ubuntu 22.04。请拯救我免于邪恶