0

I recently setup a server for apt-mirror with Ubuntu 20.04 server in our network. The mirror-sync itself works without any error. After that i changed the Repository path on one of my Ubuntu 20.04 test servers in /etc/apt/sources.list . When running apt-get update on the test-server i receive the following errors:

Err:7 http://repository.XXX.XXXXX.XX/ubuntu/mirror/archive.ubuntu.com/ubuntu focal-updates/main amd64 c-n-f Metadata
  404  Not Found [IP: XXX.XX.XX.XX 80]
Err:19 http://repository.XXX.XXXXX.XX/ubuntu/mirror/archive.ubuntu.com/ubuntu focal-backports/main amd64 c-n-f Metadata
  404  Not Found [IP: XXX.XX.XX.XX 80]
Err:27 http://repository.XXX.XXXXX.XX/ubuntu/mirror/archive.ubuntu.com/ubuntu focal-security/main amd64 c-n-f Metadata
  404  Not Found [IP: XX.XX.XX.XX 80]
Ign:16 http://repository.XXX.XXXXX.XX/ubuntu/mirror/archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 c-n-f Metadata
E: Failed to fetch http://repository.XXX.XXXXX.XX/ubuntu/mirror/archive.ubuntu.com/ubuntu/dists/focal-updates/main/cnf/Commands-amd64  404  Not Found [IP: XX.XX.XX.XX 80]
E: Failed to fetch http://repository.XXX.XXXXX.XX/ubuntu/mirror/archive.ubuntu.com/ubuntu/dists/focal-backports/main/cnf/Commands-amd64  404 Not Found [IP: XX.XX.XX.XX 80]
E: Failed to fetch http://repository.XXX.XXXXX.XX/ubuntu/mirror/archive.ubuntu.com/ubuntu/dists/focal-security/main/cnf/Commands-amd64  404 Not Found [IP: XX.XX.XX.XX 80]
W: Some index files failed to download. They have been ignored, or old ones used instead.

i already tried running sudo rm -rf /var/lib/apt/lists/* on the server receiving update and deleting all mirror-files and running apt-mirror on the repo-server again.

I'm relative new to linux and i couldn' find any existing posts about this. thanks for helping

Image of /etc/apt/sources.list:

enter image description here

Artur Meinild
  • 21,605
  • 21
  • 56
  • 89
T.S.
  • 1
  • 1
  • Please list output of `cat /etc/apt/sources.list` in your question - it most likely has errors. Thanks. – Artur Meinild Nov 16 '22 at 13:01
  • Does this answer your question? [How can I fix a 404 Error when using a PPA or updating my package lists?](https://askubuntu.com/questions/65911/how-can-i-fix-a-404-error-when-using-a-ppa-or-updating-my-package-lists) – Artur Meinild Nov 16 '22 at 13:03
  • i added the output of cat /etc/apt/sources.list as a link ( i cant post more than 10 links) https://askubuntu.com/questions/65911/how-can-i-fix-a-404-error-when-using-a-ppa-or-updating-my-package-lists Did not answer my question. i only have one repository configured, which is hosted by myself on another server – T.S. Nov 16 '22 at 13:33
  • Where? Can't you edit the post? – Artur Meinild Nov 16 '22 at 13:34
  • Remove or comment out the line you added to `/etc/apt/sources.list` - it probably gives the error. – Artur Meinild Nov 16 '22 at 13:35
  • https://i.stack.imgur.com/hWuyU.png – T.S. Nov 16 '22 at 13:36

1 Answers1

0

It seems you can contact your server, but it doesn't get the response it should:

The 404 or Not Found error message is a HTTP standard response code indicating that the client was able to communicate with the server, but the server could not find what was requested.

So there is something wrong with the configuration of the apt mirror server that gives a 404 error. Unfortunately, you haven't provided any clues to what this could be.

Artur Meinild
  • 21,605
  • 21
  • 56
  • 89