How can I set a custom setting on a Postgres database?

0

Setting a custom value works fine in Aurora. For example:

SET jwt.claims.email = 'user.email@example.com';
SET my.custom.setting = 'yes';

In vanilla Postgres, one can also associate custom settings with a database object:

ALTER DATABASE mydb SET my.custom.setting = 'yes';

But in Aurora, I get the response:

ERROR: permission denied to set parameter "my.custom.setting"; SQLState: 42501

even though the current user is the database owner. Why does this disparity between standard Postgres and Aurora (and presumably RDS) exist? This breaks compatibility with a current setup that we're trying to migrate to AWS.

1回答
0

Amazon Aurora and Amazon RDS for PostgreSQL are managed database services. Both offer very high level of combability with existing open source offering. Some administration level actions are restricted to allow AWS to manage the database infrastcture. Setting parameters can be done using parameter groups as explained here: https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/AuroraPostgreSQL.Reference.ParameterGroups.html. You can see the list of supported parameters in the console or using CLI

In general if you are looking to migrate, you should approach your AWS account team. They will be able to provide you more in-depth guidance and assistance.

profile pictureAWS
回答済み 1年前
profile picture
エキスパート
レビュー済み 5日前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