gpt4 book ai didi

linux - 在 s390 上构建 MariaDB

转载 作者:太空宇宙 更新时间:2023-11-04 11:54:09 25 4
gpt4 key购买 nike

我正尝试按照这些说明在 s390 (z/Linux) 上构建 mariaDB mariaDB Instructions .抱歉,我不是 DBA 或 SA。

但是我卡在了“3.7创建数据库并将测试数据填充到数据库”这一步

sudo scripts/mysql_install_db --user=mysql

这是我得到的错误:

root@tdpvld01:/usr/local/mysql> sudo scripts/mysql_install_db --user=mysql
Installing MariaDB/MySQL system tables in '/var/lib/mysql' ...
2019-03-05 9:17:57 6 [ERROR] Column count of mysql.proc is wrong. Expected 21, found 20. Created with MariaDB 50552, now running 100312. Please use mysql_upgrade to fix this error
2019-03-05 9:17:57 6 [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','EMPTY_STRING_IS_NULL','SIMULTANEOUS_ASSIGNMENT'), found 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_VALU
ERROR: 1136 Column count doesn't match value count at row 1
2019-03-05 9:17:57 0 [ERROR] Aborting


Installation of system tables failed! Examine the logs in
/var/lib/mysql for more information.

The problem could be conflicting information in an external
my.cnf files. You can ignore these by doing:

shell> scripts/mysql_install_db --defaults-file=~/.my.cnf

You can also try to start the mysqld daemon with:

shell> ./bin/mysqld --skip-grant-tables --general-log &

and use the command line tool ./bin/mysql
to connect to the mysql database and look at the grant tables:

shell> ./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 /var/lib/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
You can find the latest source at https://downloads.mariadb.org and
the maria-discuss email list at https://launchpad.net/~maria-discuss

Please check all of the above before submitting a bug report
at http://mariadb.org/jira

按照某些论坛的建议,我尝试运行 mysql_upgrade。但是得到了这个错误:

root@tdpvld01:/usr/local/mysql/bin> ./mysql_upgrade
Version check failed. Got the following error when calling the 'mysql' command line client
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
FATAL ERROR: Upgrade failed

任何建议将不胜感激。

最佳答案

解决方案相当简单。
在那个 s390 上有一个以前的 mysql/mariadb rpm 安装。我卸载了 mariadb RPM,但保留了 mysql。
看来我编译mariadb时,它覆盖了mysql安装并产生了那个错误。
我卸载了所有东西,再次重新编译,现在它工作正常。

关于linux - 在 s390 上构建 MariaDB,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55008277/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com