apsd/mDNSResponder spamming thousands of DNS queries per second on macOS Big Sur
This keeps coming up every day or two, so eventually I wrote a small utility called mDNSSupervisor to monitor mDNSResponder and restart it whenever it's apparently going berserk. Doesn't solve the underlying issue of course but enough to cure the symptom and be mostly safe from its effects.
You can download the tool if you want from https://github.com/zmwangx/mDNSSupervisor (free, WTFPL licensed). Installation instructions there, too.
A sample from my logs showing it in action:
time=&quot;2020-11-28T17:15:06+00:00&quot; level=info msg=&quot;1606583706: 15s rolling average 142.8, above threshold 100&quot;
  PID  %CPU    RSS  ELAPSED COMMAND
  246  38.2   7692 14:01:57 /usr/sbin/mDNSResponder
  259   0.0   4768 14:01:57 /usr/sbin/mDNSResponderHelper
time=&quot;2020-11-28T17:15:06+00:00&quot; level=info msg=&quot;mDNSResponder restarted&quot;