What Should I Do If My Data Exceeds the Available Storage of a GaussDB Instance?
Symptom
There is not enough storage available for a GaussDB instance and the instance becomes read-only, so applications cannot write any data to the instance.
Possible Causes
- Increased workload data
- Too much data being stored
- Too many logs generated due to a large number of transactions and write operations
- Too many temporary files generated due to a large number of sorting queries executed by applications
Solution
- For insufficient storage caused by increased workload data, scale up storage space.
If the original storage has reached the maximum, upgrade the instance specifications first.
- If too much data is stored, delete unnecessary historical data.
- If your instance becomes read-only, submit a service ticket to contact technical support to remove the read-only restriction first.
- To clear up space, you can optimize tables with a high fragmentation rate during off-peak hours.
To delete data of an entire table, use the DROP or TRUNCATE statement. To delete part of table data, use the DELETE statement.
- If log files occupy too much storage, clear log files to release storage space.
- If temporary files generated by sorting queries occupy too much storage space, optimize your SQL statements.