Freeradius Y MYSQL
Hello,
I am working with freeradius and MYSQL. My goal is to authenticate users through the radius server with my users' database in mysql. I already have all the users created in mysql but when I try to establish an authentication I get the error that freeradius cannot establish the connection with the database.
I am working with freeradius and MYSQL. My goal is to authenticate users through the radius server with my users' database in mysql. I already have all the users created in mysql but when I try to establish an authentication I get the error that freeradius cannot establish the connection with the database.
Bitte markiere auch die Kommentare, die zur Lösung des Beitrags beigetragen haben
Content-ID: 669785
Url: https://administrator.de/contentid/669785
Ausgedruckt am: 26.11.2024 um 17:11 Uhr
3 Kommentare
Neuester Kommentar
By default the MySQL Database is accepting local queries only. You have to grand privileges to the user@% (all localtions), then your radius server is not at the same computer like the database. If its a windows MySQL server then the TCPIP protocol is disabled by default in the MySQL server settings.
Take a look at a local tutorial:
Freeradius with database and GUI which describes all steps in detail. Use a translator to read it in English.
In case you have the database on a separate server the most important config is under /etc/freeradius/3.0/mods-available/sql
Instead of "localhost" in the connection you have to setup the database IP address here. In case you need to encrypt the session you need to maybe activate all the TLS settings in the connection screenshot above. You should make sure that a ping between radius and database works and proofs a running IP connection. Database ports should be open in a firewall. There are also some easy checks for a remote client connectivity:
https://mariadb.com/kb/en/configuring-mariadb-for-remote-client-access/
So far the debug output looks quite ok for the Radius authentication itself but looks like there is no network connection to the database and therefor the user "user1" could not be looked up and fails authentication.
Freeradius with database and GUI which describes all steps in detail. Use a translator to read it in English.
In case you have the database on a separate server the most important config is under /etc/freeradius/3.0/mods-available/sql
Instead of "localhost" in the connection you have to setup the database IP address here. In case you need to encrypt the session you need to maybe activate all the TLS settings in the connection screenshot above. You should make sure that a ping between radius and database works and proofs a running IP connection. Database ports should be open in a firewall. There are also some easy checks for a remote client connectivity:
https://mariadb.com/kb/en/configuring-mariadb-for-remote-client-access/
So far the debug output looks quite ok for the Radius authentication itself but looks like there is no network connection to the database and therefor the user "user1" could not be looked up and fails authentication.
Serie: Freeradius Y MYSQL 1
Freeradius Y MYSQL (englisch)3