首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >E:执行脚本问题APT::用Docker更新错误

E:执行脚本问题APT::用Docker更新错误
EN

Ask Ubuntu用户
提问于 2022-07-28 00:13:00
回答 1查看 1.5K关注 0票数 2

试图构建以下对接者映像:

代码语言:javascript
复制
FROM ubuntu:22.04

RUN apt-get update
...

使用以下命令:

代码语言:javascript
复制
sudo docker build -t ubuntu22 .

但得到了:

代码语言:javascript
复制
Fetched 22.0 MB in 2s (11.8 MB/s)
Reading package lists...
E: Problem executing scripts APT::Update::Post-Invoke 'rm -f /var/cache/apt/archives/*.deb /var/cache/apt/archives/partial/*.deb /var/cache/apt/*.bin || true'
E: Sub-process returned an error code
The command '/bin/sh -c apt-get update' returned a non-zero code: 100

有什么不对的?

EN

回答 1

Ask Ubuntu用户

发布于 2022-08-04 04:59:35

我也有同样的问题。我使用FROM ubuntu:21.10,但生成结果

代码语言:javascript
复制
Ign:1 http://archive.ubuntu.com/ubuntu impish InRelease
Ign:2 http://security.ubuntu.com/ubuntu impish-security InRelease
Ign:3 http://archive.ubuntu.com/ubuntu impish-updates InRelease
Err:4 http://security.ubuntu.com/ubuntu impish-security Release
  404  Not Found [IP: ***]
Ign:5 http://archive.ubuntu.com/ubuntu impish-backports InRelease
Err:6 http://archive.ubuntu.com/ubuntu impish Release
  404  Not Found [IP: ***]
Err:7 http://archive.ubuntu.com/ubuntu impish-updates Release
  404  Not Found [IP: ***]
Err:8 http://archive.ubuntu.com/ubuntu impish-backports Release
  404  Not Found [IP: ***]
Reading package lists...
E: The repository 'http://security.ubuntu.com/ubuntu impish-security Release' does not have a Release file.
E: The repository 'http://archive.ubuntu.com/ubuntu impish Release' does not have a Release file.
E: The repository 'http://archive.ubuntu.com/ubuntu impish-updates Release' does not have a Release file.
E: The repository 'http://archive.ubuntu.com/ubuntu impish-backports Release' does not have a Release file.

"Ubuntu 21.10 ( Indri)生命的终结于2022年7月14日达成“。

然后,我将21.10改为22.04并运行build (在apt-get更新之后)

代码语言:javascript
复制
Reading package lists...
E: Problem executing scripts APT::Update::Post-Invoke 'rm -f /var/cache/apt/archives/*.deb /var/cache/apt/archives/partial/*.deb /var/cache/apt/*.bin || true'
E: Sub-process returned an error code

编辑:然后我更改了以前的LTS版本(从ubuntu:20.04),一切都正常。

票数 1
EN
页面原文内容由Ask Ubuntu提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://askubuntu.com/questions/1420759

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档