-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Basic Station kills itself after a container restart #13
Comments
Hi! Thank you for reporting the problem. |
Thanks for your reply. For the persisting data, this seems to be a weird thing of docker compose when restarting (afaict not in the doc, but it's mentioned e.g. here https://stackoverflow.com/questions/69369205/how-to-return-one-container-to-a-clean-state-in-docker-compose). Data seems to persist when doing a The easiest way I found to reproduce the issue is to observe the logs with |
I have tested the setup as you suggest and it worked as expected, no error after the reboot. Can it be specific to a certain docker version? Also, I don't see how the issue you linked applies here, there is no persistent storage in the image except that defined on the docker compose file (if defined). Anyway adding the line you suggest will not harm so I'm ok with it. But I fear the issue might not be due to something different... |
That's weird. I checked the debian Dockerfiles for balena and it doesn't seem like they define a volume explicitely anywhere. My setup, for the record: Debian 11 (buster), Docker 24.0 (tested with both a normal setup and rootless), armhf architecture (tested with a RPi 3B and a BeagleBone Green) |
Hi, I had an issue where the Basic Station process would die immediately after a container restart with the message
This seem to be caused by
killOldPid
(https://github.com/lorabasics/basicstation/blob/master/src-linux/sys_linux.c#L366) which read the PID from a file (/var/temp/station.pid) and kills it if it's still running to avoid having multiple processes running at the same time.Since the start.sh always does the same, the process will always get the same PID and there is no check for that in the code.
It might be better to fix it in the lorabasics repo somehow, but for now adding the following in the start script fixed it.
rm -r /var/tmp/ 2> /dev/null
The text was updated successfully, but these errors were encountered: