Ubuntu错误提示 E: Could not open lock file /var/lib/dpkg/lock-frontend - open

一、Ubuntu错误提示内容

1. E: Could not open lock file /var/lib/dpkg/lock-frontend - open (13: Permission denied)

2. E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), are you root?

二、解决方案

1. sudo rm /var/lib/dpkg/lock-frontend

2. sudo rm /var/lib/dpkg/lock

3. sudo apt install p7zip-full

三、错误提示1

book@100ask:~$ 7z x 100ask_imx6ull-sdk.7z.001

Command '7z' not found, but can be installed with:

apt install p7zip-full
Please ask your administrator.

在这里插入图片描述

四、错误提示2

book@100ask:~$ apt install p7zip-full
E: Could not open lock file /var/lib/dpkg/lock-frontend - open (13: Permission denied)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), are you root?
book@100ask:~$ sudo apt install p7zip-full
E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?

在这里插入图片描述

五、错误提示3

book@100ask:~$ sudo apt-get install p7zip
E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?
book@100ask:~$ sudo apt-get install p7zip-rar
E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?
book@100ask:~$ sudo apt-get install -f
E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?

在这里插入图片描述

六、解决方案1

book@100ask:~$ sudo rm /var/lib/dpkg/lock-frontend
book@100ask:~$ sudo rm /var/lib/dpkg/lock

在这里插入图片描述

七、解决方案2

book@100ask:~$ sudo apt-get install p7zip
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Suggested packages:
  p7zip-full
The following NEW packages will be installed:
  p7zip
0 upgraded, 1 newly installed, 0 to remove and 496 not upgraded.
Need to get 358 kB of archives.
After this operation, 996 kB of additional disk space will be used.
Get:1 http://us.archive.ubuntu.com/ubuntu bionic/universe amd64 p7zip amd64 16.02+dfsg-6 [358 kB]
Fetched 358 kB in 8s (43.4 kB/s)                                                                                                                                                                 
Selecting previously unselected package p7zip.
(Reading database ... 133321 files and directories currently installed.)
Preparing to unpack .../p7zip_16.02+dfsg-6_amd64.deb ...
Unpacking p7zip (16.02+dfsg-6) ...
Setting up p7zip (16.02+dfsg-6) ...
Processing triggers for man-db (2.8.3-2ubuntu0.1) ...
book@100ask:~$ 

在这里插入图片描述

八、解决方案3

book@100ask:~$ sudo apt install p7zip-full
[sudo] password for book: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Suggested packages:
  p7zip-rar
The following NEW packages will be installed:
  p7zip-full
0 upgraded, 1 newly installed, 0 to remove and 496 not upgraded.
Need to get 1,164 kB of archives.
After this operation, 4,759 kB of additional disk space will be used.
Get:1 http://us.archive.ubuntu.com/ubuntu bionic/universe amd64 p7zip-full amd64 16.02+dfsg-6 [1,164 kB]
15% [1 p7zip-full 222 kB/1,164 kB 19%]                       11.4 kB/s 1min 22s^Get:1 http://us.archive.ubuntu.com/ubuntu bionic/universe amd64 p7zip-full amd64 16.02+dfsg-6 [1,164 kB]
Fetched 3,045 B in 1min 48s (28 B/s)     
Selecting previously unselected package p7zip-full.
(Reading database ... 133332 files and directories currently installed.)
Preparing to unpack .../p7zip-full_16.02+dfsg-6_amd64.deb ...
Unpacking p7zip-full (16.02+dfsg-6) ...
Setting up p7zip-full (16.02+dfsg-6) ...
Processing triggers for man-db (2.8.3-2ubuntu0.1) ...

在这里插入图片描述

九、完美解决

book@100ask:~$ 7z x 100ask_imx6ull-sdk.7z.001

7-Zip [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21
p7zip Version 16.02 (locale=en_US.UTF-8,Utf16=on,HugeFiles=on,64 bits,2 CPUs Intel(R) Core(TM) i5-7400 CPU @ 3.00GHz (906E9),ASM,AES-NI)

Scanning the drive for archives:
1 file, 3145728000 bytes (3000 MiB)

Extracting archive: 100ask_imx6ull-sdk.7z.001
--         
Path = 100ask_imx6ull-sdk.7z.001
Type = Split
Physical Size = 3145728000
Volumes = 2
Total Physical Size = 4681729787
----
Path = 100ask_imx6ull-sdk.7z
Size = 4681729787

在这里插入图片描述
在这里插入图片描述

  • 6
    点赞
  • 27
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
这个问题可能是由于其他进程正在使用dpkg前端锁(/var/lib/dpkg/lock-frontend)导致的。为了解决这个问题,你可以尝试以下几种方法: 1. 确保你有root权限。在终端中使用sudo命令来执行命令,例如:sudo apt install p7zip-full。 2. 如果提示“Permission denied”,可能是由于你没有足够的权限来访问锁文件。你可以尝试使用chmod命令来更改锁文件的权限,例如:sudo chmod 777 /var/lib/dpkg/lock-frontend。 3. 如果提示“Resource temporarily unavailable”,可能是因为另一个进程正在使用锁文件。你可以尝试等待一段时间后再次执行命令,或者重启你的计算机。 4. 如果以上方法仍然无效,你可以尝试手动创建缺失的文件夹和复制缺失的文件。可以使用以下命令: sudo mkdir -p /var/lib/dpkg/{alternatives,info,parts,triggers,updates} sudo cp /var/backups/dpkg.status.0 /var/lib/dpkg/status 5. 最后,你可以尝试更新你的软件包列表和检查软件包依赖关系,以确保系统的完整性。使用以下命令: sudo apt-get update sudo apt-get check 希望这些方法可以帮助你解决问题。如果问题仍然存在,请尝试在技术支持论坛或者联系相关技术支持人员寻求进一步的帮助。<span class="em">1</span><span class="em">2</span><span class="em">3</span> #### 引用[.reference_title] - *1* *3* [Ubuntu错误提示 E: Could not open lock file /var/lib/dpkg/lock-frontend - open](https://blog.csdn.net/Ceosat/article/details/104730674)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT3_1"}}] [.reference_item style="max-width: 50%"] - *2* [无法打开锁定文件/var/lib/dpkg/lock-frontened 解决方案,亲测有效](https://blog.csdn.net/weixin_44273408/article/details/120039807)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT3_1"}}] [.reference_item style="max-width: 50%"] [ .reference_list ]
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值