I'm encountering difficulties while trying to upgrade my Amazon Aurora PostgreSQL database from version 13 to version 15 using the pg_upgrade utility. The upgrade process is failing with an error, and I need assistance to resolve this issue.
Error Message:
pg_restore: creating FUNCTION "public.rds_get_stat_connections_counters()"
pg_restore: while PROCESSING TOC:
pg_restore: from TOC entry 225; 1255 2922011 FUNCTION rds_get_stat_connections_counters() rdsadmin
pg_restore: error: could not execute query: ERROR: could not find function "rds_get_stat_connections_counters" in file "/rdsdbbin/aurora-15.5.15.5.0.21262.0/lib/postgresql/rdsutils.so"
Command was: CREATE FUNCTION "public"."rds_get_stat_connections_counters"(OUT "dbid" "oid", OUT "db_name" "text", OUT "rolid" "oid", OUT "role_name" "text", OUT "application_name" "text", OUT "ssl" "text", OUT "auth" "text", OUT "client_addr" "text", OUT "authorized" integer, OUT "not_authorized" integer, OUT "total_auth_failed" integer, OUT "bad_db_name" integer, OUT "bad_db_oid" integer, OUT "bad_db_perm" integer, OUT "bad_conn_packet" integer, OUT "startup_packet_timeout" integer, OUT "lastattempt" timestamp with time zone) RETURNS SETOF "record"
LANGUAGE "c" STRICT
AS '$libdir/rdsutils', 'rds_get_stat_connections_counters';
Steps Taken So Far:
Ensured that I have taken a full backup of my database before initiating the upgrade.
Verified the compatibility of extensions and custom functions with PostgreSQL version 15.
Your prompt attention and assistance are greatly appreciated.
Yup since it relates to admin utilities and those are not accessible by the administrative account, it seems that this is a problematic bug with Aurora