Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

📝 (RDSDiskSpaceLimit.md): update runbook RDSDiskSpaceLimit #28

Merged
merged 2 commits into from
Jul 4, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 14 additions & 3 deletions content/runbooks/rds/RDSDiskSpaceLimit.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,14 @@ You must avoid reaching no disk space left situation.
{{% aws-rds-storage-increase-limitations %}}
{{< /hint >}}

1. Determine the minimum storage for the increase
1. Set AWS_PROFILE

```bash
export AWS_PROFILE=<AWS account>
```

2. Determine the minimum storage for the increase
💡 RDS requires a minimal storage increase of 10%

```bash
INSTANCE_IDENTIFIER=<replace with the RDS instance identifier>
Expand All @@ -84,16 +91,20 @@ You must avoid reaching no disk space left situation.
| jq -r '{"Current IOPS": .DBInstances[0].Iops, "Current Storage Limit": .DBInstances[0].AllocatedStorage, "New minimum storage size": ((.DBInstances[0].AllocatedStorage|tonumber)+(.DBInstances[0].AllocatedStorage|tonumber*0.1|floor))}'
```

1. Increase storage:
3. Increase storage:

```bash
NEW_ALLOCATED_STORAGE=<replace with new allocated storage in GB>
```

```bash
aws rds modify-db-instance --db-instance-identifier ${RDS_INSTANCE} --allocated-storage ${INSTANCE_IDENTIFIER} --apply-immediately \
aws rds modify-db-instance --db-instance-identifier ${INSTANCE_IDENTIFIER} --allocated-storage ${NEW_ALLOCATED_STORAGE} --apply-immediately \
| jq .DBInstance.PendingModifiedValues
```

❗ If the RDS instance has replicas instances (replica or reporting), you must repeat the operation for all replicas to keep the same configuration between instances

4. Backport changes in Terraform

## Additional resources

Expand Down