Re: PostgreSQL 9.3: monitor read vs write activity

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Thu, Feb 27, 2014 at 6:54 AM, Sergey Arlashin <sergeyarl.maillist@xxxxxxxxx> wrote:
 
Thank you for your response and sorry for answering so late. Didn't have a chance to check it. 

But I cannot figure out how I can measure read vs write activity of my postgresql database with the help of "check_postgres"? I haven't seen anything related to it in "check_postgres --help" output. Moreover it seems I can get all the data that check_postgres provides simply by querying postgresql system tables like  pg_stat_database, pg_stat_user_tables, pg_stat_activity and so on. 

Let me explain. 
When I used MySQL I was able to measure read vs write activity by counting the number of selects vs inserts/updates/deletes etc. But I cannot find anything similar in PostgreSQL. 

If you looking at measuring read vs write activity on a Postgres database, then a pgbadger report ( mentioned in this email thread earlier ) would straight get you the %age of reads (SELECTS) vs %age of WRITES (inserts/updates/deletes). Alternative tools would be "pgsi" or "pg_query_analyzer" - all of these tools perform analysis on PostgreSQL logfiles in pg_log directory and impose no over-head and consume very less resources.

check_postgres.pl does not have a direct option of calculating read vs write activity. Alternatively, you can write your own scripts (perl or shell) and plug them into check_postgres.pl.

Through pg_stat* catalog tables, you can monitor read/write activity Table or Index wise. Ex: I can find out which Table or Index is getting high number of read or write requests.

Please let us know if you are what kind of monitoring you are looking at.

Regards,

Venkata Balaji N
Fujitsu Australia

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux