"Container Name" Unused when Configuring ADBR Backups for Azure
search cancel

"Container Name" Unused when Configuring ADBR Backups for Azure

book

Article ID: 293311

calendar_today

Updated On:

Products

VMware Tanzu SQL

Issue/Introduction

When configuring backups for MySQL to an Azure container, the Container Name which is a required attribute is not used. The Bucket Path is used instead. The error seen is similar to:
[ERROR] 2021/10/18 22:07:42 list.go:65: failed to list backups for GUID: -> github.com/Azure/azure-storage-blob-go/azblob.newStorageError, /var/vcap/data/compile/adbr-api/adbr-api/vendor/github.com/Azure/azure-storage-blob-go/azblob/zc_storage_error.go:42
===== RESPONSE ERROR (ServiceCode=InvalidQueryParameterValue) ===== 
Description=Value for one of the query parameters specified in the request URI is invalid. 
RequestId:GUID
Time:2021-10-18T22:07:42.1950788Z, Details: 
   Code: InvalidQueryParameterValue 
   QueryParameterName: prefix 
   QueryParameterValue: containerName/p.mysql/service-instance_GUID 
   Reason: Cannot contain slash. 
   GET https://blobstore.base.url?comp=list&prefix=containerName%2Fp.mysql%2Fservice-instance_GUID=container&timeout=61 
   Authorization: REDACTED 
   User-Agent: [Azure-Storage/0.10 (go1.14.4; linux)] 
   X-Ms-Client-Request-Id: [GUID] 
   X-Ms-Date: [Mon, 18 Oct 2021 22:07:42 GMT] 
   X-Ms-Version: [2019-02-02] 
   -------------------------------------------------------------------------------- 
   RESPONSE Status: 400 Value for one of the query parameters specified in the request URI is invalid. 
   Content-Length: [497] 
   Content-Type: [application/xml] 
   Date: [Mon, 18 Oct 2021 22:07:41 GMT] 
   Server: [Windows-Azure-Blob/1.0 Microsoft-HTTPAPI/2.0] 
   X-Ms-Client-Request-Id: [GUID] 
   X-Ms-Error-Code: [InvalidQueryParameterValue] 
   X-Ms-Request-Id: [GUID] 
   X-Ms-Version: [2019-02-02]


Environment

Product Version: 2.10

Resolution

This is a bug in current versions of the MySQL tile. The workaround for this issue is to configure Blob Store Base URL with the hostname and Container Name like so:
blobstore.base.url/containerName 

The Bucket Path may be left empty, unless an additional prefix on the blob names is desired. The reason the error is occurring (shown above) is because the API call is trying to list containers rather than objects within a container. This is because no valid container was specified by the Azure URL constructed by the ADBR blob store code.

This means the Container Name must be specified twice. Once for the required Container Name field and again in the Blob Store Base URL field.