大家好,又见面了,我是你们的朋友全栈君。
ORACLE12.2中用户无法登陆报ORA-01017的解决办法
错误现象:
在ORACLE12.2中创建一个用户linfy后,登陆:
SQL> show pdbs;
CON_ID CON_NAME OPEN MODE RESTRICTED
———- —————————— ———- ———-
2 PDB$SEED READ ONLY NO
3 ORCLPDB READ WRITE NO
SQL> alter session set container=orclpdb;
Session altered.
SQL> conn linfy/linfy@orclpdb
ERROR:
ORA-01017: invalid username/password; logon denied
Warning: You are no longer connected to ORACLE.
原因:将系统参数sec_case_sensitive_logon设置成FALSE导致。
SQL> show parameter sec
NAME TYPE VALUE
———————————— ———– ——————————
db_securefile string PREFERRED
optimizer_secure_view_merging boolean TRUE
sec_case_sensitive_logon boolean FALSE
原因分析:
SQL> select PASSWORD_VERSIONS from cdb_users where username=’LINFY’;
PASSWORD_VERSIONS
—————–
11G 12C
参见官方文档:
The new Exclusive Mode default for password-based authentication in Oracle 12.2 conflicts with case-insensitive password configurations. All user login fails with ORA-1017 after upgrade to 12.2 (文档 ID 2075401.1)
具体内容如下:
The ability for a client to authenticate depends on theDBA_USERS.PASSWORD_VERSIONSvalue on the server for that account.
Note the following implications of setting the value to12or12a:
The settingSEC_CASE_SENSITIVE_LOGON=FALSEmust not be used because case insensitivity requires the use of the10Gpassword version. If it is set asFALSE, then user accounts and secure roles become unusable because Exclusive Mode excludes the use of the10Gpassword version. TheSEC_CASE_SENSITIVE_LOGONinitialization parameter enables or disables case sensitivity for passwords.
Note:
The use of the Oracle instance initialization parameterSEC_CASE_SENSITIVE_LOGONis deprecated in favor of setting theSQLNET.ALLOWED_LOGON_VERSION_SERVERparameter to12or12ato ensure that passwords are treated in a case-sensitive fashion.
解决办法:
SQL> alter system set sec_case_sensitive_logon=TRUE;
System altered.
SQL> conn linfy/linfy@orclpdb
Connected.
发布者:全栈程序员-用户IM,转载请注明出处:https://javaforall.cn/142717.html原文链接:https://javaforall.cn
【正版授权,激活自己账号】: Jetbrains全家桶Ide使用,1年售后保障,每天仅需1毛
【官方授权 正版激活】: 官方授权 正版激活 支持Jetbrains家族下所有IDE 使用个人JB账号...