Обсуждение: How to mesure transaction rate in Postgres
Hello,
I've been asked for the transaction rate we have on an installed Postgres server. Where and how can I get this information. I could not find anything in the documentation. I have root access to the system.
Thank you for your Help.
Marco
On 5/23/06, Meyer Marco <Marco.Meyer@intradoemea.com> wrote:
this is definitelly not nice approach, but it works.
connect to database, and issue this command:
begin; create table not_previously_existsing(id int4); select xmin from pg_class where relname = 'not_previously_existsing'; rollback;
returned value is id of the transaction that created the table.
repeat this command every so often (mrtg does that every 5 minutes), and you can see how it grows.
depesz
--
http://www.depesz.com/ - nowy, lepszy depesz
I've been asked for the transaction rate we have on an installed Postgres server. Where and how can I get this information. I could not find anything in the documentation. I have root access to the system.
this is definitelly not nice approach, but it works.
connect to database, and issue this command:
begin; create table not_previously_existsing(id int4); select xmin from pg_class where relname = 'not_previously_existsing'; rollback;
returned value is id of the transaction that created the table.
repeat this command every so often (mrtg does that every 5 minutes), and you can see how it grows.
depesz
--
http://www.depesz.com/ - nowy, lepszy depesz
On May 25, 2006, at 1:33 AM, hubert depesz lubaczewski wrote: > On 5/23/06, Meyer Marco <Marco.Meyer@intradoemea.com> wrote: > I've been asked for the transaction rate we have on an installed > Postgres server. Where and how can I get this information. I could > not find anything in the documentation. I have root access to the > system. > > > this is definitelly not nice approach, but it works. Or just SELECT xact_commit + xact_rollback FROM pg_stat_database; -- Jim C. Nasby, Sr. Engineering Consultant jnasby@pervasive.com Pervasive Software http://pervasive.com work: 512-231-6117 vcard: http://jim.nasby.net/pervasive.vcf cell: 512-569-9461