*** a/src/backend/tcop/postgres.c --- b/src/backend/tcop/postgres.c *************** *** 3479,3484 **** PostgresMain(int argc, char *argv[], const char *username) --- 3479,3494 ---- } /* + * Load shared preload libraries on single-user mode. + * Because this routine is not invoked from PostmasterMain() that + * loads shared preload libraries prior to fork the backend process, + * the 'shared_preload_libraries' shall be implicitly ignored. + * So, we need to load them on single-user mode. + */ + if (!IsUnderPostmaster) + process_shared_preload_libraries(); + + /* * You might expect to see a setsid() call here, but it's not needed, * because if we are under a postmaster then BackendInitialize() did it. */