Cannot insert duplicate key row in object 'dbo.radacct' with unique index 'AcctUniqueId'

info Redlibre info at redlibre.cl
Fri Jun 27 05:56:24 CEST 2014


Hello, i'am using freeradius 2.1.12+dfsg-1.2 on debian wheezy, AAA is in MS-SQL backend using iodbc, the system is a hotspot with mikrotik routerboard using radius client, everything is fine the users can authenticate from radcheck table but in accounting log i receive this message

Error: sql_query: failed:  [FreeTDS][SQL Server]Cannot insert duplicate key row in object 'dbo.radacct' with unique index 'AcctUniqueId'. The duplicate key value is (4785db03c....

 
the problem is the radacct table is not registering info like, acctstoptime, acctsessiontime and others, only acctstarttime

 
if i modify the index unique of acctuniqueid like not unique is worst because in radacct table the start time and stoptime is inserted in two different rows 

i'm using the following schema

https://github.com/FreeRADIUS/freeradius-server/blob/master/raddb/mods-config/sql/main/mssql/schema.sql

and the query from

https://github.com/FreeRADIUS/freeradius-server/blob/master/raddb/mods-config/sql/main/mssql/queries.conf

by the way  i had to modified the query.conf file because there is an error in variable NASPortId column,  it is called from query.conf by NASPort , anyway my problem is the radacct table is not registering info like, acctstoptime, acctsessiontime and others

I am wondering if can i use the mysql query file to achieve this? (obviously, making a little changes into querys )

for example i've put the postauth definition from mysql on mssql and it works.
 
before always i've used freeradius + mysql and accounting is fine, unfortunately at this time i have to use MSSQL like backend, is not my fault ;)


regards
pablou

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeradius.org/pipermail/freeradius-users/attachments/20140627/60f662b6/attachment.html>


More information about the Freeradius-Users mailing list