Upgrading never completes

Hello community,

I have just upgraded to the latest version (0.53.0) and find that my HA never comes back to life, I see the following (this is after only a minute or so, but this state persists seemingly forever):

pi@rpi:~/.homeassistant $ sudo systemctl status home-assistant@pi -l
● [email protected] - Home Assistant
   Loaded: loaded (/lib/systemd/system/[email protected]; enabled)
   Active: active (running) since Mon 2017-09-11 14:53:25 BST; 1min 15s ago
 Main PID: 3754 (hass)
   CGroup: /system.slice/system-home\x2dassistant.slice/[email protected]
           └─3754 /usr/bin/python3 /usr/local/bin/hass

Sep 11 14:53:25 rpi systemd[1]: Started Home Assistant.
Sep 11 14:53:31 rpi hass[3754]: 2017-09-11 14:53:31 INFO (Thread-2) [homeassistant.config] Upgrading configuration directory from  to 0.53.0
Sep 11 14:53:31 rpi hass[3754]: Config directory: /home/pi/.homeassistant

Read through the Release Notes for breaking changes for the current release and for any release that you may have skipped. Every release has breaking changes that can affect your configuration and require changes.

Agreed, however, I skipped five versions or so (coming from 0.47 IIRC) - is there no way to get better logging on what the issue might be? It seems stuck at the first hurdle!

Also - I reverted to an empty config and forced a reinstall ( sudo pip3 install --upgrade --force-reinstall homeassistant ), same issue…

One of the changes is a major database upgrade. The normal upgrade is an easy half hour from that far back, this could add another half hour to hour.

It might be that you’re better off removing homeassistant.db file before trying the upgrade (with HA shut down).

1 Like

Tried this also, left it running overnight and no change… Any other tips?

Well, what to do next depends on how you install HA on your Pi. Did you use the AIO, virtual environment, other?

Either way, given that you’re using systemctl, the output of journalctl -u home-assitant@pi -n 200 shared on the likes of hastebin or pastebin (not directly here) will hopefully provide enough information that somebody can identify the problem.

1 Like

Installed using: sudo pip3 install homeassistant

Odd that there is NO output using the journalctl commands you mention, once editing, I found the following:

**pi@rpi:~ $ sudo journalctl | grep home-a**
Sep 12 09:41:16 rpi sudo[7337]: pi : TTY=pts/0 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l
Sep 12 09:42:03 rpi sudo[7359]: pi : TTY=pts/0 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl stop home-assistant@pi
Sep 12 12:29:02 rpi sudo[10058]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l
Sep 12 12:29:12 rpi sudo[10070]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl start home-assistant@pi
Sep 12 12:29:14 rpi sudo[10083]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l
Sep 12 12:29:16 rpi sudo[10094]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l
Sep 12 12:29:18 rpi sudo[10105]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l
Sep 12 12:29:20 rpi sudo[10113]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l
Sep 12 12:30:13 rpi sudo[10133]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l
Sep 12 13:49:10 rpi sudo[11368]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l
Sep 12 13:53:45 rpi sudo[11448]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l
Sep 12 14:03:38 rpi sudo[11588]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l
Sep 12 14:29:12 rpi sudo[12010]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/journalctl -u home-assitant@pi -n 200
Sep 12 14:30:31 rpi sudo[12058]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl stop home-assistant@pi
Sep 12 14:30:38 rpi sudo[12074]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl start home-assistant@pi
Sep 12 14:31:07 rpi sudo[12107]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/systemctl status home-assistant@pi -l


**pi@rpi:~ $ sudo journalctl | grep homea**
Sep 12 12:29:17 rpi hass[10076]: 2017-09-12 12:29:17 INFO (Thread-2) [homeassistant.config] Upgrading configuration directory from  to 0.53.0
Sep 12 12:29:17 rpi hass[10076]: Config directory: /home/pi/.homeassistant
Sep 12 14:30:43 rpi hass[12080]: 2017-09-12 14:30:43 INFO (Thread-2) [homeassistant.config] Upgrading configuration directory from  to 0.53.0
Sep 12 14:30:43 rpi hass[12080]: Config directory: /home/pi/.homeassistant

Further, in a more general edit of the journalctl commands, I found that MQTT seems to be broken / stuck in a reboot loop, which may be something, but my config is BLANK right now, hoping to get HA to even start:

homeassistant:
  # Name of the location where Home Assistant is running
  name: Home
  # Pick yours from here: http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
  time_zone: Europe/London

# Enables support for tracking state changes over time.
history:

# Enables the frontend
frontend:

# Discover some devices automatically
discovery:

(I know that with this config the systemctl output also includes a warning about Lat/Long being missing, but nothing else in addition…)

The process wouldn’t be called “home-assistant” but “hass”.

Output is the same, this morning I uninstalled and re-installed 0.53.1… still not going anywhere!

Any other tips?

I don’t think I’m the same boat as you but I had the same issue, for me it was the new customize panel. In my configuration.yaml I had it set as a seperate entity instead of under homeassistant which caused it to get stuck as it was trying to load it as a component.

I renamed my configuration.yaml and restart HA to generate a new config so I could work that out. Sounds like you’ve already tried that though?

@Craig86 - you hero! Starting with no configuration.yaml (vs a “blank” one) got it to move forward, now “simply” to recreate my configuration!

Thanks all!

No worries, Once I’d figured out that, I just went through the configuration.yaml and commented a couple of items out and restarted. Mine turned out to my “customize:” and it was a layout issue. I had too many spaces, it worked in the previous build but didn’t like it on this one!

My HA is laid out with separate files for most config such as groups and scripts etc.