Home Assistant Won't Start

I can’t get Home Assistant to start. This is all I get in /home/hass/.homeassistant/homeassistant.log:

hass@hass:~$ tail -f -n 200 ~/.homeassistant/home-assistant.log 
2018-01-11 19:40:47 WARNING (Recorder) [homeassistant.components.recorder] Ended unfinished session (id=549 from 2018-01-12 00:42:36)
2018-01-11 19:41:12 WARNING (MainThread) [homeassistant.components.device_tracker] Duplicate device MAC addresses detected F8:A9:D0:73:B7:72
2018-01-11 19:41:17 WARNING (MainThread) [homeassistant.setup] Setup of climate is taking over 10 seconds.
2018-01-11 19:41:17 WARNING (MainThread) [homeassistant.setup] Setup of sensor is taking over 10 seconds.
2018-01-11 19:41:19 WARNING (MainThread) [homeassistant.setup] Setup of notify is taking over 10 seconds.
2018-01-11 19:41:19 WARNING (MainThread) [homeassistant.components.sensor] Setup of platform command_line is taking over 10 seconds.
2018-01-11 19:41:20 WARNING (MainThread) [homeassistant.setup] Setup of device_tracker is taking over 10 seconds.
2018-01-11 19:41:22 WARNING (MainThread) [homeassistant.setup] Setup of wemo is taking over 10 seconds.

I see quite a few entries in /var/log/syslog from Home Assistant:

Jan 11 19:41:26 hass hass[372]: INFO:homeassistant.core:Bus:Handling <Event service_executed[L]: service_call_id=1968688368-37>
Jan 11 19:41:26 hass hass[372]: INFO:pywemo.subscribe:Received event from <WeMo Switch "Kitchen 2">(192.168.1.19) - BinaryState 0
Jan 11 19:41:26 hass hass[372]: INFO:homeassistant.components.switch.wemo:Subscription update for  <WeMo Switch "Kitchen 2">
Jan 11 19:41:26 hass hass[372]: INFO:pywemo.subscribe:Received event from <WeMo Switch "Monitor backlights">(192.168.1.86) - BinaryState 0
Jan 11 19:41:26 hass hass[372]: INFO:homeassistant.components.switch.wemo:Subscription update for  <WeMo Switch "Monitor backlights">

But… I have an automation that sends a notification on homeassistant.start that never fires. The web ui never loads. And that’s as far as things ever seem to get. I’ve waited several hours on a few attempts, and nothing ever seems to go any further.

How can I troubleshoot this?

Thanks in advance!

you could try disabling options in configuration.yaml… ie switches, automations, etc and adding one by one until you find which one is the culprit.

If you didn’t change the options for logger: to reduce the log level, check out sudo journalctl -f -u home-assistant@homeassistant for more verbose logging.

Thanks for your help guys! I ended up commenting everything out, and then restoring things bit by bit. This turned out to be the culprit:

  - platform: command_line
    name: Agenda
    command: "gcalcli --tsv agenda $(date '+%Y%m%dT%H%M') $(date -d 23:59:59 '+%Y%m%dT%H%M') | cut -f2,5"
    scan_interval: 7200

Normally that gives me a sensor containing all my events for the day, but apparently it requires authorization when you run it the first time. This was a new virtualenv, so the auth was required.