pg_cron not running scheduled tasks

0

Recently had to terminate an SQL query "update cron.job_run_details" that was running indefintely on our RDS db, using SELECT pg_terminate_backend(<jobid>);

Since then, no cron jobs are running. I've taken a snapshot and restored a test instance, in which ive tried adding new cron jobs (such as vacuums every minute on a table) and it still does not work. I've rebooted the test instance to no effect. I wondering if the pg_chron extension works off a daemon and it I unwillingly terminated it and have no idea how to reboot it from RDS. Has anyone had similar issues?

2 Answers
0
Accepted Answer

Turn out I had terminated the connection that was idle, and pg_cron does not automatically recreate the connection. What we had to do was delete the extension, recreate it and reboot the instance and now the cron jobs work as expected

answered 9 months ago
0

Hello.
Does cron not work even if you reconfigure it according to the steps in the following document?
https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/PostgreSQL_pg_cron.html

profile picture
EXPERT
answered 9 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions