travisghansen / hass-opnsense

OPNsense integration with Home Assistant
Apache License 2.0
227 stars 29 forks source link

[Bug]: OPNsense Unbound logs filled with DNS requests for opn-repo.routerperformance.net #322

Open V4ler1an opened 12 hours ago

V4ler1an commented 12 hours ago

What happened?

My OPNsense Unbound DNS logs are getting flooded with queries for these two domains, at the same time, every 30 seconds:

opn-repo.routerperformance.net pkg.opnsense.org

After looking into this I found that the interval of the requests match the 'Scan interval (seconds)' setting in the OPNsense integration's configuration options. When I changed it to 120 seconds, the requests changed similarly.

I don't mind scanning OPNsense every 30 seconds but my take is that this may be triggering pkg update checks against the 'mimugmail' opn-repo repository?

If so perhaps we could decouple the OPNsense repo/pkg checking interval from the integration's scan interval? If it is triggering repo update checks, surely we only need this aspect daily?

I'd like to get this resolved as my Unbound logs are getting filled! Thanks.

hass-opnsense Version

0.3.9

OPNsense Firmware

24.7.8

Home Assistant Version

OS: 13.2 / Core: 2024.11.3 / Supervisor: 2024.11.4

Relevant logs

A copy of the OPNsense Unbound DNS log entries from each 'Scan interval' check by the integration:
-------------------
2024-11-22 22:24:11 localhost   A   pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 271     
2024-11-22 22:24:11 localhost   AAAA    pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 396     
2024-11-22 22:24:11 localhost   A   opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2161        
2024-11-22 22:24:11 localhost   AAAA    opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2091        
2024-11-22 22:24:11 localhost   A   opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2161        
2024-11-22 22:24:11 localhost   AAAA    opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2091        
2024-11-22 22:24:11 localhost   A   opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2161        
2024-11-22 22:24:11 localhost   AAAA    opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2091        
2024-11-22 22:24:10 localhost   A   opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2162        
2024-11-22 22:24:10 localhost   AAAA    opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2092        
2024-11-22 22:24:10 localhost   A   opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2162        
2024-11-22 22:24:10 localhost   AAAA    opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2092        
2024-11-22 22:24:10 localhost   A   pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 272     
2024-11-22 22:24:10 localhost   AAAA    pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 397     
2024-11-22 22:24:10 localhost   A   pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 272     
2024-11-22 22:24:10 localhost   AAAA    pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 397     
2024-11-22 22:24:10 localhost   A   pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 272     
2024-11-22 22:24:10 localhost   AAAA    pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 397     
2024-11-22 22:24:10 localhost   A   opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2162        
2024-11-22 22:24:10 localhost   AAAA    opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2092        
2024-11-22 22:24:10 localhost   A   opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2162        
2024-11-22 22:24:10 localhost   AAAA    opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2092        
2024-11-22 22:24:10 localhost   A   opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2162        
2024-11-22 22:24:10 localhost   AAAA    opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2092        
2024-11-22 22:24:10 localhost   A   pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 272     
2024-11-22 22:24:10 localhost   AAAA    pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 397     
2024-11-22 22:24:10 localhost   A   pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 272     
2024-11-22 22:24:10 localhost   AAAA    pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 397     
2024-11-22 22:24:09 localhost   A   pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 273     
2024-11-22 22:24:09 localhost   AAAA    pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 398     
2024-11-22 22:24:09 localhost   A   pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 273     
2024-11-22 22:24:09 localhost   AAAA    pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 398     
2024-11-22 22:24:09 localhost   A   opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2163        
2024-11-22 22:24:09 localhost   AAAA    opn-repo.routerperformance.net. Pass    Cache   NOERROR 0ms 2093        
2024-11-22 22:24:08 localhost   A   pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 274     
2024-11-22 22:24:08 localhost   AAAA    pkg.opnsense.org.   Pass    Cache   NOERROR 0ms 399

Additional Details

No response

Snuffy2 commented 12 hours ago

Likely duplicate/same root cause as #315. I expect the change to using a different firmware version check endpoint will fix this.

V4ler1an commented 12 hours ago

Yes, it looks to be. I had assumed the firmware checker was only for the primary OPNsense router firmware. Does it also notify on available updates to other plugins / repos?