Skip to content
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

Stops recording after a while #1

Open
kyleawayan opened this issue Jul 28, 2021 · 0 comments
Open

Stops recording after a while #1

kyleawayan opened this issue Jul 28, 2021 · 0 comments

Comments

@kyleawayan
Copy link
Owner

kyleawayan commented Jul 28, 2021

Recording of data will stop happening after a while, probably around a week or so running continuously. When it does happen, restarting the program fixes the issue.

According to the logs, it's probably due to the refreshing of the API tokens.

Temporary Fix

Create a cron job to restart it every two days through PM2.

  1. sudo crontab -e
  2. Add something like this below. You could also replace "all" with the id of the PM2 instance running vintage-influxdb.
0 0 */2 * * /usr/bin/node /usr/bin/pm2 restart all

Edit: It may even be better to restart daily actually:

0 0 */1 * * /usr/bin/node /usr/bin/pm2 restart all

You could also use PM2's built in --cron-restart flag:

pm2 start yarn --name vintage-influxdb --cron-restart="0 0 * * *" -- start
@kyleawayan kyleawayan pinned this issue Aug 8, 2021
@kyleawayan kyleawayan mentioned this issue Dec 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant