Poeschl / Hassio-Addons

The repository for my Home Assistant Supervisor Add-ons.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

syncthings addon failing

coolbombom opened this issue · comments

Which addon?
syncthings

Describe the bug
syncthing is not syncing

syncthing show following error in gui and log:
Failure checking encryption consistency with device computer for folder "common-sync-folder" (z64hu-dw22): open /root/common-sync-folder/.stfolder/syncthing-encryption_password_token: no such file or directory

To Reproduce
i have no idea how it got to this stage. imagine after a update of homeassistant and a restart.

Expected behavior
syncthing to sync

System
Core 2023.11.1
Supervisor 2023.10.1
Operating System 11.1
Brugerflade 20231030.1

Hi

I finally figured out how to reproduce this issue.

I removed the addon, installed it again, synced with clients, everything works as it should.

I restart home assistant server, and the error occurs.

I have a password on the folder i sync from the clients, and maybe that is the issue? The syncthing server is loosing password token after restart of docker container.

kind regards
cbb

In other words the docker setup needs to be setup to retain/store the encryption_password_token between restart of docker container? could that be it?

In other words the docker setup needs to be setup to retain/store the encryption_password_token between restart of docker container? could that be it?

Well, yes. Although, it's not only the encryption_password_token but also the synced data that needs to be retained between container restarts. Which brings us to...

Failure checking encryption consistency with device computer for folder "common-sync-folder" (z64hu-dw22): open /root/common-sync-folder/.stfolder/syncthing-encryption_password_token: no such file or directory

You're attempting to store syncthing data under /root/, it appears. That won't work due to Home Assistant's container setup:

When using this add-on to permanently hold your data, put the synced folders inside one of the following directories:

  • /data
  • /media
  • /share
  • /config
  • /ssl
  • /addons

Only the above directories are mapped into the add-on container. If you put synced folders in any other directory (like /root or /mnt), the synced data will be deleted on container restart.

RTFM 😉

It would be nice to make default folder persistent #447. I know that doc already mentioned that but what is the point of syncing to temporary folder at all?

Latest release of the add-on (v1.18.2) defaults to /share as folder path, which is persistent.

@Poeschl I think this issue can be closed.