On Wed, Aug 29, 2012 at 4:11 AM, Alan DeKok <al...@deployingradius.com> wrote:
> Matthias Nagel wrote:

>> 5) Thread #2 terminates first and the accounting stop message is written to 
>> the PostgreSQL database. The SQL UPDATE statement fails, because there is no 
>> entry for this session that could be updated, as the start message has not 
>> been processed yet. Hence, an INSERT INTO statement is executed as a 
>> fail-over measure.
>> 6) Thread #1 terminates and an SQL INSERT statement is performed in order to 
>> log the start message.
>
>   That doesn't make sense.  If the table indexes are set up correctly,
> the SQL insert will fail at step (6).  The module will then try the
> update query, which should succeed.

IIRC the default schema for postgresql (as was also the case for mysql
untill a month ago) does not have unique index for acctuniqueid. So
yes, by default what the OP experienced will happen, and yes, it's an
easy fix.

-- 
Fajar
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Reply via email to