这里介绍、演示一下,安装validate_password组件时遇到ERROR 3529 (HY000): Cannot load component from specified URN: 'file://component_validate_password'错误的原因 当前测试的环境为MySQL 8.0.33 此时不重启MySQL服务,然后由于一些事情导致当你忘记已经安装过validate_password组件这件事情了,检查MySQL是否安装validate_password组件 检查发现没有安装validate_password组件,然后重新安装组件时就会遇到这个错误,如下所示: 你可以用下面方式验证,发现已经安装过validate_password组件 重启MySQL服务后,就可以从mysql.component中看到相关数据了。如下所示:mysql> select @@version;
+-----------+
| @@version |
+-----------+
| 8.0.33 |
+-----------+
1 row in set (0.00 sec)
mysql>
mysql> INSTALL COMPONENT 'file://component_validate_password';mysql> select * from mysql.plugin;
Empty set (0.00 sec)mysql> INSTALL COMPONENT 'file://component_validate_password';
ERROR 3529 (HY000): Cannot load component from specified URN: 'file://component_validate_password'.mysql> show global variables like '%validate_password%';
+--------------------------------------+--------+
| Variable_name | Value |
+--------------------------------------+--------+
| validate_password.check_user_name | ON |
| validate_password.dictionary_file | |
| validate_password.length | 8 |
| validate_password.mixed_case_count | 1 |
| validate_password.number_count | 1 |
| validate_password.policy | MEDIUM |
| validate_password.special_char_count | 1 |
+--------------------------------------+--------+
7 rows in set (0.00 sec)
mysql> mysql> select * from mysql.component;
+--------------+--------------------+------------------------------------+
| component_id | component_group_id | component_urn |
+--------------+--------------------+------------------------------------+
| 1 | 1 | file://component_validate_password |
+--------------+--------------------+------------------------------------+
1 row in set (0.00 sec)
mysql> show global variables like '%validate_password%';
+--------------------------------------+--------+
| Variable_name | Value |
+--------------------------------------+--------+
| validate_password.check_user_name | ON |
| validate_password.dictionary_file | |
| validate_password.length | 8 |
| validate_password.mixed_case_count | 1 |
| validate_password.number_count | 1 |
| validate_password.policy | MEDIUM |
| validate_password.special_char_count | 1 |
+--------------------------------------+--------+
7 rows in set (0.00 sec)
mysql>