首先以root身份运行:
从数据库导出数据库
例如:
mysqldump -u root -p sqlroot wordpress > wordpress.sql
从文件导入数据库
例如:
mysql -uabc_f -p abc
期间遇到如下问题:
The mysql error: Out of resources when opening file… (Errcode: 24) indicates that the number of files that msyql is permitted to open has been exceeded.
最终找到解决办法:
This limit is controlled by the variable open_files_limit. You can read this in phpMyAdmin (or the MySQL command line utility) with the statement:
To set this variable to a higher number, edit the /etc/my.cnf file and add the lines:
note:
我的系统版本是Debian7和Centos7.4。
本文修改于180803
领取专属 10元无门槛券
私享最新 技术干货