Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have been running Ubuntu 18.04/20.04 for just over a year without any noticeable problems. I work in a busy environment that hasn't allowed me time to learn anything more than the most basic aspects of Ubuntu, and I have just found an issue that requires help to resolve.
My problem:
Wifi works fine from my home, but when I try to connect to a different network, either private or public, the wifi area of the notification bar says it is connected but I can't connect to any sites. I get a variety of error messages in the browser. The most frequent message is that the host connection cannot be resolved.
What I've tried:
1. A coworker who uses Ubuntu suggested upgrading from 18.04 to 20.04. I did this, but the problem was not resolved.
2. The same coworker suggested that I test my wifi by creating a bootable USB via Unetbootin. I did this, booted into a clean install of Ubuntu 20.04, and found that the problem is resolved. While this shows that my current installation has problems, my work environment can't be interrupted to rebuild my OS.
I need to find a way to resolve this networking issue without the need to perform a full replacement of the OS.
The first thing to do is try from the command line to ping to something on the internet. Something like "ping -c 4 8.8.8.8" should give you 4 return packets.
Try it again with "ping -c 4 google.com"
If the first one works then you are most definitely connected.
If the second works then there is no problem, but if it fails then the issue is likely in how your system is resolving dns.
The fact that it works when booted to the live image already points to resolving host names, but the ping will confirm that.
What is in /etc/resolv.conf? Post the output of "cat /etc/resolv.conf"
What do you see if you run "dig google.com"? Post the output.
Last edited by computersavvy; 09-05-2021 at 06:21 PM.
Thanks for the quick reply, Computersavvy!
I'll test your suggestions as soon as I can and post the requested results.
FYI: My access to networks other than my working one will be less frequent in the coming week, so it may be a few days before I post again.
JP
I've run the Ping and Dig commands. Output shown below:
:~$ ping -c 4 8.8.8.8
PINT 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
64 bytes from 8.8.8.8: icmp_seq=1 ttl=114 time=658 ms
64 bytes from 8.8.8.8: icmp_seq=2 ttl=114 time=614 ms
64 bytes from 8.8.8.8: icmp_seq=3 ttl=114 time=613 ms
64 bytes from 8.8.8.8: icmp_seq=4 ttl=114 time=611 ms
--- 8.8.8.8 print statistics ---
4 packets transmitted, 4 received, 0% packet loss, time 3005ms
rtt min/avg/max/mdev = 611.017/623.919/657.635/19.501 ms
:~ping -c 4 google.com
ping: google.com: Name or service not known
I tried running "cat /etc/resolv.conf", but got the message:
cat: /etc/resolv.conf: No such file or directory
In my 9/13 post, the CAT command reported the resolv.conf file as not existing, however when I tried creating the link via the LN command, I got this response:
ln: Failed to create symbolic link '/etc/resolv.conf': File exists
Home wifi connects, other networks do not - Resolved, not solved
Hi all:
Sorry for the long delay in responding. My company has given me another laptop to work from so the one with problems could be entirely rebuilt with Ubuntu 20.10. All is now working correctly on all networks.
Thanks for all the help!
J
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.