Hide selected messages in system log

Hello everyone,

I’ve been using Home Assistant for almost a year now, but I still haven’t figured out how to hide individual warnings and possibly errors in the log.

There are some warnings that are (unfortunately) completely normal in my setup. However, they bother me because I often check the log to find errors, and then there are various “spam” messages present.

For example:

Logger: aioesphomeapi.connection
Source: runner.py:154
First occurred: 10:08:39 (134 occurrences)
Last logged: 17:06:40

    espcam-doorfront @ 192.168.6.145: Connection error occurred: [Errno 104] Connection reset by peer
    espcam-doorfront @ 192.168.6.145: Connection error occurred: espcam-doorfront @ 192.168.6.145: EOF received
    espcam-sidedoor @ 192.168.6.83: Connection error occurred: espcam-sidedoor @ 192.168.6.83: EOF received
    espcam-sidedoor @ 192.168.6.83: Connection error occurred: [Errno 104] Connection reset by peer

This issue is due to the poor Wi-Fi connection of this device, which occasionally fails to deliver data. I’m aware of this and it’s not worth a notification. How can I hide individual messages without losing all other alerts?

Hi Chris,

Be careful with this and very specific. Too broad and you will miss stuff that are legit problems.

Example from my config:

1 Like

Thank you very much for your input.

This has resulted in the following set of rules :wink:

Thanks also for the tip, I am aware of the risks.

In my case, for example, the annoying messages are about my NAS (qnap), which is only on when it has to accept the backups. The Esx host is only on when I need one of the VMs on it. And the cams sometimes have a poor connection or decoding errors. I am aware of this and it cannot be switched off.

So it’s a pleasure to be rid of these messages now and to see the essentials :wink: Thank you also for your example. That made it easier to understand than the documentation :wink:

logger:
  default: warn
  filters:
    homeassistant.components.stream.stream.camera.floor_cam_mainstream:
      - "Error from stream worker*"
    aioesphomeapi.reconnect_logic:
      - "Can't connect to ESPHome API for birdhouse*"
      - "Can't connect to ESPHome API for growbox*"
      - "Can't connect to ESPHome API for espcam-spare*"
    homeassistant.config_entries:
      - "Error setting up entry 192.168.4.240 for esxi_stats*"
    custom_components.ha_strava:
      - "Strava API rate limit has been reached*"
    homeassistant.components.dlna_dmr:
      - "Failed connecting to recently alive device at*"      
    homeassistant.components.tankerkoenig.coordinator:
      - "Error when adding station*"     
    custom_components.esxi_stats:
      - "Operation timed out*"
    homeassistant.backports.enum:
      - ".*deprecated.*"
    homeassistant.bootstrap:
      - ".*esxi.*"
      - ".*qnap.*"
    homeassistant.helpers.event:
      - ".*esxi.*"
    homeassistant.components.template.template_entity:
      - ".*esxi.*"   
1 Like