MySQL SSL connection error on Ubuntu 20.04

Hello,

I am testing connecting to MySQL using R on Ubuntu 20.04 and keep getting the following error when using RMySQL.
It works when using the native mysql client.

Error in R:

Loading required package: DBI
Error in .local(drv, ...) :
  Failed to connect to database: Error: SSL connection error: SSL_CTX_set_default_verify_paths failed
Calls: dbConnect -> dbConnect -> .local -> .Call
Execution halted

Any guidance would be appreciated.

The following appears to work:

library("RMySQL")
con <- dbConnect(RMySQL::MySQL(), host = "aurora-db-in-aws.eu-west-1.rds.amazonaws.com",user = "username", password = "password", default.file = "/etc/mysql/conf.d/mysql.cnf", group="mysql")
dbDisconnect(con)

contents of mysql.conf

[mysql]
ssl_cipher = "DHE-RSA-AES128-GCM-SHA256:AES128-SHA:@SECLEVEL=1"

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.