Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set default_password_lifetime to 0 (Never Expire) #60

Merged
merged 1 commit into from Nov 14, 2015

Conversation

konomae
Copy link
Contributor

@konomae konomae commented Nov 14, 2015

default_password_lifetime is 360 since MySQL 5.7.4
http://dev.mysql.com/doc/refman/5.7/en/server-system-variables.html#sysvar_default_password_lifetime

It will stop apps using MySQL 360 days later.

vagrant@homestead:~$ mysql -u homestead -p

mysql> UPDATE mysql.user SET password_last_changed = '2014-11-13 00:00:00' WHERE user = 'homestead'; 
Query OK, 2 rows affected (0.00 sec)
Rows matched: 2  Changed: 2  Warnings: 0

mysql> FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.01 sec)

mysql> ^DBye


vagrant@homestead:~$ mysql -u homestead -p

mysql> SHOW DATABASES;
ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants