- Newest
- Most votes
- Most comments
The issue you're experiencing with missing tables in the information_schema is a known problem that can occur during database migrations or upgrades, especially when moving from MySQL 5.7 to MySQL 8. This situation where tables appear to exist in the InnoDB data dictionary but not in the actual database can be challenging to resolve in an Amazon RDS environment due to limited access to the underlying file system.
Here are some steps you can try to address this issue:
-
First, attempt to drop the table using the IF EXISTS clause, which you've already tried. While this didn't resolve the issue, it's always a good first step.
-
Try rebuilding the table using the ALTER TABLE command:
ALTER TABLE MY_DATABASE
._SomeVeryOldTable
ENGINE=INNODB;
This command might force InnoDB to rebuild the table metadata and potentially resolve the discrepancy.
- If the above doesn't work, you can try to create a new table with a different name but the same structure as the problematic table, then attempt to rename it to the original name:
CREATE TABLE MY_DATABASE
._SomeVeryOldTable_new
(...);
RENAME TABLE MY_DATABASE
._SomeVeryOldTable_new
TO MY_DATABASE
._SomeVeryOldTable
;
-
If these methods don't work, you may need to involve AWS Support. They have access to lower-level tools and can potentially help remove the orphaned table entries from the InnoDB data dictionary.
-
As a last resort, you might consider dumping the data from your current database (excluding the problematic tables), creating a new RDS instance with MySQL 8, and then importing the data. This approach bypasses the upgrade process entirely and creates a clean MySQL 8 environment.
It's important to note that these issues can be complex, especially in a managed service like Amazon RDS where you don't have direct access to the file system. If you continue to face difficulties, don't hesitate to reach out to AWS Support for assistance. They can provide more targeted solutions based on your specific RDS setup and the exact nature of the problem.
Remember to always take backups before attempting any of these operations, and if possible, test these solutions in a non-production environment first.
Sources
Resolve storage full issues on DB instances | AWS re:Post
Table not found when using Athena with Amazon QuickSight - Amazon QuickSight
Relevant content
- asked 7 months ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 2 months ago
- AWS OFFICIALUpdated 4 months ago
none of the point 1-3 worked. How do I get AWS support involved without having to pay for support? I might look at DMS in order to solve this, not sure if it will be of any help. It's just a lot of infra just to remove 2 tables from the innodb schema
You don't need to pay for support. it depends on your account plan. but in general you don't need to pay