Home  >  Article  >  Database  >  如何修改mysql数据库的max_allowed_packet参数_MySQL

如何修改mysql数据库的max_allowed_packet参数_MySQL

WBOY
WBOYOriginal
2016-06-01 13:25:091379browse

bitsCN.com

如在导入数据库时出现“Got a packet bigger than 'max_allowed_packet' bytes”或者“MySQL server has gone away”等错误,一般是由于当前导入的数据大于系统的限制的最大包大小。服务器的默认max_allowed_packet值为1MB,通过修改'max_allowed_packet' 参数的大小就可以解决问题。

修改方法为:进入mysql的安装目录,找到my.ini文件,在最底下加上 max_allowed_packet=*M  (自己视情况设置)即可。

 

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