{question}
What causes backup to fail with the error "x509: certificate signed by unknown authority"?
{question}
{answer}
The error "x509: certificate signed by unknown authority" indicates that the backup is trying to connect to an S3 compatible endpoint, presenting an SSL certificate that a Certification Authority issued that the host does not trust.
Example of the error:
memsql> BACKUP DATABASE test TO S3 "production/backup" CONFIG '{"region":"us-east1","compatibility_mode":true,"endpoint_url":"https://<end point>:3000"}' CREDENTIALS '{"aws_access_key_id": "******" ,"aws_secret_access_key": "******"}';
ERROR 2298 (HY000): Could not perform remote backup. RequestError: send request failed
caused by: Get https://<end point>:3000/production/backup?max-keys=1: x509: certificate signed by unknown authority
There are a few options available to fix this issue:
- Use a trusted certificate in the S3 compatible storage
- Connect using HTTP instead of HTTPS
- Disable the certificate verification
Click the below links to learn about parameters that can be passed with BACKUP and RESTORE commands:
{answer}