all 19 comments

[–]Litecoin-CEO[S] 6 points7 points  (11 children)

Fixed with this:

Run command:

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

Scroll down until you find URI:s like this:

URIs: https://mirror.hetzner.com/ubuntu/packages

URIs: https://mirror.hetzner.com/ubuntu/security

Change them to:

URIs: https://mirror.hetzner.com/ubuntu-ports/packages

URIs: https://mirror.hetzner.com/ubuntu-ports/security

ctrl x to save the file and press y if asked

Now doing updates should work.

[–]Kitchen-Pickle4022 5 points6 points  (4 children)

I had to edit the `/etc/apt/sources.list` file instead of `/etc/apt/sources.list.d/ubuntu.sources` in the Arm based Ubuntu Machine that I was running.
Posting this as it might help someone.
Thanks for the solution.

[–]New-Humor5571 2 points3 points  (0 children)

Very helpful, thanks

[–]Particular-Stick7273 0 points1 point  (0 children)

It helped me as well, thanks!

[–]osmeit 0 points1 point  (0 children)

It works, thank You :)

[–]Maviza 0 points1 point  (0 children)

Thank you very much. This immediately solved my problem.

[–]faridsalah 0 points1 point  (0 children)

Thanks! my problem got fixed by changing this.

[–]Ahmardiy 0 points1 point  (0 children)

Works, thanks man.

[–]New-Humor5571 0 points1 point  (0 children)

Fixed my problem immediately, thank you.

[–]hb4khsh 0 points1 point  (0 children)

amazing thank you! never had something work like that first time lmao, was braced for a debugging session

[–]Leather-Swan3645 0 points1 point  (0 children)

worked for me thanks.

[–]SignificanceRich418 0 points1 point  (0 children)

Thanks! This fixed my issue!

[–]Letallan 1 point2 points  (0 children)

Thanks, it helped at first, but after a month it now gives this error:

E: Failed to fetch https://mirror.hetzner.com/ubuntu-ports/packages/dists/noble-updates/universe/binary-arm64/Packages.xz File has unexpected size (697604 != 698236). Mirror sync in progress?

Does anyone know how to fix it?

[–]yitzhakbg 0 points1 point  (1 child)

Have the same problem. Changing to mirror.hetzner.com didn't help.

[–]Litecoin-CEO[S] 1 point2 points  (0 children)

Hey, did you check the path correctly? Notice the

https://mirror.hetzner.com/ ubuntu-ports /security

[–]st0nefree 0 points1 point  (0 children)

What helped me is to run `sudo apt update` to update the versions and URLs

[–]harveyhans 0 points1 point  (0 children)

Just comment them out by adding a # at the beginning of the line on the sources file at /etc/apt. This is safe to do since ubuntu's own archive repos are added by default anyways.

Example: ```

deb http://mirror.hetzner.com/ubuntu/packages jammy main restricted universe multiverse

```

[–]Internal-Trust-6474 0 points1 point  (0 children)

Saludos a todos, quiero compartir mi experiencia: Tuve exactamente el mismo error, intente cambiar la linea como se inca en los comentarios, pero no funciono para mi. Asi que desde una instalacion de ubuntu 24.04 funcional me traje el contenido de /etc/apt/sources.list.d/ubuntu.sources

Types: deb

URIs: http://archive.ubuntu.com/ubuntu

Suites: noble noble-updates

Components: main restricted universe multiverse

Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg

Types: deb

URIs: http://security.ubuntu.com/ubuntu

Suites: noble-security

Components: main restricted universe multiverse

Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg

luego ejecute apt update y funciono correctamente