# No internet yet can ping 8.8.8.8



## balanga (Jun 8, 2021)

My internet connection often disconnects, but when it reconnects I can `ping 8.8.8.8`yet Chromium displays this msg:-



> No internet​Try:
> 
> Checking the network cables, modem, and router
> Reconnecting to Wi-Fi
> ERR_INTERNET_DISCONNECTED


Why do I get this? Sometimes it takes ten minutes or more before I can actually browse pages.

Why the delay and is there anything I can do about it?


----------



## datasmurf (Jun 8, 2021)

Just clear your Webbrowser cache by opening chrome://settings/clearBrowserData usually helps.


----------



## a6h (Jun 9, 2021)

CTRL+F5


----------



## balanga (Jun 9, 2021)

datasmurf said:


> Just clear your Webbrowser cache by opening chrome://settings/clearBrowserData usually helps.


Doesn't that clear all the usernames and passwords (most of which I can't remember) of sites I most often visit?


----------



## alex-t (Jun 12, 2021)

Check DNS servers availability:


```
telnet yor.dns.server.or.ip 53
```


----------



## Vull (Jun 12, 2021)

balanga said:


> Doesn't that clear all the usernames and passwords (most of which I can't remember) of sites I most often visit?


In Firefox you can untick all those things and just clear the cache only. I think most browsers have something similar.


----------



## Alain De Vos (Jun 12, 2021)

To see it it is only the browser

```
curl www.google.com
```
Or

```
curl -6 ipv6.google.com
```
If these works the problem is in the browser.
U can try falkon or qutebrowser.


----------



## gpw928 (Jun 13, 2021)

I spend my weekends at a place where the Internet connection is poor (very weak 3G signal) -- to the point where it is occasionally unusable.

My experience of slow and unreliable Internet connections is that the things that play up the most are web browsers.  They seem to cache a lot of state information that reflects the recent past, rather than the current situation.

I also routinely see DNS queries failing (timing out).  I think that this is because NAT translation table entries in the firewall for UDP "connections" get deleted automatically after their "time to live" has expired -- and the query takes longer than the default "time to live".  [I can fix this on my firewall, but my ISP runs my Internet traffic through a second firewall that I can't control (double NAT).]

So if you can ping 8.8.8.8, it's extremely likely that your Internet connection is working and your browser is just operating on obsolete information.  For a full page reload, hit the "Reload" icon while holding down the "Shift" key.

If you have control of your firewall, extending the timeout on the UDP NAT translation table entries may help.


----------



## Jose (Jun 13, 2021)

gpw928 said:


> I also routinely see DNS queries failing (timing out).  I think that this is because NAT translation table entries in the firewall for UDP "connections" get deleted automatically after their "time to live" has expired -- and the query takes longer than the default "time to live".  [I can fix this on my firewall, but my ISP runs my Internet traffic through a second firewall that I can't control (double NAT).]


Run a local caching only DNS server. It's easy and it's fun. I find running my own nameserver speeds up "the Internet" far more than any other one thing.


----------



## balanga (Jun 13, 2021)

Jose said:


> Run a local caching only DNS server. It's easy and it's fun. I find running my own nameserver speeds up "the Internet" far more than any other one thing.


I use pfSense as my Internet gateway and presume it has Enable DNS resolver ticked off so I presume I do have my own nameserver.


----------



## Alain De Vos (Jun 13, 2021)

What's the effect when you do curl ?


----------



## Jose (Jun 13, 2021)

balanga said:


> I use pfSense as my Internet gateway and presume it has Enable DNS resolver ticked off so I presume I do have my own nameserver.


So `drill www.google.com` and find out. The last four lines should look something like


```
;; Query time: 0 msec
;; SERVER: your.servers.ip.address
;; WHEN: Sat Jun 12 16:34:48 2021
;; MSG SIZE  rcvd: 48
```

See if you recognize the IP address in the SERVER entry.

Edit: Run it twice in case it's not already in your cache. You should see the IP for your Pfsense box in the second run's output.


----------



## balanga (Jun 13, 2021)

I get:-

```
root@T530:/# drill www.google.com
;; ->>HEADER<<- opcode: QUERY, rcode: NOERROR, id: 11015
;; flags: qr rd ra ; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0
;; QUESTION SECTION:
;; www.google.com.    IN    A

;; ANSWER SECTION:
www.google.com.    129    IN    A    172.217.169.4

;; AUTHORITY SECTION:

;; ADDITIONAL SECTION:

;; Query time: 0 msec
;; SERVER: 127.0.0.1
;; WHEN: Sun Jun 13 06:35:44 2021
;; MSG SIZE  rcvd: 48
```

The second run is just the same.


----------



## SirDice (Jun 13, 2021)

Modern browsers tend to cache DNS request and responses. So your browser may have cached the failed attempt.


----------



## balanga (Jun 13, 2021)

Aren't all my usernames and passwords which I use on various websites in cache? I'm concerned about losing them if I clear my cache.


----------



## Alain De Vos (Jun 13, 2021)

What's the effect when you do curl ?


----------



## memreflect (Jun 13, 2021)

balanga said:


> Aren't all my usernames and passwords which I use on various websites in cache? I'm concerned about losing them if I clear my cache.


Authentication information (username/password) is saved using cookies.  When you clear the browser cache but don't delete cookies, you effectively delete all downloaded resources from all websites (web page content, JavaScript files, images, and more).  If you were logged in to a website before clearing your cache, then you'll still be logged in after clearing your cache if you did not also delete cookies and the cookies have not expired.


----------



## balanga (Jun 13, 2021)

memreflect said:


> Authentication information (username/password) is saved using cookies.  When you clear the browser cache but don't delete cookies, you effectively delete all downloaded resources from all websites (web page content, JavaScript files, images, and more).  If you were logged in to a website before clearing your cache, then you'll still be logged in after clearing your cache if you did not also delete cookies and the cookies have not expired.


Thanks.... just shows how ignorant I am....


----------

