Coder Social home page Coder Social logo

hostname_max column is empty about anemometer HOT 3 OPEN

vachanda avatar vachanda commented on September 27, 2024
hostname_max column is empty

from anemometer.

Comments (3)

akuzminsky avatar akuzminsky commented on September 27, 2024

@vachanda , we'll have a look

from anemometer.

krzykawski avatar krzykawski commented on September 27, 2024

I'm sure vachanda above already has fixed this. For others that are having the same issue, the pt-query-digest command line need the hostname specified as described in https://github.com/box/Anemometer/blob/master/README.md

i.e, my function in my collect script run across all db's is:
`
digest() {

    LOG "Running pt-query-digest and saving metrics in database $STOREDB - file: $1"

    pt-query-digest \
    --user=${DBUSER} \
    --password=${DBPASS} \
    --review h=${STOREDB},D=slow_query_log,t=global_query_review,P=${STOREDBPORT} \
    --history h=${STOREDB},D=slow_query_log,t=global_query_review_history,P=${STOREDBPORT} \
    --no-report \
    --limit=0% \
    --filter=" \$event->{Bytes} = length(\$event->{arg}) and \$event->{hostname}=\"$HOSTNAME:$MYPORT\"" $1 >> $SESSIONLOGFILE

EXIT=$?

}
`

Note $HOSTNAME and $MYPORT. The latter is picked up from the local my.cnf file like: MYPORT=$(cat /etc/my.cnf|grep port|head -1|sed 's/[^0-9]//g'). The former is a bash default var, but if you're on an older bash, you can populate it like HOSTNAME=$(hostname)

from anemometer.

Jonathanliu525 avatar Jonathanliu525 commented on September 27, 2024

I have the same problem when I use the percona-toolkit 2.2.13,although I specify the host by using --filter=" \$event->{Bytes} = length(\$event->{arg}) and \$event->{hostname}=\"$HOSTNAME\""
I solve it after changing to percona-toolkit 3.0.2.
know more about the hostname_max. You can read this

https://www.percona.com/blog/2012/08/28/hidden-columns-of-query_review_history/

from anemometer.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.