- Mais recentes
- Mais votos
- Mais comentários
Sorry for the delay, but I have an answer from AWS Support now. Not what I expected at all - restoring via CLI actually works!
I've just restored an old Postgres 9.3.5 snapshot successfully using:
aws rds restore-db-instance-from-db-snapshot
--db-instance-identifier mynewdbinstance
--db-snapshot-identifier mydbsnapshot
--db-subnet-group mysubnetgroup
See https://docs.aws.amazon.com/cli/latest/reference/rds/restore-db-instance-from-db-snapshot.html
Mine immediately auto-upgraded to 9.3.25 which right now is still in progress. It may auto-upgrade straight away all the way to v12, or that might happen later if I don't upgrade manually to something else. Note sure yet.
Hi, you can upgrade the engine version of your snapshot - https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_UpgradeDBSnapshot.PostgreSQL.html.
That's a great suggestion. However, the "Upgrade snapshot" option is greyed out and there is a note on the page that says "You can't upgrade automated DB snapshots that are created during the automated backup process."
Unfortunately, I only have automated backups --- the last manual snapshot is too old to be useful :(
OK, I copied the automated snapshot, which created a manual snapshot. Then I tried to upgrade it, but under the "New engine version" field, the dropdown list is empty, and there's a message below stating "No upgrades are available for the snapshot at this time."
Thanks for raising this, I think I need to revisit how restorable our compliance backups (up to 7 years old) really are.
https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_UpgradeDBSnapshot.PostgreSQL.html says "For the list of engine versions that are available for upgrading a DB snapshot, see https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_UpgradeDBInstance.PostgreSQL.html#USER_UpgradeDBInstance.PostgreSQL.MajorVersion".
There, it doesn't list anything older than 9.6.1.
This smells bad to me, I'm going to raise a support case and escalate as needed. I'll comment back here if I find out more.
Oof, missed by a few engine versions :) Thank you for raising a support case; that's very kind of you. Please let me know if you find out anything.
Conteúdo relevante
- AWS OFICIALAtualizada há 2 meses
- AWS OFICIALAtualizada há um ano
- AWS OFICIALAtualizada há 2 anos
Thank you so much for looking into this. For some reason, this is still not working for me. If I just run your command, it gives the following error:
"An error occurred (InvalidParameterCombination) when calling the RestoreDBInstanceFromDBSnapshot operation: RDS does not support creating a DB instance with the following combination: DBInstanceClass=db.m1.small, Engine=postgres, EngineVersion=9.3.25, LicenseModel=postgresql-license. For supported combinations of instance class and database engine version, see the documentation."
Of course, this is because DBInstanceClass db.m1.small is now deprecated. But even if I add "--db-instance-class db.m6i.large" or something to the command, I still get the same error with the new instance class. For some reason, it's still trying to restore with EngineVersion 9.3.25.
I also tried using AWS CLI to upgrade the snapshot version using modify-db-snapshot, but it says:
"An error occurred (InvalidParameterCombination) when calling the ModifyDBSnapshot operation: You can't upgrade the DB snapshot from the engine version 9.3.25 to 12.6."
Any ideas as to what I'm doing wrong?
My 9.3.5 DB restored and immediately upgraded to 9.3.25, where it's stopped for now, so I think yours restoring as 9.3.25 is fine.
Have a look at https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html - it looks like db,m6i won't work with 9.3. Mine restored to db.r3 OK, which according to that table makes sense.
Oh wow. That did the trick. Somehow AWS wasn't picking db.r3 automatically for me. I tried a whole bunch of instance classes, but none worked. After looking at your comment, I tried adding "--db-instance-class db.r3.large" manually and IT RESTORED! I can't thank you enough, good-hearted stranger :)
No problem, glad to help! It's been useful for us too to verify how restorable our compliance backups are. If you get around to it, it would be great if you could hit "Accept" on my answer, thanks.
Update - here's a blog article about this after more investigation and feedback from AWS. https://www.linkedin.com/pulse/can-you-really-restore-all-those-old-aws-rds-database-steve-kinsman
Part 2 will be published soon.