citusdata / citusdata/pg_cron

pg_cron for PostgreSQL 12 stops working with message LOG: cron job 1 job startup timeout

Open
#210 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
C
Stars
3.9k
Forks
260
Avg merge
5d 5h
Merged PRs (30d)
1

Description

Hello,

I have set up pg_cron on PostgreSQL 12 on production server. It was working properly. Suddenly it stops working with message LOG: cron job 1 job startup timeout.

I have tried below options still getting same message.

1. I have restarted PostgreSQL service.
2. Tried to create new job and tested.
3. Removed pg_cron extension and recreated it.
There is no pg_cron parameter available to change timeout value.

As per analysis this is the log. And job command didn't start within 10 sec so it was timeout.

2022-10-06 15:35:00.000 CEST [8334] DEBUG: StartTransaction(1) name: unnamed; blockState: DEFAULT; state: INPROGRESS, xid/subid/cid: 0/1/0
2022-10-06 15:35:00.000 CEST [8334] DEBUG: CommitTransaction(1) name: unnamed; blockState: STARTED; state: INPROGRESS, xid/subid/cid: 51366430/1/0
2022-10-06 15:35:00.000 CEST [8334] DEBUG: StartTransaction(1) name: unnamed; blockState: DEFAULT; state: INPROGRESS, xid/subid/cid: 0/1/0
2022-10-06 15:35:00.001 CEST [8334] DEBUG: CommitTransaction(1) name: unnamed; blockState: STARTED; state: INPROGRESS, xid/subid/cid: 51366431/1/1
2022-10-06 15:35:00.001 CEST [8334] LOG: cron job 1 starting: Refresh Materialized view CONCURRENTLY vw_publicmap_moor;
2022-10-06 15:35:00.001 CEST [8334] DEBUG: StartTransaction(1) name: unnamed; blockState: DEFAULT; state: INPROGRESS, xid/subid/cid: 0/1/0
2022-10-06 15:35:00.001 CEST [8334] DEBUG: CommitTransaction(1) name: unnamed; blockState: STARTED; state: INPROGRESS, xid/subid/cid: 51366432/1/1
2022-10-06 15:35:10.000 CEST [8334] DEBUG: StartTransaction(1) name: unnamed; blockState: DEFAULT; state: INPROGRESS, xid/subid/cid: 0/1/0
2022-10-06 15:35:10.000 CEST [8334] DEBUG: CommitTransaction(1) name: unnamed; blockState: STARTED; state: INPROGRESS, xid/subid/cid: 51366445/1/1
2022-10-06 15:35:10.000 CEST [8334] LOG: cron job 1 job startup timeout

How to resolve this issue ?

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.