My nas that I’m using for storj unfortunately gets killed occasionally due to power fluctuations in the local area. It reboots automatically but the storagenode/watchtower containers regularly fail to restart despite both being started with the following options:
docker run -d --restart unless-stopped …
As a result, both containers have been offline for a while. So the question here is what can I do to make this more resilient.
The storagenode currently won’t start, it’s erroring with:
Error: piecestore monitor: error verifying location and/or readability of storage directory: open config/storage/storage-dir-verification: no such file or directory.
The file config/storage/storage-dir-verification should be created with the first setup. If the file doesn’t exist - the storagenode will fail to start, because you probably mounted a wrong disk or not mounted on startup. It’s usually happened with Unraid (they start a docker service before the mount of the disks).
If you think that your data folder is correct, then you can run setup once:
I really recommend only storing user data on Synology on a path on one of the defined volumes, like /volumes/storj. They have a tendency to wipe anything that isn’t inside those user locations on DSM updates.
Additionally, instead of trying to fix the restart you should consider a UPS to prevent the restarting to begin with. Those sudden restarts are a guarantee your data will get corrupted at some point.
@BrightSilence It’s not synology and whilst I whole heartedly agree UPS would be a wise investment I still have to be able to get things back to a sane point where I’m able to run the storagenode container.
@Alexey I think this covers what you recommend but still no luck
You need to remove this from your docker run command. This parameter should only be used in the one time setup command, not every time you run the node.