Home IT Linux Windows Database Network Programming Server Mobile  
           
  Home \ Database \ error 1819 (HY000): your password does not satisfy the current policy requirements     - About redis in Replication (Database)

- Ubuntu Series Installation Docker (Linux)

- Android custom title bar (Programming)

- CentOS 6.5 using Virtualenv under development environment to build Python3 (Linux)

- High-performance Linux system firewall detailed analysis of double-effect (Linux)

- How to install Nginx on FreeBSD 10.2 as an Apache reverse proxy (Server)

- Will Laravel become the most successful PHP framework? (Programming)

- Linux ls command (Linux)

- Python closure and function objects (Programming)

- Kitematic how seamless and DockerFILE (Server)

- Java data structures - order linear form of table ArrayList (Programming)

- Android basics summary article (Programming)

- C ++ CBitmap, HBitmap, Bitmap difference and contact (Programming)

- Oracle RMAN repair logical bad blocks (Database)

- PostgreSQL Source Customization: Online global read only (Database)

- To install network scanning and packet sniffer tool Nmap 7.00 under ubuntu (Linux)

- Linux initialization init systems - Systemd (Linux)

- PostgreSQL query lock and kill the process (Database)

- Oracle table compression Technology Introduction (Database)

- MySQL 5.6 database code changes (Database)

 
         
  error 1819 (HY000): your password does not satisfy the current policy requirements
     
  Add Date : 2018-11-21      
         
       
         
  In order to strengthen security, MySQL5.7 for the root user to generate a random password, error log, the error log on the position, if installed RPM package, the default is /var/log/mysqld.log.

Generally set by log_error

mysql> select @@ log_error;
+ --------------------- +
| @@ Log_error |
+ --------------------- +
| /var/log/mysqld.log |
+ --------------------- +
1 row in set (0.00 sec)
MySQL can get a temporary password by # grep "password" /var/log/mysqld.log command

2016-01-19T05: 16: 36.218234Z 1 [Note] A temporary password is generated for root @ localhost: waQ, qR% be2 (5
Use this password to log on to the server, the password must be changed immediately, otherwise an error will be reported as follows:

mysql> select user ();
ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement.
If only modified to a simple password, the following error message:

mysql> ALTER USER USER () IDENTIFIED BY '12345678';
ERROR 1819 (HY000): Your password does not satisfy the current policy requirements
This is actually the value validate_password_policy related.

validate_password_policy following values
The default is 1, that is MEDIUM, so the beginning of the password must be set in line with the length and must contain numbers, lowercase or uppercase letters, special characters.

Sometimes, just to test myself, do not want to set a password so complicated, say, I just want to set the root password is 123456.

You must modify two global parameters:

First, change the value of the parameter validate_password_policy

mysql> set global validate_password_policy = 0;
Query OK, 0 rows affected (0.00 sec)
Thus, the criteria for judging the password based on the length of the password. This parameter is determined by the validate_password_length.

mysql> select @@ validate_password_length;
+ ---------------------------- +
| @@ Validate_password_length |
+ ---------------------------- +
| 8 |
+ ---------------------------- +
1 row in set (0.00 sec)
validate_password_length argument defaults to 8, it has a minimum limit and a minimum of:

validate_password_number_count
+ Validate_password_special_char_count
+ (2 * validate_password_mixed_case_count)
Wherein, validate_password_number_count specifies the length of the password data, validate_password_special_char_count specifies the length of special characters in the password, validate_password_mixed_case_count specify the size of the letters in the password length.

These parameters, the default value is 1, so validate_password_length minimum of 4, if you explicitly specify a value less than 4 validate_password_length, despite not being given, but the value will be set validate_password_length 4. As follows:

mysql> select @@ validate_password_length;
+ ---------------------------- +
| @@ Validate_password_length |
+ ---------------------------- +
| 8 |
+ ---------------------------- +
1 row in set (0.00 sec)

mysql> set global validate_password_length = 1;
Query OK, 0 rows affected (0.00 sec)

mysql> select @@ validate_password_length;
+ ---------------------------- +
| @@ Validate_password_length |
+ ---------------------------- +
| 4 |
+ ---------------------------- +
1 row in set (0.00 sec)
If you modify the validate_password_number_count, validate_password_special_char_count, validate_password_mixed_case_count any value, then validate_password_length will be dynamically modified.

mysql> select @@ validate_password_length;
+ ---------------------------- +
| @@ Validate_password_length |
+ ---------------------------- +
| 4 |
+ ---------------------------- +
1 row in set (0.00 sec)

mysql> select @@ validate_password_mixed_case_count;
+ -------------------------------------- +
| @@ Validate_password_mixed_case_count |
+ -------------------------------------- +
| 1 |
+ -------------------------------------- +
1 row in set (0.00 sec)

mysql> set global validate_password_mixed_case_count = 2;
Query OK, 0 rows affected (0.00 sec)

mysql> select @@ validate_password_mixed_case_count;
+ -------------------------------------- +
| @@ Validate_password_mixed_case_count |
+ -------------------------------------- +
| 2 |
+ -------------------------------------- +
1 row in set (0.00 sec)

mysql> select @@ validate_password_length;
+ ---------------------------- +
| @@ Validate_password_length |
+ ---------------------------- +
| 6 |
+ ---------------------------- +
1 row in set (0.00 sec)
Of course, the premise is validate_password widget must already be installed, MySQL5.7 is installed by default.

So how do you verify validate_password plug is installed it? By viewing the following parameters, if not installed, the output will be empty.

mysql> SHOW VARIABLES LIKE 'validate_password%';
+ -------------------------------------- + ------- +
| Variable_name | Value |
+ -------------------------------------- + ------- +
| Validate_password_dictionary_file | |
| Validate_password_length | 6 |
| Validate_password_mixed_case_count | 2 |
| Validate_password_number_count | 1 |
| Validate_password_policy | LOW |
| Validate_password_special_char_count | 1 |
+ -------------------------------------- + ------- +
6 rows in set (0.00 sec)
     
         
       
         
  More:      
 
- C language programming entry - Common operators (Programming)
- VMware virtual machine to use bridged mode fast Internet access (Linux)
- Log device files under Linux - logger (Linux)
- Arduino UNO simulation development environment set up and run simulation (Linux)
- Use window.name + iframe cross-domain access to data Detailed (Programming)
- Python when automated operation and maintenance often used method (Programming)
- Ubuntu PPA install SMPlayer 14.9 (Linux)
- Build Python3.4 + PyQt5.3.2 + Eric 6.0 development platform Ubuntu 14.04 (Server)
- CentOS yum install LNMP PHP5.4 version (Server)
- CMake Quick Start Tutorial (Linux)
- Connect to the Oracle Database Help class (Database)
- Linux ls command (Linux)
- Compare Oracle MySQL (ICP) index condition pushdown is described (Database)
- MySQL 5.7 perfectly distributed transaction support (Database)
- Automatic and Manual Proxy Settings Switch GNOME Shell Extension Proxy Switcher Recommend (Linux)
- CentOS7 installation configuration Redis-3.0.0 (Database)
- Netfilter / Iptables Comments (Linux)
- Safe learning through self-extracting package to achieve invasion (Linux)
- CentOS and RHEL installation under GAMIT10.6 (Linux)
- Tmux create the perfect terminal management tool under CentOS (Linux)
     
           
     
  CopyRight 2002-2016 newfreesoft.com, All Rights Reserved.