AWS RDS

AWS RDS #

Cannot restore snapshot from console #

If restoring a snapshot from console is not working, do it from the cli . for example:

aws rds restore-db-instance-from-db-snapshot ⮠
    --db-instance-identifier <INSTANCE_IDENTIFIER> ⮠ 
    --db-snapshot-identifier "<SRC_SNAPSHOT_ARN>" ⮠
    --region eu-west-1 ⮠
    --db-subnet-group-name <DB_SUBNET_GROUP_ID>

Update instance security group from CLI #

aws rds modify-db-instance ⮠ 
    --db-instance-identifier <INSTANCE_IDENTIFIER> ⮠ 
    --region eu-west-1 ⮠ 
    --vpc-security-group-ids <VPC_SEC_GROUP_ID>

RDS instance storage type compatibility matrix #

To upgrade mssql instances to major versions #

  1. Update to latest version that supports the current instance type
    aws rds modify-db-instance ⮠ 
      --db-instance-identifier <INSTANCE_IDENTIFIER> ⮠ 
      --region eu-west-1 ⮠ 
      --engine-version 14.00.3421.10.v1 ⮠ 
      --allow-major-version-upgrade ⮠ 
      --apply-immediately
    
  2. Upgrade the instance type to the one that is supported by the desired version
    aws rds modify-db-instance ⮠ 
      --db-instance-identifier <INSTANCE_IDENTIFIER> ⮠ 
      --region eu-west-1 ⮠ 
      --db-instance-class db.t3.small ⮠ 
      --apply-immediately
    
  3. upgrade to the latest version of mssql
    aws rds modify-db-instance ⮠ 
      --db-instance-identifier <INSTANCE_IDENTIFIER> ⮠ 
      --region eu-west-1 ⮠ 
      --engine-version 15.00.4198.2.v1 ⮠ 
      --allow-major-version-upgrade ⮠ 
      --apply-immediately
    

Use performance insights to find slow queries #

Troubleshoot Slow RDS SQL Servers with Performance Insights

MySql 8 - The table ‘/rdsdbdata/tmp/#sql…’ is full #

Use the TempTable storage engine on Amazon RDS for MySQL and Amazon Aurora MySQL