我目前正在Mac上安装mariadb。我按照官方指南进行操作。之后我运行了
mysql_install_db
我在下面有很多东西
Installing MariaDB/MySQL system tables in '/usr/local/var/mysql' ...
2016-12-06 13:34:08 140736312062912 [Note] /usr/local/Cellar/mariadb/10.1.19/bin/mysqld (mysqld 10.1.19-MariaDB) starting as process 1755 ...
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: Using mutexes to ref count buffer pool pages
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: The InnoDB memory heap is disabled
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: Compressed tables use zlib 1.2.8
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: Using SSE crc32 instructions
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: Completed initialization of buffer pool
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: Highest supported file format is Barracuda.
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: 128 rollback segment(s) are active.
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: Waiting for purge to start
2016-12-06 13:34:08 140736312062912 [Note] InnoDB: Percona XtraDB (http://www.percona.com) 5.6.32-79.0 started; log sequence number 1606728
2016-12-06 13:34:08 123145316896768 [Note] InnoDB: Dumping buffer pool(s) not yet started
2016-12-06 13:34:08 123145319579648 [ERROR] Incorrect definition of table mysql.proc: expected column 'sql_mode' at position 14 to have type set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','IGNORE_BAD_TABLE_OPTIONS','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVA
2016-12-06 13:34:08 123145319579648 [ERROR] Incorrect definition of table mysql.event: expected column 'sql_mode' at position 14 to have type set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','IGNORE_BAD_TABLE_OPTIONS','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE','NO_ENGINE_SUBSTITUTION','PAD_CHAR_TO_FULL_LENGTH'), found type set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_A
ERROR: 1136 Column count doesn't match value count at row 1
2016-12-06 13:34:08 140736312062912 [ERROR] Aborting
Installation of system tables failed!Examine the logs in/usr/local/var/mysql for more information.
The problem could be conflicting information in an external my.cnf files. You can ignore these by doing:
shell> /usr/local/Cellar/mariadb/10.1.19/scripts/scripts/mysql_install_db --defaults-file=~/.my.cnf
You can also try to start the mysqld daemon with:
shell> /usr/local/Cellar/mariadb/10.1.19/bin/mysqld --skip-grant --general-log & and use the command line tool /usr/local/Cellar/mariadb/10.1.19/bin/mysql to connect to the mysql database and look at the grant tables:
shell> /usr/local/Cellar/mariadb/10.1.19/bin/mysql -u root mysql
mysql> show tables;
Try 'mysqld --help' if you have problems with paths. Using --general-log gives you a log in /usr/local/var/mysql that may be helpful.
The latest information about mysql_install_db is available at https://mariadb.com/kb/en/installing-system-tables-mysql_install_db
MariaDB is hosted on launchpad; You can find the latest source and email lists at http://launchpad.net/maria
Please check all of the above before submitting a bug report at http://mariadb.org/jira