pingcap / tidb

TiDB - the open-source, cloud-native, distributed SQL database designed for modern applications.
https://pingcap.com
Apache License 2.0
37.23k stars 5.84k forks source link

Use "Tencent Cloud Object Storage" for Restore Data from S3-Compatible Storage Fail #55568

Open shezhangjun opened 2 months ago

shezhangjun commented 2 months ago

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

Use "Tencent Cloud Object Storage" for Restore Data from S3-Compatible Storage Using BR

2. What did you expect to see? (Required)

It will be Normal

3. What did you see instead (Required)

PathStyleDomainForbidden

The bucket you are attempting to access must be addressed using COS virtual-styled domain.

4. What is your TiDB version? (Required)

8.1.0

5.How to fix

br/pkg/storage/s3.go #L175 Need add if options.Provider == "tencent" use options.ForcePathStyle = false

BornChanger commented 1 week ago

@shezhangjun could you please contribute the pr? thx