向 docker 推送/拉取镜像时出现错误:403 Forbidden

2023-12-29


我在用泊坞窗服务器版本:1.10.3安装了 docker 发行版RHEL 7.2
我面临的问题是间歇性的。有时推/拉命令有效,有时会抛出以下错误:

Pulling repository test.a.b.c.com/hello-world
Error: Status 403 trying to pull repository hello-world: "<!DOCTYPE HTML PUBLIC \"-//IETF//DTD HTML 2.0//EN\">\n<html><head>\n<title>403 Forbidden</title>\n</head><body>\n<h1>Forbidden</h1>\n<p>You don't have permission to access /v1/repositories/hello-world/images\non this server.<br />\n</p>\n</body></html>\n"

的输出“sudo 服务 docker 状态" is:

Aug 15 11:04:48 server forward-journal[6535]: time="2016-08-15T11:04:48.866644712+02:00" level=error msg="Handler for POST /v1.22/images/create returned error: invalid reference format"
Aug 15 21:40:05 server forward-journal[6535]: time="2016-08-15T21:40:05.558387849+02:00" level=info msg="{Action=build, LoginUID=4294967295, PID=17431}"
Aug 15 21:40:23 server forward-journal[6535]: time="2016-08-15T21:40:23.346912366+02:00" level=info msg="{Action=push, LoginUID=4294967295, PID=17452}"
Aug 15 21:40:23 server forward-journal[6535]: time="2016-08-15T21:40:23.426768722+02:00" level=error msg="Upload failed: Error parsing HTTP response: unexpected end of JSON input: \"\""
Aug 15 21:40:23 server forward-journal[6535]: time="2016-08-15T21:40:23.428789638+02:00" level=error msg="Upload failed: Error parsing HTTP response: unexpected end of JSON input: \"\""
Aug 15 22:36:05 server forward-journal[6535]: time="2016-08-15T22:36:05.122054012+02:00" level=info msg="{Action=build, LoginUID=4294967295, PID=22228}"
Aug 15 22:36:16 server forward-journal[6535]: time="2016-08-15T22:36:16.022509441+02:00" level=info msg="{Action=push, LoginUID=4294967295, PID=22247}"
Aug 16 07:17:45 server forward-journal[6535]: time="2016-08-16T07:17:45.608893675+02:00" level=info msg="{Action=create, Username=test, LoginUID=877601153, PID=978}"
Aug 16 07:18:24 server forward-journal[6535]: time="2016-08-  16T07:18:24.768737515+02:00" level=info msg="{Action=push, Username=test, LoginUID=877601153, PID=1081}"
Aug 16 07:20:15 server forward-journal[6535]: time="2016-08-16T07:20:15.546273448+02:00" level=info msg="{Action=create, Username=test, LoginUID=877601153, PID=1273}"

谁能解释一下为什么会这样?为什么我有权限却收到 403 禁止问题?
为什么有时有效有时无效?


我绝对相信这是一项安全功能,可以防止拒绝服务 / 分布式拒绝服务 https://en.wikipedia.org/wiki/Denial-of-service_attack当从同一个执行大量并发拉取时发生攻击或类似攻击IP地址。

今天我们在参加一门不错的课程时遇到了类似的问题每个人都从https://singularity-hub.org https://singularity-hub.org相同hello-world来自同一集群的图像,通过:

singularity pull hello-world.sif shub://vsoch/hello-world

大多数服务员都出现以下错误消息:

FATAL:   While pulling shub image: failed to get manifest for: shub://vsoch/hello-world: 403 Forbidden

几分钟后它就消失了。

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

向 docker 推送/拉取镜像时出现错误:403 Forbidden 的相关文章

随机推荐