0

I'm trying to upgrade from Xubuntu 20.04 to 24.04 but getting the following when I try sudo apt update:

W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/focal/InRelease  Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/focal-updates/InRelease  Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/focal-backports/InRelease  Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/focal-security/InRelease  Temporary failure resolving 'archive.ubuntu.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.

$ ping archive.ubuntu.com PING archive.ubuntu.com (185.125.190.81) 56(84) bytes of data. 64 bytes from ubuntu-mirror-1.ps5.canonical.com (185.125.190.81): icmp_seq=1 ttl=54 time=71.0 ms 64 bytes from ubuntu-mirror-1.ps5.canonical.com (185.125.190.81): icmp_seq=2 ttl=54 time=71.9 ms 64 bytes from ubuntu-mirror-1.ps5.canonical.com (185.125.190.81): icmp_seq=3 ttl=54 time=70.6 ms ^C --- archive.ubuntu.com ping statistics --- 3 packets transmitted, 3 received, 0% packet loss, time 2003ms rtt min/avg/max/mdev = 70.583/71.180/71.946/0.569 ms

$ sudo apt update Err:1 http://archive.ubuntu.com/ubuntu focal InRelease Temporary failure resolving 'archive.ubuntu.com' Err:2 http://archive.ubuntu.com/ubuntu focal-updates InRelease Temporary failure resolving 'archive.ubuntu.com' Err:3 http://archive.ubuntu.com/ubuntu focal-backports InRelease Temporary failure resolving 'archive.ubuntu.com' Err:4 http://archive.ubuntu.com/ubuntu focal-security InRelease Temporary failure resolving 'archive.ubuntu.com' Reading package lists... Done Building dependency tree
Reading state information... Done All packages are up to date. W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/focal/InRelease Temporary failure resolving 'archive.ubuntu.com' W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/focal-updates/InRelease Temporary failure resolving 'archive.ubuntu.com' W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/focal-backports/InRelease Temporary failure resolving 'archive.ubuntu.com' W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/focal-security/InRelease Temporary failure resolving 'archive.ubuntu.com' W: Some index files failed to download. They have been ignored, or old ones used instead.

The ping in the middle shows archive.ubuntu.com is being successfully resolved to 185.125.190.81, yet apt insists it can't resolve it. I've tried other repositories, and the same thing happens with all of them. Can anyone help me resolve this? (pun not intended.)

1 Answers1

0

I didn't have such a problem but you can try changing the apt repository:

sudo nano /etc/apt/sources.list

(try if that didn't work /etc/apt/sources.list.d/ubuntu.sources)

deb {http:CUSTOMREPO.COM/UBUNTU/}

deb-src is for source code

Or if you are editing the [/etc/apt/sources.list.d/ubuntu.sources], You should put your link After URI:

apt repo list (mirrors): https://launchpad.net/ubuntu/+archivemirrors

Alex.m
  • 1