运行mysqlslap报错如下:

[root@monitor-db ~]# mysqlslap --version
mysqlslap: Error when connecting to server: Access denied for user 'root'@'localhost' (using password: NO)

解决方法:带上--no-defaults参数

[root@sso-db-a binlog]# mysqlslap --no-defaults --version
mysqlslap  Ver 1.0 Distrib 5.7.23, for Linux (x86_64)

或者在my.cnf里面将default-character-set修改为utf8,需重启生效

[client]
#设置MySQL客户端的字符集
default-character-set=utf8

mysqlslap.png

Tags标签: mysqlslap Tags相关文章如下:

上一篇:FATAL: MySQL error: 1461 "Can't create more than max_prepared_stmt_count statements (current value: 16382)"

下一篇:使用sysbench对MySQL进行测试