Freeradius can't connect to MySQL 8.0 from Debian Buster

Mark Antony mark.antony.4 at protonmail.com
Sun Mar 14 10:02:53 CET 2021


Hello,

I have FreeRADIUS Version 3.0.17 is installed that comes by default with Debian 10.
When Freeradius is trying to connect to a remote MySQL 8.0 server, I get this error:

rlm_sql_mysql: libmysql version: 10.3.27
mysql {
tls {
}
warnings = "auto"
}
rlm_sql (sql): Attempting to connect to database "rad_db"
rlm_sql (sql): Initialising connection pool
pool {
start = 5
min = 3
max = 32
spare = 10
uses = 0
lifetime = 0
cleanup_interval = 30
idle_timeout = 60
retry_delay = 30
spread = no
}
rlm_sql (sql): Opening additional connection (0), 1 of 32 pending slots used
rlm_sql_mysql: Starting connect to MySQL server
rlm_sql_mysql: Couldn't connect to MySQL server myuser at 18.133.xxx.xxx:rad_db
rlm_sql_mysql: MySQL error: Plugin caching_sha2_password could not be loaded: /usr/lib/x86_64-linux-gnu/mariadb19/plugin/caching_sha2_password.so: cannot open shared object file: No such file or directory
rlm_sql_mysql: Socket destructor called, closing socket
rlm_sql (sql): Opening connection failed (0)
rlm_sql (sql): Removing connection pool
/etc/freeradius/3.0/mods-enabled/sql[20]: Instantiation failed for module "sql"

Debian buster doesn't come with MySQL 8.0. So I have installed it manually:
MYSQL_8_file="mysql-apt-config_0.8.16-1_all.deb"
apt install gnupg -y
wget -c https://dev.mysql.com/get/${MYSQL_8_file}
dpkg -i ${MYSQL_8_file}
apt update
apt install mysql-client libmysqlclient-dev

The error message indicated that FreeRadius is looking for mariadb plugins.
I checked and there is no caching_sha2_password.so in the path /usr/lib/x86_64-linux-gnu/mariadb19/plugin/.

Any suggestions, please?


More information about the Freeradius-Users mailing list