Details
-
Bug
-
Status: In Review (View Workflow)
-
Minor
-
Resolution: Unresolved
-
10.5.27
-
None
Description
MariaDB Server 10.5 is using a buggy version of libmarias3 (3846890) * in which the value of *MS3_OPT_FORCE_PROTOCOL_VERSION is overwriting the wrong variable hence setting s3_protocol_version won't have any effect.
When setting s3_host_name to an actual hostname instead of an IP, protocol_version in libmarias3 will default to 2, which is not the case with every S3 provider resulting in wrong request headers.
The error one will encounter is "Couldn't resolve host name" when the server will send requests to the S3 provider.
This bug was solved in libmarias3 -> 289108f.
$ git diff 3846890 289108f |
diff --git a/src/marias3.c b/src/marias3.c
|
index 74d7233..7a07bdd 100644 |
--- a/src/marias3.c
|
+++ b/src/marias3.c
|
@@ -617,7 +617,7 @@ uint8_t ms3_set_option(ms3_st *ms3, ms3_set_option_t option, void *value) |
return MS3_ERR_PARAMETER; |
}
|
|
- ms3->list_version = protocol_version;
|
+ ms3->protocol_version = protocol_version;
|
break; |
}
|
|
Steps to reproduce the issue on 10.5
docker run -it --rm quay.io/mariadb-foundation/bb-worker:ubuntu20.04 bash |
clone MariaDB Server -> branch==10.5 |
|
sh -c 'cmake . -DCMAKE_BUILD_TYPE=Debug -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER=g++ -DPLUGIN_TOKUDB=NO -DPLUGIN_MROONGA=NO -DPLUGIN_SPIDER=YES -DPLUGIN_OQGRAPH=NO -DPLUGIN_PERFSCHEMA=YES -DPLUGIN_SPHINX=NO -DWITH_DBUG_TRACE=OFF -DEXTRA_DEBUG=ON && make -j24' |
|
export S3_PROTOCOL_VERSION=Original
|
export S3_BUCKET=amd64-ubuntu-2004-35971 |
export S3_HOST_NAME=minio.mariadb.org
|
export S3_PORT=443 |
export S3_USE_HTTP=OFF
|
export S3_ACCESS_KEY=#access_key#
|
export S3_SECRET_KEY=#secret_key#
|
|
sh -c '
|
cd mysql-test &&
|
exec perl mysql-test-run.pl --verbose-restart --force --retry=3 --max-save-core=2 --max-save-datadir=10 --parallel=$(expr 7 \* 2) --suite=s3; |
'
|
Every test yields "Couldn't resolve host name". |
|
CURRENT_TEST: s3.basic
|
mysqltest: At line 18: query 'alter table t1 engine=s3' failed: 3: Got error from put_object(s3_test_ad103c5bb88311efa5520242ac110002/t1/frm): 5 Couldn't resolve host name |
Attachments
Activity
Transition | Time In Source Status | Execution Times |
---|
|
32d 6h 25m | 1 |
|
6s | 1 |