Your password does not satisfy the current policy requirements

后端 未结 19 2513
眼角桃花
眼角桃花 2020-12-12 08:33

I want to create a new user in mysql with syntax:

create user \'demo\'@\'localhost\' identified by \'password\';

But it returns an error: <

19条回答
  •  囚心锁ツ
    2020-12-12 09:19

    I had the same Problem and the Answer is just Right in front of you, remember when you ran the script while installing mysql like

    sudo mysql_secure_installation

    there somewhere you chose which password type would you like to chose

    There are three levels of password validation policy:

    LOW Length >= 8 MEDIUM Length >= 8, numeric, mixed case, and special characters STRONG Length >= 8, numeric, mixed case, special characters and dictionary file

    Please enter 0 = LOW, 1 = MEDIUM and 2 = STRONG:

    you have to give a password to same policy

    here are some sample examples for your passwords:
    for type 0: abcdabcd
    for type 1: abcd1234
    for type 2: ancd@1234

提交回复
热议问题