mysql issue

andy andy at shady.org
Fri May 26 11:18:24 CEST 2006


On Thu, May 25, 2006 at 05:20:03PM -0400, Alan DeKok wrote:
> andy <andy at shady.org> wrote:
> > MySQL clusters require an auto-incrementing field to be the primary key.
> > Within the default table definitions for freeradius, which I have used, in the table radius.radius_radacct there is an 
> > auto-incrementing field that is not defined as a primary key.
> 
>   In 1.1.1 the RadAcctID field is auto-increment, and PRIMARY KEY.
> See doc/examples/mysql.sql.
> 
>   Which version are you looking at?
> 
>   Alan DeKok.
> - 
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
> 


The version im looking at is freeradius from ports:

dhcp1# radiusd -v
radiusd: FreeRADIUS Version 1.1.1, for host , built on May 18 2006 at 18:06:18


I have re-imported the radacct table from this source and the error is slightly different but is still happening:

rlm_sql (primary): Reserving sql socket id: 89
rlm_sql_mysql: query:  INSERT into RADIUS_RADACCT (AcctSessionId, AcctUniqueId, UserName, Realm, NASIPAddress, 
NASPortId, NASPortType, AcctStartTime, AcctStopTime, AcctSessionTime, AcctAuthentic, ConnectInfo_start, 
ConnectInfo_stop, AcctInputOctets, AcctOutputOctets, CalledStationId, CallingStationId, AcctTerminateCause, 
ServiceType, FramedProtocol, FramedIPAddress, AcctStartDelay, AcctStopDelay) values('0300FFFF78001E5D-4476C727', 
'52213596cf7e22f9', '00:0a:e4:56:e2:7c', '', '62.231.32.50', '67174400', 'Virtual', '2006-05-26 10:15:19', '0', '0', 
'RADIUS', '', '', '0', '0', '', '', '', 'Dialout-Framed-User', '', '', '', '0')
rlm_sql_mysql: MYSQL check_error: 2006, returning SQL_DOWN
rlm_sql (primary): Attempting to connect rlm_sql_mysql #89
rlm_sql_mysql: Starting connect to MySQL server for #89
rlm_sql (primary): Connected new DB handle, #89
rlm_sql_mysql: query:  INSERT into RADIUS_RADACCT (AcctSessionId, AcctUniqueId, UserName, Realm, NASIPAddress, 
NASPortId, NASPortType, AcctStartTime, AcctStopTime, AcctSessionTime, AcctAuthentic, ConnectInfo_start, 
ConnectInfo_stop, AcctInputOctets, AcctOutputOctets, CalledStationId, CallingStationId, AcctTerminateCause, 
ServiceType, FramedProtocol, FramedIPAddress, AcctStartDelay, AcctStopDelay) values('0300FFFF78001E5D-4476C727', 
'52213596cf7e22f9', '00:0a:e4:56:e2:7c', '', '62.231.32.50', '67174400', 'Virtual', '2006-05-26 10:15:19', '0', '0', 
'RADIUS', '', '', '0', '0', '', '', '', 'Dialout-Framed-User', '', '', '', '0')
rlm_sql (primary): Released sql socket id: 89


It now doesnt move onto the next socket, but retries the current connection.
I have also updated the default queries from sql.conf.example so everything is default.

cheers


-- 
andy    andy at shady.org
-----------------------------------------------
Never argue with an idiot. They drag you down 
to their level, then beat you with experience.
----------------------------------------------- 



More information about the Freeradius-Users mailing list