修改本地数据源密码
cp datasource_localhost.inc.php datasource_localhost.inc.php.bak sed -i "3s#localhost#127.0.0.1#g" datasource_localhost.inc.php sed -i '6s#root#anemometer#g' datasource_localhost.inc.php sed -i "7s#''#'123456'#g" datasource_localhost.inc.php
导入数据
cd .. mysql -uanemometer -p123456 -h127.0.0.1 < install.sql
浏览器访问网站,如下图所示
文章插图
导入t100w数据t100w数据库,可以从搜索下载或私信作者索取
下面的sql语句是导入t100w数据表,并执行查询操作
source /root/t100w.sql; use test; select num,k1 from t100w where num !=0 order by k1 limit 10; select num,k1 from t100w where num !=10 order by k1 limit 100; select num,k1 from t100w where num >1000 order by k1 limit 100; select num,k1 from t100w where num >10000 order by k1 limit 10000; select num,k1 from t100w where num !=1000 order by k1 limit 100; select num,k1 from t100w where num !=10 order by k1 limit 10000; select * from t100w where num !=10 order by k1 limit 100,300; select * from t100w where num !=0 order by k1 limit 100,3000; select * from t100w where num >1 order by k1 limit 10000,30000; select * from t100w where k1="s" order by k1 limit 10000,30000; select * from t100w where k1="s" order by k1 limit 1000,3000; select num,k1 from t100w where k1="s" order by k1 limit 1000,3000; select num,k1 from t100w where k1="s" order by k1 limit 10000,30000; select num,k1 from t100w where k1="0" order by k1 limit 10000,30000; select num,k1 from t100w where k1 like "%1%" order by k1 limit 10000,30000; select num,k1 from t100w where k1 like "%2%" order by k1 limit 10000,30000;
查看慢日志出于友好提示,密集恐惧者,请不要执行下面的命令!密集恐惧者,请不要执行下面的命令!密集恐惧者,请不要执行下面的命令!
mysqldumpslow -s c -t 1 /var/lib/mysql/db114-slow.log | more
导入慢查询日志 pt-query-digest --user=anemometer --password=123456 --review h='192.168.255.114',D=slow_query_log,t=global_query_review --history h='192.168.255.114',D=slow_query_log,t=global_query_review_history --no-report --limit=50% --filter=" $event->{Bytes} = length($event->{arg}) and $event->{hostname}="$HOSTNAME"" /var/lib/mysql/db114-slow.log
如下图所示文章插图
以上就是全部的安装步骤,明天更新anemometer的使用方法
欢迎在评论区一起讨论,质疑 。文章都是手打原创,每天最浅显的介绍运维、数据库相关的技术,喜欢我的文章就关注一波吧,可以看到最新更新和之前的文章 。
【MySQLAnemometer可视化工具安装】
推荐阅读
- 自媒体必备账号管理工具,一键多发,轻松应对
- 2019年最受欢迎的20款黑客工具盘点
- 硬盘检测工具哪个好?在win10中这样检查磁盘健康状态就对了
- 安装数据可视化展现软件-grafana
- 11个代码质量审核和管理工具,程序员收藏
- 程序员必备实用工具大全,说说你用过几个?
- 分享几款Linux 下C/C++程序内存泄漏检查工具
- 2019年最受欢迎的20款黑客工具盘点!
- 提高开发效率的 9 个工具
- 推荐 10 个不错的网络监视工具,值得收藏