-专注香港服务器租用18年
当前位置:首页 >> 帮助中心 >> 正文

[广深互联技术分享]mysql5.1升级到5.5

文章作者:客服中心 文章来源:广深互联 发布时间:2014/11/22

1.如果目前使用的是mysql5.0,先升级到5.1再升级到5.5,官方文档的说法:

if you currently are running MySQL 5.0 and wish to upgrade to a newer series, upgrade to MySQL 5.1 first before upgrading to 5.5


2.数据库升级后,应该执行mysql_upgrade命令,官方对mysql_upgrade命令作用的解说:


After upgrading to a new version of MySQL, run mysql_upgrade (see Section 4.4.7, “mysql_upgrade — Check Tables for MySQL Upgrade”). This program checks your tables, and attempts to repair them if necessary. It also updates your grant tables to make sure that they have the current structure so that you can take advantage of any new capabilities. (Some releases of MySQL introduce changes to the structure of the grant tables to add new privileges or features.)
 
 
3.mysql_upgrade命令实际执行了以下操作:
mysql_upgrade executes the following commands to check and repair tables and to upgrade the system tables:
mysqlcheck --all-databases --check-upgrade --auto-repair
mysql < fix_priv_tables
mysqlcheck --all-databases --check-upgrade --fix-db-names --fix-table-names
 
 
4.执行mysql_upgrade后重启数据库
After running mysql_upgrade, stop the server and restart it so that any changes made to the system tables take effect.
 

5.mysql5.5默认数据库引擎是InnoDB,如果想指定默认数据库引擎,编辑my.cnf
在[mysqld]最后添加为上default-storage-engine=MyISAM
如果填入InnoDB数据库默认的引擎修改为InnoDB


6.官方mysql5.1升级5.5指引

http://dev.mysql.com/doc/refman/5.5/en/upgrading-from-previous-series.html



上一篇: 如何在WIN2003系统中IIS6中配置Gzip压缩?
下一篇: [广深互联技术分享]开启proxy_arp
--------------------------------------------------------------------------------------------------------------------------------------
最新公告: