question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

cron fails on two servers, approximately same time, without error

See original GitHub issue

I have two aws servers, identical setup: lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 18.04.2 LTS Release: 18.04 Codename: bionic uname -r 4.15.0-1035-aws node --version v8.16.0 cat package.json | grep cron "cron": "^1.7.1",

both have cron running with this code: new CronJob('*/10 * * * * *', procNewBlock, null, true, 'Europe/Berlin');

both stopped running at approximately the same time, the first was running the last time at: May 2 09:05:47 UTC

the second last run was at: May 2 09:06:30 UTC

so far this was the only time that this happend (running for about 1 month now). To me it looks as if some scheduled system task outside of nodejs is killing the crons. But any help greatly appreciated. The nodejs processes did not see any interruption.

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:9 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
ChristophDFinecommented, Jul 3, 2019

No, not yet. I am still waiting that it happens again so I get more debug info. So far it happened once more, which showed me that: a) it is actually not related to the cron package but some deeper source in nodejs b) it was probably a coincidence that it happend on both servers at the same time

0reactions
EdClauscommented, Mar 28, 2020

This morning I got this same error and tried out with a fresh new install of rasbian and node-red. I was able to pinpoint it to an inject node with specific content. With this (below) node it crashed, with other configurated inject nodes there are no problems.

[{“id”:“a02e32cd.28c53”,“type”:“tab”,“label”:“Flow 6”,“disabled”:false,“info”:“”},{“id”:“a78a0f31.f1bc9”,“type”:“inject”,“z”:“a02e32cd.28c53”,“name”:“Init & reset”,“topic”:“”,“payload”:“auto”,“payloadType”:“str”,“repeat”:“”,“crontab”:“*/20 2 * * *”,“once”:true,“onceDelay”:0.1,“x”:130,“y”:120,“wires”:[[]]}]

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cron job troubleshooting guide - Cronitor
This guide will walk you through locating cron jobs on your server, validating their schedules, and debugging common problems.
Read more >
Cron job fails silently - Server Fault
When something works from the command line and not from 'cron', my experience is that 'environment' is one of the most common problems....
Read more >
google app engine - Cron always fails and manual execution ...
The scheduled task always succeeds when I manually run. It always fails when cron (Google Cloud Scheduler) runs it. The logs don't give...
Read more >
cron job stops after certain hours. · Issue #232 - GitHub
Using on raspberry pi with node v4.2.1 and cron 1.1.0 . ... cron fails on two servers, approximately same time, without error #423....
Read more >
Where are cron errors logged? - Unix & Linux Stack Exchange
@Wirone: that file does contain CRON logs, but only the time and invocation line; no output. I have a 2-command crontab entry that...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found