optimize sqlippool scheme

2012-01-12 Thread Alexander Kosykh
hi Is anyone have a success story of optimizing ippool sql table to make it work faster? The default scheme is very slow, and then you have about 25000 subscribers it's not work. I trying to add indexes to this table. It make fast selects, but slow updates. [code] CREATE TABLE `radippool` ( `id`

Re: optimize sqlippool scheme

2012-01-12 Thread Fajar A. Nugraha
On Thu, Jan 12, 2012 at 6:36 PM, Alexander Kosykh avkos...@gmail.com wrote: hi Is anyone have a success story of optimizing ippool sql table to make it work faster? The default scheme is very slow, and then you have about 25000 subscribers it's not work. I have over 1 million subscribers.

Re: optimize sqlippool scheme

2012-01-12 Thread Phil Mayers
On 01/12/2012 11:59 AM, Fajar A. Nugraha wrote: That's why having a dba is important. If you can't do it yourself, hire one. Or learn to be one. Depending on your deployment scale, the cost is justifiable. Seriously. Agreed, this is the key. SQL optimisation is a specialist task, and if you

Re: optimize sqlippool scheme

2012-01-12 Thread Alexander Kosykh
One more question. Where can I take nas-type value to use it in user authorization? Radius take it from mysql nasinfo table at startup. I take it from DB every time subscriber try to authorize. Regards, Alexander. 2012/1/12 Fajar A. Nugraha l...@fajar.net On Thu, Jan 12, 2012 at 6:36 PM,

Re: optimize sqlippool scheme

2012-01-12 Thread Fajar A. Nugraha
On Thu, Jan 12, 2012 at 8:15 PM, Phil Mayers p.may...@imperial.ac.uk wrote: So in short, for now: - revert your changes - try changing the engine to innodb - if it's still too slow, hire a dba, and/or be prepared to implement mysql cluster (or something like clustrix) - use postgres ;o)

Re: optimize sqlippool scheme

2012-01-12 Thread Fajar A. Nugraha
On Thu, Jan 12, 2012 at 8:30 PM, Alexander Kosykh avkos...@gmail.com wrote: One more question. Where can I take nas-type value to use it in user authorization? Radius take it from mysql nasinfo table at startup. I take it from DB every time subscriber try to authorize. That's pretty much the

Re: optimize sqlippool scheme

2012-01-12 Thread Alexander Kosykh
I have interim accounting value 10 minutes and IP lease time is 30 minutes. 2012/1/12 Phil Mayers p.may...@imperial.ac.uk On 01/12/2012 11:59 AM, Fajar A. Nugraha wrote: That's why having a dba is important. If you can't do it yourself, hire one. Or learn to be one. Depending on your

Re: optimize sqlippool scheme

2012-01-12 Thread Phil Mayers
On 01/12/2012 01:33 PM, Fajar A. Nugraha wrote: I avoid postgres like plague in the past due to vacuum :) It has autovacuum now, but the bad image remains. To be fair, it's probably similar with the way many people avoid mysql due to myisam-related issues :) Funnily enough I avoid MySQL like

Re: optimize sqlippool scheme

2012-01-12 Thread Phil Mayers
On 01/12/2012 01:40 PM, Alexander Kosykh wrote: I have interim accounting value 10 minutes and IP lease time is 30 minutes. So you should be getting, what, ~40 accounting packets/second with 25k users online. Does this correspond to the query load you're seeing? 40 SQL updates/second is