• Register
1 vote
32 views

Problem :

I am very new to the mysql. I am trying to create the new user in the mysql with below syntax:

create user 'MyUser'@'localhost' identified by 'password';

But I am always facing below error:

“Your password does not satisfy the current policy requirements.”

I have already tried many types of passwords but none of them are working. I am trying to fix the above error from many hours but still no success. Can someone help me in fixing it for me?

8 5 2
3,230 points

2 Answers

1 vote

Solution :

I am trying to help you as I found your question very interesting.

To fix your this problem you need to execute below command in mysql: 

SHOW VARIABLES LIKE 'validate_password%' 

 When I executed above command I found that my "validate_password_policy" was set to Medium.

The below output is self explanatory. It is for the valid password when the Password policy is set to medium:

The Password must be at least 8 characters long

The Mixed case count is 1 here At least 1 letter in small and 1 letter in caps

The Number count is 1

The Minimum special Character count is 1

So for you a valid password must obey above policy. You can refer below examples of valid password for the above rules:

·  Student@123

·  NINJAcoder@100

·  demoPass@99

You should pick any of the above combination as long as it satisfies your policy.

8 4
5,680 points
0 votes

One can set many requirements for password validation. The password policy must have strong otherwise you will get an error “Your password does not satisfy the current policy requirements.” Error when the user tries to set a password in MYSQL.

Where to create a password policy?

The password policy will be created in the MYSQL server, when the validate_plugin is active and this will throw an error message by saying that the password does not satisfy the current policy requirements.

Solutions:

This error can be fixed by three methods.

  • Set the password policy value to low
  • Set the same password policy value in my.cnf file
  • Uninstall the plugin that is used for validating a password.

Set the password policy to low:

The default password level of the plugin can be changed at runtime or by using a config file. For this purpose, the default authentication plugin has to be checked.

SHOW VARIABLES LIKE ‘default authentication plugin’;

For checking the current variables for password validation, run the following command.

SHOW VARIABLES LIKE ‘validate_password%’;

Validate_password is a variable that is used to inform the server about the validate_password plugin. This plugin tests the passwords and improves security.

Policies in validate_password_policy:

There are three policies in Validate_password_policy. The policies are used to define the strength of the password. The default policy will be Medium and the value is changed to Low which has the password length of a minimum of 8 characters. It is only used to check the length of the password. Password policy is set by using the following command;

SET GLOBAL validate_password_policy = LOW

 

11 5 1
3,890 points

Related questions

0 votes
1 answer 120 views
120 views
Problem : I am very new to node.js and MySQL and I have just started setting up and also trying out some basic code. But, I am unable to make even the simple connection to a server for some reason. I have also installed a newest MySQL ... ; console.log("Connected!"); }); My Error: “Client does not support authentication protocol requested by server consider upgrading mysql client”
asked Jan 30 jwilliam 3.9k points
0 votes
1 answer 28 views
28 views
Problem : I have a Stored procedure like below: CREATE PROCEDURE MyProG() BEGIN SELECT * FROM `hs_hr_employee_leave_quota`; END But it gives me the below error: #1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 3 What does this error mean? What is wrong with my line number 2?
asked Jan 30 jwilliam 3.9k points
1 vote
1 answer 325 views
325 views
Problem : I am naïve to mysql. Currently I am continuously facing below error. “Mysql access denied for user 'root'@'localhost' (using password yes)”. I have recently started using mySQL Workbench and after doing research on above error I found that my root's ... of no us. I want to get my root access back as soon as possible. Can somebody help me in getting my root access back?
asked Apr 7 morrisBson 3.2k points
0 votes
2 answers 63 views
63 views
Problem : I am very much new to the whole Mac experience. I have recently installed MySQL on Mac and it is asking me to reset the password after install. It is not allowing me to do anything else. Now I have already reset the password the usual way as below: update ... I need to change the password but in some different way that is not known to me. Can someone here has any solution on my problem?
asked Dec 4, 2019 alecxe 7.5k points
0 votes
1 answer 27 views
27 views
Problem : I am new to WampServer and while trying to install the Joomla 3.3.4 on my localhost in a Database Configuration I have encountered below error “Could not connect to the database. Connector returned number: Could not connect to MySQL." I also tried to leave the password as blank, but still it didn’t connect.
asked Feb 18 mphil 2.3k points