Re: pgbench cpu overhead (was Re: lazy vxid locks, v1)
От | Greg Smith |
---|---|
Тема | Re: pgbench cpu overhead (was Re: lazy vxid locks, v1) |
Дата | |
Msg-id | 4DF6BFBD.9040801@2ndQuadrant.com обсуждение исходный текст |
Ответ на | Re: pgbench cpu overhead (was Re: lazy vxid locks, v1) (Jeff Janes <jeff.janes@gmail.com>) |
Список | pgsql-hackers |
On 06/13/2011 08:27 PM, Jeff Janes wrote: > pgbench sends each query (per connection) and waits for the reply > before sending another. > > Do we know whether sysbench does that, or if it just stuffs the > kernel's IPC buffer full of queries without synchronously waiting for > individual replies? > sysbench creates a thread for each client and lets them go at things at whatever speed they can handle. You have to setup pgbench with a worker per core to get them even close to level footing. And even in that case, sysbench has a significant advantage, because it's got the commands it runs more or less hard-coded in the program. pgbench is constantly parsing things in its internal command language and then turning them into SQL requests. That's flexible and allows it to be used for some neat custom things, but it uses a lot more resources to drive the same number of clients. > I can't get sysbench to "make" for me, or I'd strace in single client > mode and see what kind of messages are going back and forth. > If you're using a sysbench tarball, no surprise. It doesn't build on lots of platforms now. If you grab http://projects.2ndquadrant.it/sites/default/files/bottom-up-benchmarking.pdf it has my sysbench notes starting on page 34. I had to checkout the latest version from their development repo to get it to compile on any recent system. The attached wrapper script may be helpful to you as well to help get over the learning curve for how to run the program; it iterates sysbench over a number of database sizes and thread counts running the complicated to setup OLTP test. -- Greg Smith 2ndQuadrant US greg@2ndQuadrant.com Baltimore, MD PostgreSQL Training, Services, and 24x7 Support www.2ndQuadrant.us
Вложения
В списке pgsql-hackers по дате отправления: