Decreasing the Storage of a DB System
You cannot decrease the storage size of a DB system through the Console or CLI. You must use the export and import method to migrate the data to a newly created DB system with a smaller storage size.
Note
The allocated storage size affects the storage performance of the DB system. The initial storage size of the new DB system determines the number of storage volume and can restrict the storage performance if the storage size is increased tremendously later. See DB System Storage.
The allocated storage size affects the storage performance of the DB system. The initial storage size of the new DB system determines the number of storage volume and can restrict the storage performance if the storage size is increased tremendously later. See DB System Storage.
Using Export and Import Method
To decrease the storage size of a DB system, export the data of the DB system and import it into a new DB system created with a smaller storage size.
Do the following to decrease the storage of a DB system:
- Stop all applications that may change the data stored in the DB system.
- Export the DB system to an Object Storage bucket. See Exporting a MySQL Instance.
- Create a new DB system with a smaller storage size and import the data. See Importing Using the Data Import Feature.
- Restart and switch all applications to connect to the new DB system endpoint.
- Delete the original DB system if it is no longer required.