kelektiv / node-cron

Cron for NodeJS.
MIT License
8.48k stars 626 forks source link

Unraid api crash #893

Closed PyeAz closed 3 months ago

PyeAz commented 3 months ago

Hi, apologies if this is not lodged correctly, this is my first bug report.

Added an APC UPS to my Unraid server using NUT plugin (Network UPS Tools (NUT) for UNRAID / 2024.08.14 ) and now have started getting the server hang once per day or so, completely unresponsive to ssh, gui etc. all but ping. Requires hard power down.

This is what is logged each time it occurs:

*Aug 18 01:48:30 NAZ unraid-api[31644]: ⚠️ Caught exception: Something went wrong. cron reached maximum iterations.#012#011#011#011#011#011#011Please open an issue (https://github.com/kelektiv/node-cron/issues/new) and provide the following string#012#011#011#011#011#011#011Time Zone: "" - Cron String: 0 - UTC offset: +10:00 - current Date: Sun Aug 18 2024 01:48:25 GMT+1000 Aug 18 01:48:37 NAZ unraid-api[31644]: ⚠️ UNRAID API crashed with exit code 1** Aug 18 01:54:35 NAZ usbhid-ups[22593]: nut_libusb_get_report: Input/Output Error Aug 18 01:58:56 NAZ upsd[14850]: Data for UPS [ups] is stale - check driver Aug 18 01:58:59 NAZ upsmon[14853]: Poll UPS [ups@127.0.0.1] failed - Data stale Aug 18 01:58:59 NAZ upsmon[14853]: Communications with UPS ups@127.0.0.1 lost Aug 18 01:59:05 NAZ upsmon[14853]: Poll UPS [ups@127.0.0.1] failed - Data stale Aug 18 01:59:10 NAZ upsmon[14853]: Poll UPS [ups@127.0.0.1] failed - Data stale Aug 18 01:59:15 NAZ upsmon[14853]: Poll UPS [ups@127.0.0.1] failed - Data stale Aug 18 01:59:20 NAZ upsmon[14853]: Poll UPS [ups@127.0.0.1] failed - Data stale Aug 18 01:59:25 NAZ upsmon[14853]: Poll UPS [ups@127.0.0.1] failed - Data stale Aug 18 01:59:30 NAZ upsmon[14853]: Poll UPS [ups@127.0.0.1] failed - Data stale Aug 18 01:59:35 NAZ upsmon[14853]: Poll UPS [ups@127.0.0.1] failed - Data stale Aug 18 01:59:36 NAZ upsd[14850]: UPS [ups] data is no longer stale Aug 18 02:01:20 NAZ upsmon[14853]: Communications with UPS ups@127.0.0.1 established Aug 18 03:39:02 NAZ upsd[14850]: Data for UPS [ups] is stale - check driver Aug 18 03:40:57 NAZ upsmon[14853]: Poll UPS [ups@127.0.0.1] failed - Write error: Broken pipe Aug 18 03:42:24 NAZ usbhid-ups[22593]: WARNING: send_to_all: write 29 bytes to socket 16 failed (ret=-1), disconnecting: Resource temporarily unavailable Aug 18 03:45:04 NAZ upsd[14850]: UPS [ups] data is no longer stale Aug 18 03:49:36 NAZ upsmon[14853]: Communications with UPS ups@127.0.0.1 lost Aug 18 03:50:08 NAZ usbhid-ups[22593]: send_to_all: synchronous mode was 'auto', will try 'on' for next connections Aug 18 03:52:28 NAZ upsd[14850]: Connected to UPS [ups]: usbhid-ups-ups Aug 18 03:53:19 NAZ upsmon[14853]: UPS [ups@127.0.0.1]: connect failed: Server disconnected Aug 18 03:57:16 NAZ usbhid-ups[22593]: sock_connect: keeping default synchronous mode Aug 18 04:02:17 NAZ upsd[14850]: Data for UPS [ups] is stale - check driver Aug 18 04:03:57 NAZ upsmon[14853]: UPS ups@127.0.0.1 is unavailable Aug 18 04:05:33 NAZ upsd[14850]: write() failed for 127.0.0.1: Broken pipe Aug 18 04:09:13 NAZ upsmon[14853]: UPS [ups@127.0.0.1]: connect failed: Server disconnected Aug 18 04:09:58 NAZ upsd[14850]: UPS [ups] data is no longer stale Aug 18 04:12:20 NAZ upsmon[14853]: UPS ups@127.0.0.1 is unavailable Aug 18 04:12:43 NAZ upsd[14850]: write() failed for 127.0.0.1: Broken pipe Aug 18 04:12:43 NAZ upsmon[14853]: UPS [ups@127.0.0.1]: connect failed: Server disconnected Aug 18 04:12:43 NAZ upsd[14850]: Data for UPS [ups] is stale - check driver Aug 18 04:12:43 NAZ upsd[14850]: UPS [ups] data is no longer stale Aug 18 04:12:43 NAZ upsd[14850]: write() failed for 127.0.0.1: Broken pipe Aug 18 04:12:48 NAZ upsd[14850]: User monuser@127.0.0.1 logged into UPS [ups] Aug 18 04:12:48 NAZ upsmon[14853]: Communications with UPS ups@127.0.0.1 established Aug 18 04:33:57 NAZ usbhid-ups[22593]: nut_libusb_get_report: Input/Output Error Aug 18 04:36:12 NAZ usbhid-ups[22593]: nut_libusb_get_report: Input/Output Error Aug 18 04:40:04 NAZ usbhid-ups[22593]: nut_libusb_get_report: Input/Output Error Aug 18 04:59:37 NAZ usbhid-ups[22593]: nut_libusb_get_report: Input/Output Error

After a few hours it appears the server regained connectivity with the UPS (return of nut_libusb_get_report: Input/Output Error) but still unable to connect via ssh or gui.

(Beforehand I continually see the following every 15 - 45 mins or so but apparently this can be ignored): Aug 18 00:13:50 NAZ usbhid-ups[22593]: nut_libusb_get_report: Input/Output Error

Happy to provide more details if required.

sheerlox commented 3 months ago

Hi, we're only a library used by Unraid. Please refer to the following issue for more details: