programing

Ubuntu에서 apt-get 업데이트를 실행할 때 Docker Repository에 릴리스 파일이 없음

lastcode 2023. 8. 20. 11:12
반응형

Ubuntu에서 apt-get 업데이트를 실행할 때 Docker Repository에 릴리스 파일이 없음

Ubuntu 16.10을 사용하고 있으며 최근에 Xenial 빌드를 사용하여 Docker(v1.12.4)를 설치했습니다.컨테이너를 만들거나 컨테이너가 자동으로 다시 시작되는지 확인하는 등의 문제는 발생하지 않았습니다.

그러나 이제 apt-get update를 실행할 때마다 다음과 같은 오류 메시지가 표시됩니다.

W: The repository 'https://apt.dockerproject.org/repo ubuntu-xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch https://apt.dockerproject.org/repo/dists/ubuntu-xenial/main/binary-amd64/Packages
E: Some index files failed to download. They have been ignored, or old ones used instead.

저는 여기서 발견된 조언을 따라 문제를 해결하려고 노력했지만 이 문제를 해결할 수 없는 것 같습니다.

전에 이 문제를 해결한 적이 있는 사람이 문제를 해결한 적이 있습니까?그렇다면 이 문제를 해결하기 위해 무엇이 필요합니까?

Linux Mint에서는 공식적인 지침이 저에게 효과가 없었습니다.안으로 들어가야 했어요./etc/apt/sources.list.d/additional-repositories.list 변경 그고변화리serenaxenial내 우분투 코드 이름을 반영하기 위해.데비안 버전, 버전 및 이후의 원래 설치 방법에 따라 수정해야 할 수도 있습니다./etc/apt/sources.list.d/docker.list대신.

일반적으로 몇 가지 명령 중 하나를 실행하여 적절한 코드 이름을 찾을 수 있습니다.다음 예제에서는focal " 드코이니다입름는"입니다.

$ grep CODENAME /etc/os-release
VERSION_CODENAME=focal
UBUNTU_CODENAME=focal

$ lsb_release -c
Codename:   focal

# NOTE: On Ubuntu 20.04.2, /etc/os-release is symlinked to /usr/lib/os-release and
#       lsb_release reads from /usr/lib/os-release.

Linux Mint의 경우 이 문제는 실제로 Docker 웹 사이트에서 참조할 수 있습니다.

참고: Thelsb_release -cs은 Ubuntu합니다. 를 들어 Ubuntu 배포의 을 반환합니다.xenialMint와 Mint를 변경해야 경우가.$(lsb_release -cs)상위 Ubuntu 배포로 이동합니다.예를 들어 Linux Mint Rafaela를 사용하는 경우 trusty를 사용할 수 있습니다.

amd64:

$ sudo add-apt-repository \
"deb [arch=amd64] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) \
stable"

lsb_release -cs명령은 Docker에 준비된 패키지가 없는 리포지토리를 제공하므로 이를 xenial로 변경해야 합니다.

Ubuntu 16.04 Xenial을 기반으로 하는 Linux Mint 18에 대한 올바른 명령은 다음과 같습니다.

sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
   xenial \
   stable"

엘리엇 비치가 맞습니다.감사합니다 엘리엇.

여기 제 요지의 코드가 있습니다.

sudo apt-get remove docker docker-engine docker.io

sudo apt-get update

sudo apt-get install apt-transport-https ca-certificates curl software-properties-common

curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -

sudo apt-key fingerprint 0EBFCD88

sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
xenial \
stable"

sudo apt-get update

sudo apt-get install docker-ce

sudo docker run hello-world

공식 도커 문서에서도 제안된 바와 같이.실행해 보십시오.

  • sudo vi /etc/apt/sources.list

