Re: Duplicate SQL records versus unique constraints

2009-06-08 Thread Alan DeKok
Arran Cudbard-Bell wrote: Ooo useful. Would you be adverse to a patch adding a policy section that provided the requisite behavior for both Access-Accept and Accounting-Request packets ? Or would you like two policy sections. I'll look at the patch and see. i.e. One that has a switch

Re: Duplicate SQL records versus unique constraints

2009-06-04 Thread Arran Cudbard-Bell
On 3/6/09 17:38, Alan DeKok wrote: Arran Cudbard-Bell wrote: Thanks, i'll poke Alan and see if he wants to include it. $ git format-patch :) Still haven't had feedback on the last one yet ! It'd be nice to have a generic hashing module for string expansions and not have to do some

Re: Duplicate SQL records versus unique constraints

2009-06-03 Thread Arran Cudbard-Bell
If we add a CONSTRAINT to enforce uniqueness for acctuniqueid in the DB, will the failure to insert an accounting record confuse the freerad sql module and will those failures percolate up towards the radius protocol level and thus result in the NAS keep on sending that accounting packet? Yes.

Re: Duplicate SQL records versus unique constraints

2009-06-03 Thread Arran Cudbard-Bell
On 3/6/09 07:53, Arran Cudbard-Bell wrote: If we add a CONSTRAINT to enforce uniqueness for acctuniqueid in the DB, will the failure to insert an accounting record confuse the freerad sql module and will those failures percolate up towards the radius protocol level and thus result in the NAS

Re: Duplicate SQL records versus unique constraints

2009-06-03 Thread Christian Balzer
Hello, On Wed, 03 Jun 2009 08:24:53 +0100 Arran Cudbard-Bell wrote: [more uniqueness for accounting packets] Example policy for this would be something like : [snip] Thanks a bundle for that, I was about to whack my head against the screen here and type man unlang. ;) If you're still

Re: Duplicate SQL records versus unique constraints

2009-06-03 Thread Arran Cudbard-Bell
[snip] Thanks a bundle for that, I was about to whack my head against the screen here and type man unlang. ;) If you're still getting duplicates, check that the NAS is actually sending the value of the Class attribute. Vendors are notoriously bad for ignoring the RFC in this area. Yeah,

Re: Duplicate SQL records versus unique constraints

2009-06-03 Thread Alan DeKok
Arran Cudbard-Bell wrote: Thanks, i'll poke Alan and see if he wants to include it. $ git format-patch :) It'd be nice to have a generic hashing module for string expansions and not have to do some much unlang hackyness, useful for CUI too. update reply { User-Name :=

Duplicate SQL records versus unique constraints

2009-06-02 Thread Christian Balzer
Hello, First of, been using freeradius for 5-6 years now and we are happy campers thanks to it. Freeradius 2.04 (Debian Lenny package), but I don't think this is very version specific. Configuration is set for direct (sql, not sql_log) logging of accounting records into mysql. We've got a