sudo apt-get update
After inputting that command, the following occurs:
Reading package lists... Done
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/jammy/InRelease Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/jammy-updates/InRelease Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/jammy-backports/InRelease Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/jammy-security/InRelease Temporary failure resolving 'security.ubuntu.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.
For all the modules, all of them say IGN and it repeats over and over with the same modules attempted to be downloaded until a formal error occurs. "Temporary failure resolving" . For context, I have recently downloaded Ubuntu to test C on it via downloading GCC, but when I attempt to download gcc, it's more modules so the same error as previously stated occurs. If I am right and essentially no modules have been downloaded due to the ignore, is there a work-around/fix for this specific issue?
sudo apt-get install gcc
ping -c3 www.ubuntu.com
ping: www.ubuntu.com: Temporary failure in name resolution
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
64 bytes from 8.8.8.8: icmp_seq=1 ttl=118 time=70.3 ms
64 bytes from 8.8.8.8: icmp_seq=2 ttl=118 time=63.6 ms
64 bytes from 8.8.8.8: icmp_seq=3 ttl=118 time=65.4 ms
--- 8.8.8.8 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2004ms
rtt min/avg/max/mdev = 63.585/66.441/70.310/2.837 ms
Per instructions:
ls -al /etc/resolv.conf
lrwxrwxrwx 1 root root 20 Feb 1 18:12 /etc/resolv.conf -> /mnt/wsl/resolv.conf
sudo systemctl restart systemd-resolved.service
System has not been booted with systemd as init system (PID 1). Can't operate.
Failed to connect to bus: Host is down
ping -c3 www.ubuntu.com
and:ping -c3 8.8.8.8
Welcome to Ask Ubuntu. – chili555 Feb 01 '23 at 21:25ls -al /etc/resolv.conf
We're getting closer. – chili555 Feb 01 '23 at 22:35