Home  >  Article  >  Database  >  mysql Innodb的ibdata的作用与分离_MySQL

mysql Innodb的ibdata的作用与分离_MySQL

WBOY
WBOYOriginal
2016-06-01 13:31:271117browse

bitsCN.com

mysql Innodb的ibdata的作用与分离

 

mysql INNODB类型数据状态下,ibdata用来储存文件的数据,而数据库名的文件夹里面的那些表文件只是结构而已,小心,万小心不能删除它,共享表空间管理会出现表空间分配后不能回缩的问题,所以它会变的越来越大,所以有必要对它进行分离

INNODB的独立表空间的参数: 

innodb_file_per_table

 

具体步骤如下:

1、备份数据库mysqldump -uroot -p --all-database>c:/all_back_database.sql2、停止数据库mysqladmin --host=localhost --user=root --password shutdown3、删除相关文件ibdata1ib_logfile*4、手动删除除Mysql之外所有数据库文件夹,然后启动数据库net start mysql5、还原数据mysql -uroot -p<c:/all_back_database.sq

 


bitsCN.com
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn