I have had a problem that unused components are still loaded and I could not disable them. The posts I have found told me to disable the discovery component, but logs still showed things like these.
2019-07-04 09:19:48 INFO (SyncWorker_18) [homeassistant.loader] Loaded daikin from homeassistant.components.daikin
2019-07-04 09:19:48 INFO (SyncWorker_7) [homeassistant.loader] Loaded toon from homeassistant.components.toon
2019-07-04 09:19:48 INFO (SyncWorker_5) [homeassistant.loader] Loaded openuv from homeassistant.components.openuv
2019-07-04 09:19:48 INFO (SyncWorker_13) [homeassistant.loader] Loaded ambient_station from homeassistant.components.ambient_station
2019-07-04 09:19:48 INFO (SyncWorker_3) [homeassistant.loader] Loaded gpslogger from homeassistant.components.gpslogger
Now I have found a way to disable the loading of components that I do not need.
I have to say that probably this is not the proper way to do it, but it works for me, and I can accept the fact that I have to repeat this after every upgrade.
So please keep this in mind…
Anyway, what I did was open the home_asssitant_install_folder/python3.7/site-packages/homeassistant/generated/config_flows.py file and deleted the lines I do not need from the flows array.
Also keep in mind that after the last component there should be no comma…
The best way to disable unused components is to comment out the default_config line in your configuration.yaml file and only include the components you desire. Here’s what I have in mine. This removes all the preloading associated with auto discovery (zeroconf).
# I commented out default configure here
#default_config:
# what is included by default with default_configure can be found here
# https://www.home-assistant.io/integrations/default_config/
# add your own lines to only include what you desire instead of all of default_config
# Commenting out zeroconfig stops HA from auto discovering things on your network
# and as such it doesn't preload everything. I had an issue with a memory leak in ssdp
# which was searching for stuff I didn't need it to find
automation: !include automations.yaml
#automation manual: !include_dir_merge_list automations
#cloud:
config:
counter:
#dhcp
#energy
frontend:
history:
image:
#input_boolean: !include input_boolean.yaml
input_button:
#input_datetime: !include input_datetime.yaml
#input_number: !include input_number.yaml
#input_select: !include input_select.yaml
input_text: !include input_text.yaml
logbook:
map:
media_source:
mobile_app:
my:
person:
#scene:
script: !include scripts.yaml
#ssdp:
stream:
sun:
system_health:
#tag:
timer:
updater:
#usb:
#webhook
#zeroconf:
zone: