![尝试更新 Kubuntu 20.04 时出现权限被拒绝错误](https://linux22.com/image/926060/%E5%B0%9D%E8%AF%95%E6%9B%B4%E6%96%B0%20Kubuntu%2020.04%20%E6%97%B6%E5%87%BA%E7%8E%B0%E6%9D%83%E9%99%90%E8%A2%AB%E6%8B%92%E7%BB%9D%E9%94%99%E8%AF%AF.png)
Reading package lists... Done
E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied)
E: Unable to lock directory /var/lib/apt/lists/
W: Problem unlinking the file /var/cache/apt/pkgcache.bin - RemoveCaches (13: Permission denied)
W: Problem unlinking the file /var/cache/apt/srcpkgcache.bin - RemoveCaches (13: Permission denied)
答案1
喜欢Parsa Mousavi 说,看来您没有管理员权限。请尝试以您在安装时创建的默认用户身份运行它(如果您尚未使用该用户身份),然后使用sudo
:
sudo apt update && sudo apt upgrade
我猜你做的apt update
不是sudo apt update
。
如果命令输出Permission Denied
,请尝试在其前添加sudo
。