for i in $(seq 39 55);do mysqlbinlog binlog.1150${i} >> binlog.sql; done
cat binlog.sql | grep -i -e "^update" -e "^insert" -e "^delete" -e "^replace" -e "^alter" | cut -c1-100 | tr '[A-Z]' '[a-z]' | sed -e "s/\t/ /g;s/\`//g;s/(.*$//;s/ set .*$//;s/ as .*$//" | sed -e "s/ where .*$//" | sort | uniq -c | sort -nr
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/23153585/viewspace-1717196/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/23153585/viewspace-1717196/