pg_cron icon indicating copy to clipboard operation
pg_cron copied to clipboard

Creating pg_cron extension getting Error

Open ramrasi opened this issue 6 years ago • 10 comments

image

I am Using

Fedora 28 Posgres 10.4

ramrasi avatar Jun 20 '18 06:06 ramrasi

You need to add pg_cron to shared_preload_libraries.

marcocitus avatar Jun 20 '18 06:06 marcocitus

I'm seeing the same error on "create extension". I have the following in my postgresql.conf

shared_preload_libraries = 'pg_cron' cron.database_name = 'postgres'

I'm using postgres 9.5 on centos 6

Leeann-Sandstrom avatar Jul 09 '18 17:07 Leeann-Sandstrom

I'm having the same issue with Docker image citusdata/citus:7.5.1 (Postgres 10). Tried both installations from sources and apt-get. I also tried install v1.1.2 and v1.0.2 from sources, but got the same result.

peppered avatar Oct 16 '18 09:10 peppered

Also unable to start the Postgres server when including shared_preload_libraries = 'pg_cron' in postgresql.conf file.

Mar 16 16:43:52 ip-10-0-0-240 systemd[1]: Starting PostgreSQL Cluster 11-lusca...
Mar 16 16:43:52 ip-10-0-0-240 postgresql@11-lusca[29537]: Error: /usr/lib/postgresql/11/bin/pg_ctl /usr/lib/postgresql/11/bin/pg_ctl start -D /var/lib/postgresql/11/lusca -l /var/log/postgresql/postgresql-11-lusca.log -s -o  -c config_file="/etc/postgresql/11/lusc
Mar 16 16:43:52 ip-10-0-0-240 postgresql@11-lusca[29537]: 2019-03-16 16:43:52.635 UTC [29543] FATAL:  could not load library "/usr/lib/postgresql/11/lib/pg_cron.so": /usr/lib/postgresql/11/lib/pg_cron.so: undefined symbol: getmissingattr
Mar 16 16:43:52 ip-10-0-0-240 postgresql@11-lusca[29537]: 2019-03-16 16:43:52.635 UTC [29543] LOG:  database system is shut down
Mar 16 16:43:52 ip-10-0-0-240 postgresql@11-lusca[29537]: pg_ctl: could not start server
Mar 16 16:43:52 ip-10-0-0-240 postgresql@11-lusca[29537]: Examine the log output.
Mar 16 16:43:52 ip-10-0-0-240 systemd[1]: [email protected]: Can't open PID file /var/run/postgresql/11-lusca.pid (yet?) after start: No such file or directory
Mar 16 16:43:52 ip-10-0-0-240 systemd[1]: [email protected]: Failed with result 'protocol'.
Mar 16 16:43:52 ip-10-0-0-240 systemd[1]: Failed to start PostgreSQL Cluster 11-lusca.

I used apt to install the library (running Ubuntu 18.04).

mecampbellsoup avatar Mar 16 '19 16:03 mecampbellsoup

Yeah, when I tried to add shared_preload_libraries = 'pg_cron' in postgresql.conf file, my database is not started up.

herenickname avatar Apr 08 '19 13:04 herenickname

Yeah, when I tried to add shared_preload_libraries = 'pg_cron' in postgresql.conf file, my database is not started up.

same problem

kbereza avatar Jun 21 '19 05:06 kbereza

I had the same problem. In my instance the error was:

FATAL: could not load library "/usr/pgsql-11/lib/libpqwalreceiver.so": /usr/pgsql-11/lib/libpq.so.5: symbol X509_get_signature_nid, version libcrypto.so.10 not defined in file libcrypto.so.10 with link time reference

The issue is described here (in a nut shell - old version of openssl package): https://www.postgresql.org/message-id/20190109042747.GG21835%40paquier.xyz

and the solution is to install openssl version >= 1.0.2 (i had 1.0.1)

matuszabojnik avatar Jul 01 '19 12:07 matuszabojnik

I'm getting the same error on Ubuntu 20.04.02 LTS

openssl is installed, version is 1.1.1. PostgreSQL 13.3 (packages from postgresql.org) postgresql-13-cron 1.3.1-1

sjstoelting avatar Jul 26 '21 11:07 sjstoelting

I am experiencing something similar even though I have updated the postgresql.conf

❯ systemctl status postgresql.service  
...
FATAL:  could not access file "pg_cron": No such file or directory
...

Version Info:

OpenSSL 3.0.9
postgres (PostgreSQL) 15.1

kaushalyap avatar Jun 05 '23 03:06 kaushalyap