Binary Log File Analysis

I used a tool to open and analyze binary files. Output used

insert into table1 update table4 insert into some_other_table 

It showed how many insert or update statements are contained there in a binary file. It was useful to find out if the server is inserting / deleting records or is there a big update.

I do not remember the name of the utility. any hint?

+7
mysql
source share
1 answer

Finally got the tool I was looking for.

http://forge.mysql.com/tools/tool.php?id=273

Since the link is not working, here is the code ...

 mysqlbinlog filename | grep -i -e "^update" -e "^insert" -e "^delete" -e "^replace" -e "^alter" | cut -c1-100 | tr '[AZ]' '[az]' | sed -e "s/\t/ /g;s/\`//g;s/(.*$//;s/ set .*$//;s/ as .*$//" | sed -e "s/ where .*$//" | sort | uniq -c | sort -nr | head -50 
+7
source share

All Articles