每天MySQL自动优化
浏览:2218次 出处信息
下面说下几个参数的含义
-a, --analyze 分析 [Analyze given tables]
-o, --optimize 优化 [Optimize table]
-A, --all-databases 所有的数据库 [Check all the database]
--auto-repair 自动修复 [If a checked table is corrupted, automatically fix it. Repairing will be done after all tables have been checked, if corrupted ones were found]
vi /opt/shell/mysql_opt.sh
/usr/local/mysql/bin/mysqlcheck -Aao -auto-repair -uroot -p
加入 crontab
-o, --optimize 优化 [Optimize table]
-A, --all-databases 所有的数据库 [Check all the database]
--auto-repair 自动修复 [If a checked table is corrupted, automatically fix it. Repairing will be done after all tables have been checked, if corrupted ones were found]
vi /opt/shell/mysql_opt.sh
/usr/local/mysql/bin/mysqlcheck -Aao -auto-repair -uroot -p
加入 crontab
* * */1 * * /opt/shell/mysql_opt.sh
建议继续学习:
- 30分钟3300%性能提升――python+memcached网页优化小记 (阅读:11869)
- WEB系统需要关注的一些点 (阅读:10163)
- 基于SSD的数据库性能优化 (阅读:7186)
- jQuery性能优化指南 (阅读:7167)
- 一次简单C程序的性能优化 (阅读:5459)
- mysql sql 百万级数据库优化方案 (阅读:4854)
- 一次神奇的MySQL优化 (阅读:4701)
- PHP最佳实践 (阅读:4657)
- Linux 64位, MySQL, Swap & Memory 优化 (阅读:4306)
- PHP 性能优化技巧-google (阅读:4196)
QQ技术交流群:445447336,欢迎加入!
扫一扫订阅我的微信号:IT技术博客大学习
扫一扫订阅我的微信号:IT技术博客大学习
<< 前一篇:PHP操作MongoDB时的整数问题及对策
后一篇:Mysql 安全 >>
文章信息
- 作者:Mike.Xu 来源: DBA Blog
- 标签: mysqlcheck 优化
- 发布时间:2011-06-24 13:58:41
建议继续学习
近3天十大热文
- [16] Go Reflect 性能
- [15] 浏览器的工作原理:新式网络浏览器幕后揭秘
- [13] 界面设计速成
- [13] iOS可视化编程 Tips 之“无需代码设置
- [13] iOS下自己动手造无限循环图片轮播
- [12] iTerm2 (Mac Terminal)
- [12] Spark性能优化——和shuffle搏斗
- [12] iOS并发编程(Concurrency Pr
- [12] 最萌域名.cat背后的故事:加泰与西班牙政府
- [11] 浅谈Web安全验证码