The fault phenomenon ORA-28002: the password will expire within 7 days Oracle Database 11g ORA-28002: the password will expire within 7 days [11:01:00oracle@dvd db_1]$sqlplus wang/oracle SQL*Plus: Release 11.2.0.1.0 Production on Fri Nov 16 11:01:23 2012 Copyright (c) 1982, 2009, Oracle. All rights reserved. ERROR: ORA-28002: the password will expire within 7 days Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production With the OLAP and Data Mining options wang@SUN >
The cause of the problem Oracle 11G There is a 180-day default password period for normal users. This is when the default password period is about to expire.
The solution View the current user corresponding to profile and corresponding password period select * from dba_profiles where profile=‘DEFAULT’ AND resource_name=‘PASSWORD_LIFE_TIME’; alter profile default limit password_life_time unlimited; SELECT username,PROFILE FROM dba_users where username like upper(’ & USER’); sys@SUN > SELECT username,PROFILE FROM dba_users where username like upper(’ & USER’); Enter value for user: wang old 1: SELECT username,PROFILE FROM dba_users where username like upper(’ & USER’) new 1: SELECT username,PROFILE FROM dba_users where username like upper(‘wang’) USERNAME PROFILE ------------------------------ ------------------------------ WANG DEFAULT Mysql > select Profile from user where DEFAULT = DEFAULT sys@SUN > set lines 222 sys@SUN > col PROFILE for a20 sys@SUN > col RESOURCE_NAME for a20 sys@SUN > col RESOURCE_TYPE for a20 sys@SUN > col LIMIT for a20 sys@SUN > select * from dba_profiles where profile=‘DEFAULT’ AND resource_name=‘PASSWORD_LIFE_TIME’; PROFILE RESOURCE_NAME RESOURCE_TYPE LIMIT -------------------- -------------------- -------------------- -------------------- DEFAULT PASSWORD_LIFE_TIME PASSWORD 180 profile password lifetime is 180 days Change the current user to profile to the corresponding password period sys@SUN > alter profile default limit password_life_time 365; Profile altered. Change the password lifetime configuration for profile to 365 days sys@SUN > alter profile default limit password_life_time unlimited; Profile altered. Change the password life cycle configuration for profile to unrestricted