Announcement

Announcement Module
Collapse
No announcement yet.

mk/pt-query-digest

Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • mk/pt-query-digest

    Hi All,

    I'm using the query-digest tool to gather some statistics on a number of busy servers. Currently the problem I have is that pt-query-digest's memory usage continuously grows, heres how I'm using it.


    /usr/sbin/tcpdump -i eth0 port 3306 -s 65535 -x -n -q -tttt \|/usr/bin/pt-query-digest --type tcpdump \--review u=dbUser,p=dbPass,h=dbHost,D=mk_query_digest,t=que ry_review --create-review-table \--review-history u=dbUser,p=dbPass,h=dbHost,D=mk_query_digest,t=que ry_review_history --create-review-history-table \--run-time-mode clock --run-time 1m --iterations 0 --noreport


    I was hoping that after each run specified by --run-time that pt-query-digest would write out the statistics to my query_review database and this would keep the memory usage to 1m's worth of run time rather than wait until Ctrl-C or iterations is reached.

    Any ideas if this is possible and if so how?

    Cheers,
    Rob

  • #2
    For anybody else who might be interested I decided to run pt-query-digest under Upstart with,


    --run-time-mode clock --run-time 1m --iterations 1

    and have Upstart respawn each time.

    Cheers,
    Rob

    Comment

    Working...
    X