그런 다음 아무 것이나 제거/설명합니다(deb [arch=amd64] https://download.docker.com/linux/ubuntu/ xenial stable파일의 마지막 줄에 해당 항목이 표시됩니다.

그런 다음 터미널에서 다음 명령을 실행합니다.

  • sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu/ bionic stable"

  • sudo apt-get update

제 경우에는 효과가 있었습니다.

리눅스 민트 20 울리아나 사용자는 에서 "울리아나""바이오닉"으로 변경해야 합니다.

/etc/apt/sources.list.d/additional-repositories.list

이와 같이:

deb [arch=amd64] https://download.docker.com/linux/ubuntu    bionic    stable

는 여기서 Ikraider가 제 문제를 해결해 준 흥미로운 게시물을 보았습니다: https://github.com/docker/docker/issues/22599 .

웹 사이트 지침이 잘못되었습니다. 16.04에서 작동하는 내용은 다음과 같습니다.

curl -s https://yum.dockerproject.org/gpg | sudo apt-key add
apt-key fingerprint 58118E89F3A912897C070ADBF76221572C52609D
sudo add-apt-repository "deb https://apt.dockerproject.org/repo ubuntu-$(lsb_release -cs) main"
sudo apt-get update
sudo apt-get install docker-engine=1.13.0-0~ubuntu-xenial

오래된 게시물이지만, 어제도 비슷한 문제에 부딪혔습니다.Docker 자체 웹 사이트의 지침이 제대로 작동하지 않아 설치 오류가 많이 발생했습니다. (단말기 출력에서 문제가 되는 일부 행 아래)

Get:6 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
Err:7 https://download.docker.com/linux/debian focal Release
  404  Not Found [IP: 13.227.219.37 443]
Reading package lists... Done                            
E: The repository 'https://download.docker.com/linux/debian focal Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
root@<my-server-name>:~# sudo apt-get install docker-ce docker-ce-cli containerd.io docker-compose-plugin
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package docker-ce is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'docker-ce' has no installation candidate
E: Unable to locate package docker-ce-cli
E: Unable to locate package containerd.io
E: Couldn't find any package by glob 'containerd.io'
E: Couldn't find any package by regex 'containerd.io'
E: Unable to locate package docker-compose-plugin
root@<my-server-name>:~# sudo apt-get upgrade

여러 수정을 검색하고 시도한 결과 #Prashant Abdare에서 제공한 응답이 가장 유용하다는 것을 알게 되었습니다.다음 명령을 실행할 때:

$ cat /etc/debian_version

다음과 같은 출력을 받았습니다.

불스아이/사이드

xed 편집기가 설치되어 있지 않기 때문에 #Prashant Abdare의 명령을 서버 루트의 sudo nano로 바꾸기만 하면 됩니다.

$ sudo nano /etc/apt/sources.list.d/docker.list

다음으로, 저는 단순히 그가 표시한 대로 데비안 버전을 (잘못됨)에서 (잘못됨)에서 (즉,)으로 변경하여 항목을 편집했습니다.

deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian   focal stable

대상(내 시스템에 대해 수정됨):

deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian   bullseye stable

그 후, 저는 다음 명령을 실행했습니다(Docker의 원래 지침에서).

$ sudo apt-get update
$ sudo apt-get install docker-ce docker-ce-cli containerd.io docker-compose-plugin

이번에는 설치 작업이 순조롭게 진행되어 이전 문제(위에 붙여넣은 터미널 출력 라인에서)가 해결되어 버전 20.10.17로 업데이트되었습니다.

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  bridge-utils dns-root-data dnsmasq-base libidn11 ubuntu-fan
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  docker-ce-rootless-extras docker-scan-plugin slirp4netns
Suggested packages:
  aufs-tools cgroupfs-mount | cgroup-lite
The following packages will be REMOVED:
  containerd docker.io runc
The following NEW packages will be installed:
  containerd.io docker-ce docker-ce-cli docker-ce-rootless-extras docker-compose-plugin docker-scan-plugin slirp4netns
0 upgraded, 7 newly installed, 3 to remove and 0 not upgraded.
Need to get 108 MB of archives.
After this operation, 115 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://mirrors.digitalocean.com/ubuntu focal/universe amd64 slirp4netns amd64 0.4.3-1 [74.3 kB]
Get:2 https://download.docker.com/linux/debian bullseye/stable amd64 containerd.io amd64 1.6.7-1 [28.1 MB]
Get:3 https://download.docker.com/linux/debian bullseye/stable amd64 docker-ce-cli amd64 5:20.10.17~3-0~debian-bullseye [40.6 MB]
Get:4 https://download.docker.com/linux/debian bullseye/stable amd64 docker-ce amd64 5:20.10.17~3-0~debian-bullseye [21.0 MB]
Get:5 https://download.docker.com/linux/debian bullseye/stable amd64 docker-ce-rootless-extras amd64 5:20.10.17~3-0~debian-bullseye[8159 kB]
Get:6 https://download.docker.com/linux/debian bullseye/stable amd64 docker-compose-plugin amd64 2.6.0~debian-bullseye [6562 kB]
Get:7 https://download.docker.com/linux/debian bullseye/stable amd64 docker-scan-plugin amd64 0.17.0~debian-bullseye [3520 kB]
Fetched 108 MB in 2s (44.9 MB/s)         
(Reading database ... 95602 files and directories currently installed.)
Removing docker.io (20.10.12-0ubuntu2~20.04.1) ...
'/usr/share/docker.io/contrib/nuke-graph-directory.sh' -> '/var/lib/docker/nuke-graph-directory.sh'
Removing containerd (1.5.9-0ubuntu1~20.04.4) ...
Removing runc (1.1.0-0ubuntu1~20.04.1) ...
Selecting previously unselected package containerd.io.
(Reading database ... 95340 files and directories currently installed.)
Preparing to unpack .../0-containerd.io_1.6.7-1_amd64.deb ...
Unpacking containerd.io (1.6.7-1) ...
Selecting previously unselected package docker-ce-cli.
Preparing to unpack .../1-docker-ce-cli_5%3a20.10.17~3-0~debian-bullseye_amd64.deb ...
Unpacking docker-ce-cli (5:20.10.17~3-0~debian-bullseye) ...
Selecting previously unselected package docker-ce.
Preparing to unpack .../2-docker-ce_5%3a20.10.17~3-0~debian-bullseye_amd64.deb ...
Unpacking docker-ce (5:20.10.17~3-0~debian-bullseye) ...
Selecting previously unselected package docker-ce-rootless-extras.
Preparing to unpack .../3-docker-ce-rootless-extras_5%3a20.10.17~3-0~debian-bullseye_amd64.deb...
Unpacking docker-ce-rootless-extras (5:20.10.17~3-0~debian-bullseye) ...
Selecting previously unselected package docker-compose-plugin.
Preparing to unpack .../4-docker-compose-plugin_2.6.0~debian-bullseye_amd64.deb ...
Unpacking docker-compose-plugin (2.6.0~debian-bullseye) ...
Selecting previously unselected package docker-scan-plugin.
Preparing to unpack .../5-docker-scan-plugin_0.17.0~debian-bullseye_amd64.deb ...
Unpacking docker-scan-plugin (0.17.0~debian-bullseye) ...
Selecting previously unselected package slirp4netns.
Preparing to unpack .../6-slirp4netns_0.4.3-1_amd64.deb ...
Unpacking slirp4netns (0.4.3-1) ...
Setting up slirp4netns (0.4.3-1) ...
Setting up docker-scan-plugin (0.17.0~debian-bullseye) ...
Setting up containerd.io (1.6.7-1) ...
Setting up docker-compose-plugin (2.6.0~debian-bullseye) ...
Setting up docker-ce-cli (5:20.10.17~3-0~debian-bullseye) ...
Setting up docker-ce-rootless-extras (5:20.10.17~3-0~debian-bullseye) ...
Setting up docker-ce (5:20.10.17~3-0~debian-bullseye) ...
Processing triggers for man-db (2.9.1-1) ...
Processing triggers for systemd (245.4-4ubuntu3.17) ...
root@<my-server-name>:~# sudo nano /etc/apt/sources.list.d/docker.list
root@<my-server-name>:~# docker --version
Docker version 20.10.17, build 100c701
root@<my-server-name>:~# hostnamectl

따라서 이 솔루션을 공유해 주신 @Prashant Abdare와 최근 편집한 @Deep Kakkar에게 다시 한 번 감사드립니다.

리눅스 민트에서 비슷한 문제에 직면하고 있었는데, 제가 한 일은 데비안 버전을 사용하는 것으로 밝혀졌습니다.

$ cat /etc/debian_version buster/sid

그리고 나서 데비안 버전을 대체했습니다.

$ sudo vi /etc/apt/sources.list.d/additional-repositories.list
deb [arch=amd64] https://download.docker.com/linux/debian    buster    stable

저는 쿠분투 20.04를 사용합니다.내가 만약에cat /etc/os-release알겠습니다.

VERSION="22.04.1 LTS (Jammy Jellyfish)"
VERSION_CODENAME=jammy

, 제 하만서에, 내파일이 있습니다./etc/apt/sources.list.d/docker.list나는 다음과 같은 대사를 했습니다.

deb [arch=amd64 signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian jammy stable

해결책은 변화하는 것이었습니다.debianubuntu효과가 있었습니다.

저도 비슷한 문제가 있었습니다.누군가는 나에게 도움이 되는 것을 발견할지도 모릅니다.

시스템에서 Ubuntu 16.04를 실행하고 있으며 Docker CE가 있습니다.여기에 제공된 답변과 링크, 특히 엘리엇 비치가 제공한 도커 웹사이트의 링크를 살펴본 후, 저는 제 /etc/apt/sources.list를 열고 검토했습니다.

그 파일은 둘 다 있었습니다.deb [arch=amd64] https://download.docker.com/linux/ubuntu (lsb_release -cs) stable그리고.deb [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable.

두 번째 것이 필요했기 때문에 첫 번째 것을 언급하고 문서를 저장하여 문제가 해결되었습니다.테스트를 위해 같은 문서로 돌아가서 댓글 표시를 지우고 실행했습니다.sudo apt-get update다시. 제가 그 일을 했을 때 이슈가 돌아왔습니다.

요약하자면, 저는 도커 웹사이트에 명시된 것처럼 부모님의 Ubuntu 배포 이름을 가지고 있었을 뿐만 아니라 (lsb_release-cs)를 포함하고 있는 줄에 대해서도 언급했습니다.

리눅스 민트 20.3 시나몬의 경우 다음 과정이 저에게 효과가 있었습니다.

데비안 버전 확인 중:

$ cat /etc/debian_version 
bullseye/sid

그런 다음 파일 인덱스 편집기 열기

sudo xed /etc/apt/sources.list.d/docker.list

버전을 uma에서 bulseye로 업데이트합니다.

/etc/apt/sources.list.d/additional-repositories.list 데브 [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable제게 도움이 되었습니다. 이 게시물은 매우 도움이 되었습니다. https://github.com/typora/typora-issues/issues/2065

저는 여전히 같은 문제를 가지고 있습니다.위의 답변 중 어느 것도 그것을 해결하지 못하는 것 같습니다.Ubuntu 16.04를 사용하고 있으며 https://docs.docker.com/install/linux/docker-ce/ubuntu/ 에 설명된 단계를 따릅니다.

나는 그것이 그것과 관련이 있다고 의심합니다.apt-gethttps에 대한 버그입니다.에 의해 입니다.apt-get오해의 소지가 있습니다.

나는 생각합니다.Failed to fetch..다음과 번역될 도 있습니다.problem accessing resource from within an https connection

어떻게 이런 결론에 도달했을까요?

우선 회사 프록시를 지원하기 때문에 다음 구성을 설정했습니다.

/etc/apt/apt.conf

Acquire::http::proxy "http://squidproxy:8080/";
Acquire::https::proxy "http://squidproxy:8080/";
Acquire::ftp::proxy "ftp://squidproxy:8080/";

Acquire::https::CaInfo     "/etc/ssl/certs/ca-certificates.pem";

/etc/apt/apt.conf.d/99pps

Acquire::http::Proxy {
    localhost DIRECT;
    localhost:9020 DIRECT;
    localhost:9021 DIRECT;
};

의 다른 항목으로 다음 테스트를 수행했습니다.sources.list

테스트 항목 1:

deb [arch=amd64] https://download.docker.com/linux/ubuntu xenial stable

sudo apt-get update

W: The repository 'https://download.docker.com/linux/ubuntu xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration     details.
E: Failed to fetch     https://download.docker.com/linux/ubuntu/dists/xenial/stable/binary-amd64/Packages  
E: Some index files failed to download. They have been ignored, or old ones used instead.

실패.

테스트 항목 2:

deb [arch=amd64] http://localhost:9020/linux/ubuntu xenial stable

/etc/sys2/sys-enabled/apt-sys.conf

# http to https reverse proxy configuration.
Listen 9020
<VirtualHost *:9020>
SSLProxyEngine On
# pass from squid proxy
ProxyRemote https://download.docker.com/ http://squidproxy:8080
ProxyPass / https://download.docker.com/
ProxyPassReverse / https://download.docker.com/
ErrorLog ${APACHE_LOG_DIR}/apt-proxy-error.log
CustomLog ${APACHE_LOG_DIR}/apt-proxy-access.log combined
</VirtualHost>

sudo apt-get update

Hit:1 ..
Hit:2 ..
  ...                                                              
Hit:7 http://localhost:9020/linux/ubuntu xenial InRelease                
Get:8 ...
Fetched 323 kB in 0s (419 kB/s)
Reading package lists... Done

성공.

테스트 항목 3:

deb [arch=amd64] https://localhost:9021/linux/ubuntu xenial stable

/etc/sys2/sys-enabled/apt-sys.conf

# https to https revere proxy
Listen 9021
<VirtualHost *:9021>
# serve on https
SSLEngine on
SSLCertificateFile      /etc/ssl/certs/ssl-cert-snakeoil.pem
SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key
SSLProxyEngine On
# pass from squid proxy
ProxyRemote https://download.docker.com/ http://squidproxy:8080
ProxyPass / https://download.docker.com/
ProxyPassReverse / https://download.docker.com/
ErrorLog ${APACHE_LOG_DIR}/apt-proxy-error.log
CustomLog ${APACHE_LOG_DIR}/apt-proxy-access.log combined
</VirtualHost>

sudo apt-get update

W: The repository 'https://localhost:9021/linux/ubuntu xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch https://localhost:9021/linux/ubuntu/dists/xenial/stable/binary-amd64/Packages  
E: Some index files failed to download. They have been ignored, or old ones used instead.

실패.


apt-get URL을 지정하는 Failed to fetch 고또한리그.Release은 실제로 실로액수있파일다니에서 수 .browser/wget/curl동일한 프록시 구성을 사용합니다.
▁▁fact은▁the실.apt-gethttp reverse proxy url에서만 작동하며, 이는 https 연결 내에서 리소스에 액세스하는문제가 있음을 의미합니다.
이가 무엇인지는 , 이문무모만지르겠는지엇인가제,만▁i▁is지▁issue▁this.apt-get 더 메시지를 .apt훨씬 덜 장황함).

참고: 와이어쇼킹 케이스 1은 프록시를 보여주었습니다.CONNECTRST가 전송되지 않았지만 파일을 읽을 수 없었습니다.

리눅스 Mint Change 디렉터리

cd /etc/apt/sources.list.d
ls -la

docker.list라는 파일을 찾아서 nano 텍스트 편집기로 편집합니다.

sudo nano docker.list
// or
/etc/apt/sources.list.d/additional-repositories.list

내 경우 리눅스 민트 버전을 교체하십시오. 초점이 맞았습니다. 당신의 경우 바이오닉, 초점, 버스터 등일 수 있습니다.

코드명 참조

lsb_release -a
deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu focal stable

만약 당신이 앵무새 OS나 다른 데비안 베이스 OS를 사용하고 있다면, 당신은 당신의 OS의 데비안 릴리스(bullseye, buster 등)를 사용하기 위해 /etc/apt/sources.list.d/docker.list의 docker.list를 편집해야 합니다.

sudo nano /etc/apt/sources.list.d/docker.list

위의 명령을 실행하면 링크를 다음과 같이 변경할 수 있는 docker.list 파일이 열립니다.

deb [arch=amd64 signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian bullseye stable

불스아이를 당신의 OS 데비안 코드명으로 바꾸고 저장하세요. 다음, 그후에, 뛰요어를 합니다.sudo apt-get update한 번

이것이 LinuxMint 19에서 제게 도움이 된 것입니다.

curl -s https://yum.dockerproject.org/gpg | sudo apt-key add
apt-key fingerprint 58118E89F3A912897C070ADBF76221572C52609D
sudo add-apt-repository "deb https://apt.dockerproject.org/repo ubuntu-$(lsb_release -cs) main"
sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io

나는 리눅스 민트 20.3을 사용합니다.

lsb_release -cs은 " " " 를 반환합니다.unaxenial로 이름을 바꾸는 것은 잘 작동하지 않았지만 바이오닉은 작동했습니다.

deb [arch=amd64 signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu bionic stable

이 문제에 대한 최선의 검사: (프록시를 사용하는 경우), (Ubuntu 18.04에서 실행됨), (다른 Ubuntu에서도 작동됨), (https_filename="https://192.168.0.251:808/의 오류)

  1. 다음 파일 확인:

    #sudo cat /etc/environment :
    http_proxy="http://192.168.0.251:808/"
    https_proxy="http://192.168.0.251:808/"
    ftp_proxy="ftp://192.168.0.251:808/"
    socks_proxy="socks://192.168.0.251:808/"
    #sudo cat /etc/apt/apt.conf :
    Acquire::http::proxy "http://192.168.0.251:808/";
    Acquire::https::proxy "http://192.168.0.251:808/";
    Acquire::ftp::proxy "ftp://192.168.0.251:808/";
    Acquire::socks::proxy "socks://192.168.0.251:808/";
    
  2. 도커 안정적 레포 추가

    #sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" 
    
  3. apt-get 업데이트 실행:

    #sudo apt-get update
    
  4. 도커 CE 확인

    #apt-cache policy docker-ce
    
  5. 도커 설치

    #sudo apt-get install docker-ce
    

언급URL : https://stackoverflow.com/questions/41133455/docker-repository-does-not-have-a-release-file-on-running-apt-get-update-on-ubun

반응형