Score:0

Windows 10 WSL2 - Ubuntu - apt update with Temporary failure resolving

de flag

I'm running windows 10 with WSL2. I installed a distribution of Ubuntu 20.04.

When I do sudo apt update, it's working

Hit:1 http://archive.ubuntu.com/ubuntu focal InRelease
Get:2 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
Get:3 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
Get:4 http://archive.ubuntu.com/ubuntu focal-backports InRelease [101 kB]
Fetched 328 kB in 17s (19.3 kB/s)
Reading package lists... Done
Building dependency tree
Reading state information... Done
All packages are up to date.

Then I tried adding a repository for podman. In /etc/apt/sources.list

deb https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/xUbuntu_20.04/ /

But now when doing sudo apt update I got

Err:1 https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/xUbuntu_20.04  InRelease
  Temporary failure resolving 'download.opensuse.org'
Err:2 http://archive.ubuntu.com/ubuntu focal InRelease
  Temporary failure resolving 'archive.ubuntu.com'
Err:3 http://security.ubuntu.com/ubuntu focal-security InRelease
  Temporary failure resolving 'security.ubuntu.com'
Get:4 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
Get:5 http://archive.ubuntu.com/ubuntu focal-backports InRelease [101 kB]
Fetched 214 kB in 34s (6269 B/s)
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://security.ubuntu.com/ubuntu/dists/focal-security/InRelease  Temporary failure resolving 'security.ubuntu.com'
W: Failed to fetch https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/xUbuntu_20.04/InRelease  Temporary failure resolving 'download.opensuse.org'
W: Some index files failed to download. They have been ignored, or old ones used instead.

Yet a ping is working

PING download.opensuse.org (195.135.221.134) 56(84) bytes of data.
64 bytes from download.opensuse.org (195.135.221.134): icmp_seq=1 ttl=58 time=36.9 ms
64 bytes from download.opensuse.org (195.135.221.134): icmp_seq=2 ttl=58 time=35.9 ms

Removing the repository line and it is working.

What would be the problem ?

Edit

I asked other coworkers to try the same and it's working for them. So I suppose it is not a proxy or dns problem on the network. The last 'guilty' :-) seems to be my laptop. But why ?

Liso avatar
sd flag
It's working fine here (Ubuntu server 20.04). Maybe check your internet connection?
de flag
My internet connection is ok. See get 4 and get 5 working. And a ping is working.
ChanganAuto avatar
us flag
Are you connecting behind a proxy?
de flag
Yes. I'm behind a corporate proxy. So I can consider a resolving problem with download.opensuse.org but not with the other ones when adding opensuse. See also my edited question.
user1582298 avatar
sl flag
I had the same issue, closed it and run ubuntu again as admin. Worked for me then.
karel avatar
sa flag
Does this answer your question? [apt-get update fails to fetch files, “Temporary failure resolving …” error](https://askubuntu.com/questions/91543/apt-get-update-fails-to-fetch-files-temporary-failure-resolving-error)
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.