gpdr config backup got failed with ERROR: [029]: expected protocol 'https'
search cancel

gpdr config backup got failed with ERROR: [029]: expected protocol 'https'

book

Article ID: 297072

calendar_today

Updated On:

Products

VMware Tanzu Greenplum

Issue/Introduction

There are requirement to use s3 storage with non-TLS protocol when gpdr does backup data into s3 storage. However the following error occurs in case of running gpdr configure backup command to prepare s3 backup environment.
$ gpdr configure backup --config-file /usr/local/gpdr/templates/s3_config_file.yml
~~ snip
host: mdw | port: 5432 | contentId: -1
exit status 29; ERROR: [029]: expected protocol 'https' in URL 'http://xxx.xx.x.xx:9000'
host: sdw1 | port: 6000 | contentId: 0
exit status 29; ERROR: [029]: expected protocol 'https' in URL 'http://xxx.xx.x.xx:9000'
host: sdw1 | port: 6001 | contentId: 1
exit status 29; ERROR: [029]: expected protocol 'https' in URL 'http://xxx.xx.x.xx:9000'
~~ snip
20231024:22:37:24 gpdr:gpadmin:mdw:021212-[ERROR]:-error occurred while configuring for backup: could not configure stanza for one or several segments
Currently s3_config_file.yml is configured for gpdr and s3 storage as below.
# the type of storage used for the repository
type: s3

# absolute path to where backups and archives will be stored in the
# S3 bucket
path: /data

# S3 repository region where the bucket was created
s3_region: s3gpdr

# S3 repository endpoint for the selected S3 region
s3_endpoint: http://xxx.xx.xx.xx:9000

# S3 bucket used for the repository
s3_bucket: data

# S3 ID to access the S3 bucket location
s3_key: xxxxxxxxxxxxxxxxxxxxxxx

# S3 passcode for the S3 ID to access the S3 bucket location
s3_key_secret: xxxxxxxxxxxxxxxxxxxxxxxxxx

##################################################
# Optional configurations
##################################################

# host - Connect to bucket.endpoint host (default)
# path - Connect to endpoint host and prepend bucket to URIs
s3_uri_style: host

# Enable/disable verification of the storage server TLS certificate
# y - Verify storage server TLS certificate (default)
# n - Disable storage server TLS certificate verification
storage_verify_tls: n
What's the cause how could it be resolved?

Environment

Product Version: 6.25
OS: RHEL or CentOS 7.x and 8.

Resolution

The ERROR: [XXX]: expected protocol 'https' in URL could be avoided by setting the value of s3_endpoint option from http://xxxx.xx.xx.xx;9000 to xxx.xx.xx.xx:9000 as removing http:// in s3_config_file.yml. However there would be other errors such as unknown protocol. Because pgbackrest inside of gpdr does not support non-TLS protocol for s3 storage.

Actually there are requests to solve this error in the pgbackrest upstream site[1] and the pgbackrest maintainers have accepted the idea.
However there has not been to deal with this request and not to add support yet.

[ PgBackRest Upstream ]
[1] https://github.com/pgbackrest/pgbackrest/issues/1590