Git Product home page Git Product logo

innotopgo's Introduction

Innotop Go

Innotop for MySQL 8 written in Go

Project started to learn Go and doing something useful (I hope).

Additionally the official Innotop written in Perl became very hard to maintain.

Main Processlist Screen

Screenshot from 2021-04-06 18-57-56

InnoDB Dashboard

Screenshot from 2021-04-07 23-20-20

Memory Dashboard

Screenshot from 2021-04-10 13-16-26

Error Log Dashboard

Selection_084

Locking Info

Screenshot from 2021-07-15 22-20-45

Screenshot from 2021-07-15 22-21-00

Demo

Demo (0.1.1) on MacOS (thank you @datacharmer):

innotopgo

Connect

    ./innotopgo mysql://<username>:<password>@<host>:3306

example:

    ./innotopgo mysql://root:password@localhost:3306

Help

Press ? within innotopgo application.

innotopgo's People

Contributors

datacharmer avatar izzysmith avatar lefred avatar tinram avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

innotopgo's Issues

Locking Info Dashboard is not working

Hi Lefred,

I have installed the innotopgo version 0.3 tool and it is very helpful

I was testing all the available dashboards by creating the test scenarios, the locking info dashboard is not getting switched post giving the input as , also it is prompting to provide the thread_id as input, post giving the thread_id, it is failing to fetch the locking details

please help to resolve this issue or let me know if I am missing something.

PFA
Screenshot 2021-10-27 at 6 14 33 PM
,

Add a thread information Screen

Get all information possible for a thread.

Check how to add the information returned by:

select *, pps.PROCESSLIST_COMMAND AS command,
                                  pps.THREAD_ID AS thd_id, pps.PROCESSLIST_ID AS conn_id,
                                  conattr_pid.ATTR_VALUE AS pid, pps.PROCESSLIST_STATE AS state,
                                  if((pps.NAME in ('thread/sql/one_connection','thread/thread_pool/tp_one_connection')),
                                   concat(pps.PROCESSLIST_USER,'@',pps.PROCESSLIST_HOST),
                                   replace(pps.NAME,'thread/','')) AS user,
                                  pps.PROCESSLIST_DB AS db, sys.format_statement(pps.PROCESSLIST_INFO) AS current_statement,
                                  if(isnull(esc.END_EVENT_ID), format_pico_time(esc.TIMER_WAIT),NULL) AS statement_latency,
                                  format_pico_time(esc.LOCK_TIME) AS lock_latency,
                                  if(isnull(esc.END_EVENT_ID),esc.TIMER_WAIT,0) AS sort_time
                            from (((((((performance_schema.threads pps
                            left join performance_schema.events_waits_current ewc
                                on((pps.THREAD_ID = ewc.THREAD_ID)))
                            left join performance_schema.events_stages_current estc
                                on((pps.THREAD_ID = estc.THREAD_ID)))
                            left join performance_schema.events_statements_current esc
                                on((pps.THREAD_ID = esc.THREAD_ID)))
                            left join performance_schema.events_transactions_current etc
                                on((pps.THREAD_ID = etc.THREAD_ID)))
                            left join sys.x$memory_by_thread_by_current_bytes mem
                                on((pps.THREAD_ID = mem.thread_id)))
                            left join performance_schema.session_connect_attrs conattr_pid
                                on(((conattr_pid.PROCESSLIST_ID = pps.PROCESSLIST_ID) and (conattr_pid.ATTR_NAME = '_pid'))))
                            left join performance_schema.session_connect_attrs conattr_progname
                                on(((conattr_progname.PROCESSLIST_ID = pps.PROCESSLIST_ID)
                                and (conattr_progname.ATTR_NAME = 'program_name'))))
                            where pps.PROCESSLIST_ID is not null
                              and pps.PROCESSLIST_COMMAND <> 'Daemon'
                              and user <> 'sql/event_scheduler'
                            order by sort_time desc                            

We could also display the list of previous queries in a transaction

Add InnoDB Buffers information

Add a new screen with InnoDB information like:

  • buffer pool (size and # , free pages, dirty pages, Hit Rate...)
  • page statistics (Reads, Writes, Created, read/sec, write/sec, create/sec)
  • Insert Buffers
  • AHI

anything more ?

Add a Transaction Screen

Same a Proceslist but relate to Transaction, something like:

History  Versions  Undo  Dirty Buf  Used Bufs  Txns  MaxTxnTime  LStrcts
      0                      0.00%     84.53%     5       01:16         

ID   User  Host       Txn Status  Time   Undo  Query Text
768  root  localhost  ACTIVE      01:16     1            
769  root  localhost  ACTIVE      01:10     0 

Keyboard buffer queue is not flushed

Currently, when you are in a different dashboard like or , if you press some keys that have a meaning in the Processlist (main dashboard), once you get back to it (<--) the first element out of the queue is processed and can lead you again to another dashboard, etc...

I didn´t find the way to flush the keyboard queue, neither to workaround it.

Password in a seperate File / PSA.Shadow Feature

Your Login is something like:
./innotopgo mysql://root:password@localhost:3306

But if I don't know the password it should work something like
./innotopgo mysql://admin:**cat /etc/psa/.psa.shadow**@localhost:3306

For Example this works on Plesk based Servers:
mytop -u admin -pcat /etc/psa/.psa.shadow

Add an I/O Screen

Add a new screen for I/O

Certainly with InnoDB IO but maybe others too like Binlogs

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.