Bug #109735 No way to set the Region for S3 backups
Submitted: 23 Jan 2023 10:21 Modified: 23 May 12:51
Reporter: James Walker Email Updates:
Status: No Feedback Impact on me:
Category:MySQL Operator Severity:S3 (Non-critical)
Version:8.0.32-2.0.8 OS:Any
Assigned to: MySQL Verification Team CPU Architecture:Any

[23 Jan 2023 10:21] James Walker
There does not seem to be a way to set the AWS region to upload S3 backups to.

When manually setting the region by changing the endpoint URL (e.g. https://s3.eu-west-2.amazonaws.com), the backups terminate by complaining

> Failed to list objects using prefix 'mysql-default230123095935/': The authorization header is malformed; the region 'us-east-1' is wrong; expecting 'eu-west-2' (400)

Putting `region = eu-west-2` into the data in the credentials secret has no effect.

I see this as a pretty glaring omission.

How to repeat:

Suggested fix:
Add a new option e.g. BackupProfile.storage.s3.region to set the AWS region to upload to.
[24 Jan 2023 7:54] James Walker
(Similarly, there's no way to set the region when restoring a backup from S3, using initDB.dump.storage.s3 either.)
[27 Jan 2023 11:55] James Walker
I've realised there is a workaround:

You can set backupProfile.dumpInstance.dumpOptions.s3Region which will get passed directly to the mysqlsh's utils.dump_instance() call.

But this doesn't feel particularly clear, and could with being called out in the docs at least.
[23 Apr 12:51] MySQL Verification Team
Hello James Walker,

Thank you for the bug report.
Please upgrade to latest version and report us back if issue persist even in latest version along with the details. Thank you.

Ashwini Patil
[24 May 1:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".