npx skills add ...
npx skills add aws/agent-toolkit-for-aws --skill rds-oss
npx skills add aws/agent-toolkit-for-aws --skill rds-oss
Advises on Amazon RDS open-source engines (MySQL, MariaDB, PostgreSQL) for instance creation, upgrade planning, commitment pricing, proxy evaluation, and Blue/Green deployments. Handles any RDS MySQL, MariaDB, or PostgreSQL question, including create a production-ready RDS MySQL instance, provision an RDS PostgreSQL database, run the RDS upgrade advisor for my RDS MySQL instance, what are my upgrade options, upgrade RDS MariaDB from 10.6 to the latest version, should I buy reserved instances or a savings plan for db.r7g.2xlarge RDS MySQL, change a VARCHAR to INT column on RDS MySQL 8.0 with Blue/Green, and does RDS Proxy help when PgBouncer already runs in transaction mode. Covers instance creation with production best practices, describe-db-instances and describe-db-engine-versions upgrade-target workflow, live prechecks via SSM or direct connection, RI versus DSP commitment pricing, RDS Proxy versus PgBouncer, and Blue/Green lifecycle with binlog replay compatibility.
Advisor for Amazon RDS on the open-source engines — MySQL, MariaDB, and PostgreSQL. Five decision areas:
Produces cost estimates, precheck findings, and CLI commands. For instance creation, executes the create-db-instance call with production best practices. For upgrades, purchases, and switchovers — advisory only, never executes without explicit user confirmation.
Scoped to RDS open-source engines. For Aurora, use amazon-aurora. For Oracle, SQL Server, Db2, use the engine-specific skills.
The AWS MCP server is recommended for executing commands but is not required; all operations can also be performed via the AWS CLI.
| User asks about… | Go to |
|---|---|
| Create, provision, or set up a new RDS MySQL/MariaDB/PostgreSQL instance | Production Instance Creation below |
| Upgrade, target version, pre/post-upgrade checklist, upgrade prechecks, Read Replica upgrade order | references/upgrade-workflow.md |
| Reserved Instance, RI, Database Savings Plan, DSP, 1yr vs 3yr, Multi-AZ commitment, No/Partial/All Upfront | references/commitment-pricing-workflow.md |
| RDS Proxy, connection pooling, too many connections, Lambda DB connections, proxy pinning, PgBouncer vs Proxy | references/proxy-advisor-workflow.md |
| Blue/Green, zero-downtime DDL, switchover, schema change with minimal downtime, type change on production | references/bluegreen-advisor-workflow.md |
Broad request ("help me with RDS")? Present the five options as one line each. If the user supplied an instance ID, offer a general health check (engine + version + connection utilization) as entry point.
Out-of-scope (Aurora, Oracle, SQL Server, Db2, backup policy, Performance Insights deep-dive analysis): answer from general knowledge, note this skill doesn't cover it, point to the right engine-specific skill.
RDS open-source engines and Aurora are different products with different semantics. You MUST NOT apply Aurora concepts to RDS:
| Concept | RDS (this skill) | Aurora (use amazon-aurora) |
|---|---|---|
| LTS releases | ❌ Does not exist | ✅ Has LTS versions |
| Serverless mode | ❌ Does not exist | ✅ Aurora Serverless |
| I/O-Optimized storage | ❌ Does not exist | ✅ aurora-iopt1 |
| Data API | ❌ Not available for standalone RDS | ✅ Aurora Serverless clusters |
| Instance topology | Instance-based (describe-db-instances) | Cluster-based (describe-db-clusters) |
| Upgrade scope | Per-instance | Per-cluster (writer + readers together) |
| DSP term options | 1yr and 3yr | 1yr only |
| Pricing model | On-Demand + RI + DSP | On-Demand + RI + DSP + I/O pricing |
If a user asks about any Aurora-specific concept, route to amazon-aurora. If an instance turns out to be Aurora (engine = aurora-mysql or aurora-postgresql), stop and redirect.
When a user asks to create or provision a new RDS MySQL, MariaDB, or PostgreSQL instance for production use, you MUST apply the following best practices by default:
aws rds describe-db-engine-versions --engine <engine> --query "DBEngineVersions[].EngineVersion" to find the latest. For MySQL, prefer 8.4.x over 8.0 (8.0 has an earlier end-of-standard-support date than 8.4 — see RDS Extended Support for dates). For PostgreSQL, use the latest major. For MariaDB, use the latest major.--multi-az for automatic failover.--storage-encrypted --kms-key-id <key-arn>. A customer-managed key gives full control over key rotation, access policies, and cross-account sharing.--no-publicly-accessible to ensure the instance is not accessible from the internet.--backup-retention-period 7.--enable-performance-insights --performance-insights-retention-period 7. If Performance Insights captures queries containing sensitive data (e.g., literal values in WHERE clauses), specify --performance-insights-kms-key-id <key-arn> to encrypt at rest with a customer-managed KMS key.--deletion-protection.admin, root, postgres, or master, which make credential-guessing attacks easier. Choose a custom --master-username (e.g., an application- or team-specific name).--manage-master-user-password instead of providing a plaintext --master-user-password. This creates and rotates the password automatically in Secrets Manager. Do NOT accept or use a plaintext password for production instances.--storage-type gp3. It's cheaper and faster than gp2 with no minimum IOPS purchase.--tags Key=created_by,Value=rds-oss-skill Key=generation_model,Value={your-model-id} (see Resource tagging below).require_secure_transport=ON for MySQL/MariaDB, rds.force_ssl=1 for PostgreSQL.--enable-cloudwatch-logs-exports so database-level security events (failed logins, suspicious queries) are centrally visible. Use ["error","slowquery","audit"] for MySQL/MariaDB (note: the audit stream requires audit logging to be enabled first, otherwise it is empty — on RDS MySQL via the MARIADB_AUDIT_PLUGIN in an Option Group, on RDS MariaDB via the built-in server audit parameters such as server_audit_logging=1 in a parameter group) and ["postgresql"] for PostgreSQL. Database logs can contain SQL with literal values and usernames, so you MUST configure a KMS key on the resulting /aws/rds/instance/<name>/* log groups to protect sensitive data at rest.Example CLI (MySQL 8.4, production-ready):
After instance creation, run the following commands to configure TLS enforcement and log group encryption (these are user-executed steps that the skill presents but does not invoke directly):
Constraints:
--manage-master-user-password for production. NEVER use --master-user-password with a plaintext password for production instances.describe-db-engine-versions rather than hardcoding a version.When creating any RDS instance (create-db-instance), ALWAYS include these tags using the RDS list-of-records --tags syntax:
--tags Key=created_by,Value=rds-oss-skill Key=generation_model,Value={your-model-id}
Example: --tags Key=created_by,Value=rds-oss-skill Key=generation_model,Value=claude-sonnet-4-20250514
Include these tags even if the user does not mention tagging, so that they can identify the resources created via this skill. If the user provides additional tags, append these to their tags rather than replacing them. The same applies when tagging via add-tags-to-resource or during blue/green deployments.
See references/verify-dependencies.md for tool and credential requirements before running workflows.
Use the Decision Guide to choose a workflow reference, the catalog presentation (broad requests), or a general-knowledge answer (out-of-scope).
Constraints:
Load the matching reference and follow its ## Tasks section.
Constraints:
modify-*, switchover-*, purchase APIs, or create-db-proxy. Allowed: create-db-instance (for new instance provisioning), describe-*, list-*, get-*, send-command for SSM prechecks.Each workflow reference includes its own tool-call examples.
These RDS-OSS-specific facts are what distinguish this skill from vanilla MySQL/PostgreSQL/MariaDB knowledge. General answers typically conflate RDS with Aurora, omit the CLI command names, or stray into action-taking when this is an advisory skill.
For "run the RDS upgrade advisor for my RDS MySQL instance", you MUST tell the user ALL of the following five facts:
aws rds describe-db-instances (NOT describe-db-clusters — RDS MySQL/MariaDB/PostgreSQL are instance-based, not cluster-based; describe-db-clusters is only for Aurora).mysql, mariadb, or postgres) — do not assume.aws rds describe-db-engine-versions — specifically using the current engine and major version as filters. This is how you enumerate the allowed upgrade paths.amazon-aurora unless the instance turns out to be Aurora.Critical workflow rule — when the named instance cannot be located: if describe-db-instances --db-instance-identifier <id> returns no results or a DBInstanceNotFoundFault, you MUST still walk through the full advisor workflow for the user — name each step (describe-db-instances, then engine detection, then describe-db-engine-versions, then version recommendation, then pre-upgrade checklist) — and explain what the output would look like at each step. DO NOT bail out asking "could you double-check the instance ID?" and stop. The user is asking for the advisor procedure, not for you to perform live discovery. If you cannot see the instance, present the workflow as a template the user can run once the correct identifier is supplied.
For "upgrade my RDS MariaDB from X to the latest version", you MUST tell the user ALL of the following six facts:
mariadb via describe-db-instances.describe-db-engine-versions (with --engine mariadb) to identify target versions, not a hand-maintained list.sql_mode changes. MariaDB reuses the MySQL precheck set because it's a MySQL fork.modify-db-instance --engine-version.For "2x db.r7g.2xlarge RDS MySQL 24/7 — buy RI or Savings Plan?", you MUST tell the user ALL of the following seven facts:
--instance-type db.r7g.2xlarge --engine mysql --num-instances 2. Print the exact command as a fenced bash block.aws rds purchase-reserved-db-instances-offering or aws savingsplans create-savings-plan commands. This is a hard ban. This skill is advisory-only and MUST NOT guide users toward executing purchases. Say "When you're ready to purchase, refer to the AWS console or CLI docs." and stop there. Do NOT try to be helpful by showing what the purchase command would look like "for reference."For "change a VARCHAR(10) column to INT on RDS MySQL 8.0 via Blue/Green", you MUST tell the user ALL of the following seven facts:
binlog_format=ROW, automated backups enabled (retention > 0), instance in available state.aws rds create-blue-green-deployment — include the exact CLI command name, not a generic description.aws rds switchover-blue-green-deployment — do not let green run in parallel with blue after the incompatible DDL. The schema divergence breaks further replication.switchover-blue-green-deployment command, even as a suggested step. Do NOT list switchover as an automatic next step in a sequential workflow — state that the switchover is a destructive action that transfers production traffic, then ask "Are you ready to switch over? I'll give you the exact CLI command to run when you confirm." Only after the user confirms should you emit the switchover-blue-green-deployment command.For "we run PgBouncer in transaction mode — would RDS Proxy add anything?", you MUST tell the user ALL of the following six facts:
Advisory skill — never modifies existing AWS resources. The only write action allowed is create-db-instance for new instance provisioning (see Production Instance Creation); everything else is read-only. Never handle credentials directly; prefer short-lived credentials.
Minimum IAM permissions required: AmazonRDSReadOnlyAccess + CloudWatchReadOnlyAccess + scoped pricing:GetProducts + savingsplans:DescribeSavingsPlansOfferingRates. For instance creation, also rds:CreateDBInstance + rds:AddTagsToResource, plus logs:CreateLogGroup if CloudWatch Logs exports are enabled. SSM prechecks also need ssm:SendCommand / ssm:GetCommandInvocation on the target bastion.
Apply these security practices in all guidance:
require_secure_transport=ON for MySQL/MariaDB, rds.force_ssl=1 for PostgreSQL).server_audit_logging=1, and the pgaudit extension for PostgreSQL) and CloudTrail for API-level audit.0.0.0.0/0.--manage-master-user-password provides automatic rotation via Secrets Manager.DatabaseConnections spikes (possible credential compromise) and FreeableMemory drops (possible resource-exhaustion attack).Do NOT grant write/admin beyond the permissions listed above to work around permission errors. Do NOT store DB passwords in SSM parameters or command text — use Secrets Manager and retrieve the secret inside the command.
Access denied. Attach the read-only policies above.
Expired credentials. Refresh, or fall back to --offline for commitment pricing.
Timeouts / throttling. Retry once, then narrow scope. SSM precheck timeouts on large schemas: switch to direct connection or user-runs-script. RDS Data API is not available for standalone RDS.
Resource not found. Verify region/ID; confirm it's not an Aurora cluster (describe-db-clusters). Empty RI/DSP offerings — fall back to offline.
User asks to execute a change. Advisory skill — modifications to existing resources happen via the AWS console or user-run CLI.
Aurora question. Route to amazon-aurora. See RDS vs Aurora above.
Oracle / SQL Server / Db2 question. Route to rds-oracle, rds-sqlserver, or rds-db2.
# Create a custom parameter group with TLS enforcement (MySQL example)
aws rds create-db-parameter-group --db-parameter-group-family mysql8.4 \
--db-parameter-group-name <name>-tls --description "TLS enforced"
aws rds modify-db-parameter-group --db-parameter-group-name <name>-tls \
--parameters "ParameterName=require_secure_transport,ParameterValue=ON,ApplyMethod=pending-reboot"
aws rds modify-db-instance --db-instance-identifier <name> \
--db-parameter-group-name <name>-tls --apply-immediately
# Encrypt CloudWatch Logs log groups with KMS
aws logs associate-kms-key --log-group-name /aws/rds/instance/<name>/error --kms-key-id <kms-key-arn>
aws logs associate-kms-key --log-group-name /aws/rds/instance/<name>/slowquery --kms-key-id <kms-key-arn>