Actually losing DNS is very easy to diagnose, for me at least. Is example.com working? No? Can I ping any DNS server like 1.1.1.1, 4.4.4.4 or 8.8.8.8 or whatever the well-known DNS servers are? Yes? Then my network is fine, it's just DNS.
I don't mean to be condescending, just curious why you didn't figure it out.
How do you diagnose that your DNS have failed if your system seems to be working but is suddenly using a hidden DNS setting? Local DNS settings for your LAN could be dead and gone but "example.com" still work fine. Why? If I hadn't read the article I would have no clue unless I looked a a network dump. It's insane.
One of my first troubleshooting steps is replacing /etc/resolv.conf with just a basic one. By seeing that using Google's DNS directly works, I would know that it's a problem with resolved.
I don't mean to be condescending, just curious why you didn't figure it out.