设为首页 加入收藏

TOP

linux安装mysql5.7.22配置文件my.cnf配置细节及修改密码时出现的问题解决
2018-06-05 08:53:03 】 浏览:117
Tags:linux 安装 mysql5.7.22 配置 文件 my.cnf 细节 修改 密码 出现 问题 解决

[client]

socket=/usr/local/tools/mysql/mysql.sock

[mysqld]

lower_case_table_names=1

# Remove leading # and set to the amount of RAM for the most important data

# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.

# innodb_buffer_pool_size = 128M

# Remove leading # to turn on a very important data integrity option: logging

# changes to the binary log between backups.

# log_bin

# These are commonly set, remove the # and set as required.

basedir = /usr/local/tools/mysql

datadir = /usr/local/tools/mysql/data

port = XXXX

# server_id = .....

socket = /usr/local/tools/mysql/mysql.sock

# Remove leading # to set options mainly useful for reporting servers.

# The server defaults are faster for transactions and fast SELECTs.

# Adjust sizes as needed, experiment to find the optimal values.

# join_buffer_size = 128M

# sort_buffer_size = 2M

# read_rnd_buffer_size = 2M

explicit_defaults_for_timestamp=true

sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ZERO_DATE,NO_ZERO_IN_DATE,ERROR_FOR_DIVISION_BY_ZERO3


修改密码出问题时,解决办法:

mysql -u root -p v:AhlHqsKKd2+>提示(中间重启的一次mysql,可能是重启的原因,正常情况下是可以登录的)

Your password has expired. To log in you must change it using a client that supports expired passwords

在stackoverflow找到了解决方法,连接地址:https://stackoverflow.com/questions/33387879/mysql-password-expired-cant-connect

解决办法:

[root@localhost bin]# ./mysqladmin -uroot -p password

Enter password: //这里输入上面的v

New password: //重新输入新密码

Confirm new password: //重新输入新密码

问题解决!

】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
上一篇通过“通用数据连接文件”UDL((U.. 下一篇MySQL workbench6.3的登录和使用..

最新文章

热门文章

Hot 文章

Python

C 语言

C++基础

大数据基础

linux编程基础

C/C++面试题目