fbpx

Add space to aws MySQL RDS using awscli

To add storage space to an Amazon RDS for MySQL instance, you can use the modify-db-instance command of the AWS CLI. This command allows you to modify the settings and properties of an existing DB instance.

To increase the storage space of a DB instance, you need to specify the new AllocatedStorage parameter, which specifies the amount of storage (in gibibytes) to allocate to the instance. You can also specify the new StorageType parameter to specify the type of storage to use (e.g. gp2 for General Purpose SSD).

Here is an example of how you might use the modify-db-instance command to increase the storage space of a DB instance named mydbinstance:​

				
					aws rds modify-db-instance \
    --db-instance-identifier mydbinstance \
    --allocated-storage 100 \
    --storage-type gp2

				
			

This command increases the storage space of the mydbinstance DB instance to 100 GiB, using General Purpose SSD storage. It does not modify any other settings or properties of the instance.

Note that increasing the storage space of a DB instance can cause an outage, as the instance will be restarted to apply the changes. You should plan for this outage and ensure that it will not cause any disruption to your application.

For more information about the modify-db-instance command and the other available RDS commands, see the https://docs.aws.amazon.com/cli/latest/reference/rds/index.html

Share:

Facebook
Twitter
Pinterest
LinkedIn

Social Media

Most Popular

Get The Latest Updates

Subscribe To Our Weekly Newsletter

No spam, notifications only about new products, updates.

Categories