RSA public key is not available client side

I am trying to load the output of already created question and am getting output like below:
image

RSA public key is not available client side (option serverRsaPublicKeyFile not set)

When trying to load Dashboard, some warnings are happening as well.
Screenshot (123)

Here is the Diagnostic Info:
{
"browser-info": {
"language": "en-US",
"platform": "Win32",
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.0.0 Safari/537.36",
"vendor": "Google Inc."
},
"system-info": {
"file.encoding": "UTF-8",
"java.runtime.name": "OpenJDK Runtime Environment",
"java.runtime.version": "11.0.17+8-LTS",
"java.vendor": "Red Hat, Inc.",
"java.vendor.url": "https://www.redhat.com/",
"java.version": "11.0.17",
"java.vm.name": "OpenJDK 64-Bit Server VM",
"java.vm.version": "11.0.17+8-LTS",
"os.name": "Linux",
"os.version": "3.10.0-1160.80.1.el7.x86_64",
"user.language": "en",
"user.timezone": "UTC"
},
"metabase-info": {
"databases": [
"h2",
"mysql"
],
"hosting-env": "unknown",
"application-database": "h2",
"application-database-details": {
"database": {
"name": "H2",
"version": "1.4.197 (2018-03-18)"
},
"jdbc-driver": {
"name": "H2 JDBC Driver",
"version": "1.4.197 (2018-03-18)"
}
},
"run-mode": "prod",
"version": {
"date": "2022-12-07",
"tag": "v0.45.1",
"branch": "release-x.45.x",
"hash": "019d31c"
},
"settings": {
"report-timezone": null
}
}
}

Does your Database require SSH or SSL to connect to?

If you go to Admin -> Databases -> Your Database and press Save are you able to save? Seems like something changed on your DB

I am running Metabase and it's Mysql Database on GCP, where for establishing connection, we use public and private keys.

Was this changed recently cause it seems that the issue is with the key ... As i said If you go to Admin -> Databases -> Your Database Connection and press Save are you able to save?

After 1-2 hrs of that reported issue, it came online automatically. Now it is working fine, able to fetch data from Database.

The VM instances we restarted due to some reasons, just after that we observed RSA Public Key error. May be the restart would have caused the problem.

I received this message after I fixed another problem, the request for mysqladmin flush-hosts.

If I access one time directly from the server A (where Metabase is) to the server B (where MySQL is) via SSH shell and the CLI mysql client, with the same user used by Metabase, the problem disappear.

I don't know why and this is a bit disappointing, but it resolve the problem.

I faced this issue again last week after MySQL db container got restarted. This time it wasn't solving automatically, so I done the following to resolve it.

  • Enabled SSL

  • Added additional JDBC property,

trustServerCertificate=true

Hope this helps..!!

I have tried to access mysql docker container and using SSL certificate with trustServerCertificate=true helped me, without that I wasn't able to access the database. Thank you very much!