MYSQL的设置
groupadd -g 200 mysql
useradd -u 200 -g mysql -d /usr/local/mysql/data -M mysql
tar zxvf mysql-5.0.22.tar.gz -C /usr/src
cd /usr/src/mysql-5.0.22
./configure --prefix=/usr/local/mysql
make
make install
cp ./support-files/http://www.doczj.com/doc/7f26c159be23482fb5da4c04.htmlf /etc/http://www.doczj.com/doc/7f26c159be23482fb5da4c04.htmlf
cd /usr/local/mysql/bin
./mysql_install_db
chown -R mysql:mysql /usr/local/mysql
./mysqld_safe --user=mysql &
./mysql -u root –p
Freeradius的设置
tar xvfz freeradius-1.1.0.tar.gz
cd freeradius-1.1.0
./configure
make
make install
/usr/local/sbin/radiusd –X
adtest test test localhost 0 testing123 发认证请求,得到回应表示Radius服务器工作正常。
然后更改freeradius的配置文件,找到/usr/local/etc/raddb 下,分别更改radiusd.conf,sql.conf,Users
vi users
Auth-Type = Local,Fall-Through = 1
mysql -uroot -prootpass radius < mysql.sql
――radiusd.conf
在authorize {
……
sql(去掉前面的#)
……
}
在accouting {
….
sql (去掉前面的#)
…
}
――sql.conf
vi sql.conf
注释掉缺省的sql_user_name = "%{User-Name}",开放原来注释掉的sql_user_name =