CentOS6.5 build freeradius Server
Build freeradius service # yum install freeradius-mysql freeradius-utils mysql-server-y
Start mysql
# Service mysqld start
Set mysql password and Security Settings
/Usr/bin/mysql_secure_installation (execute the script)
Create and authorize a database
# Mysql-uroot-p
Mysql-> create database radius;
Mysql-> grant all privileges on radius. * TO radius @ localhost identified by "radpass ";
Mysql-> flush privileges;
Import Data Tables
Mysql> use radius;
Mysql> SOURCE/etc/raddb/SQL/mysql/schema. SQL;
Mysql> exit;
Edit freeradius configuration file and enable SQL Authentication
File 1:/etc/raddb/SQL. conf
# Connection info:
Server = "localhost"
# Port = 3306
Login = "radius" # mysql login Username
Password = "radpass" # password of the above logon Username
# Database table configuration for everything doesn't Oracle
Radius_db = "radius"
File 2:/etc/raddb/radiusd. conf
$ INCLUDE SQL. conf # Remove the preceding comment
File 3:/etc/raddb/sites-available/default
Authorize {} accounting {} session {} remove the comments before the SQL
/Etc/raddb/sites-available/inner-tunnel
Authorize {} session {} removes the comments before the SQL
File 4:/etc/raddb/clients. conf
Secret = testing123 this key is too simple and can be a random string. For example:
Secret = 3c23498n349c3yt290y93b4t3
Modify the IP address of freeradius client.
Start freeradius service:
Service radiusd restart
Add User information to the local test:
Mysql-uroot-p
Use radius;
Insert into radcheck (username, attribute, op, value) values ('test', 'user-password', ': =', 'test ');
Exit;
Radtest test 127.0.0.1 0 testing123
If you see "rad_recv: Access-Accept", the authentication is successful.