1.postfix在创建虚拟用户数据库时导入extmail.sql报错(mysql版本为5.5.24):

ERROR 1064 (42000) at line 50: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'TYPE=MyISAM COMMENT='Ext/Webman - Admin Accounts'' at line 15
2.解决办法:

vi extmail.sql

将里面所有的TYPE=MyISAM改为ENGINE=MyISAM

 

原因:TYPE是老的参数了,mysql5.5版本之后移除了TYPE选项并推荐使用ENNIGE代替(参见mysql官方对ENGINE的说明http://dev.mysql.com/doc/refman/5.5/en/create-table.html

 


另外如果出现mysql安全错误,按如下步骤操作:

vi /usr/local/mysql/my.cnf

#sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES

sql_mode=NO_ENGINE_SUBSTITUTION

重启mysql

service mysqld restart

导入完成后再改回来,然后再重启mysql