Update Password Life Time in Oracle Database

Update Password Life Time in Oracle Database

For testing database, disable password life time will be able to avoid following error

ORA-28002: the password will expire within 7 days

Login as sys

Using sys password (created during database instance creation) to login to sysdba

sqlplus sys@xepdb1 as sysdba

Find out profile for the user

select username, profile from dba_users where username like '<user_id>';

Check profile settings

select RESOURCE_NAME,resource_type,LIMIT from dba_profiles where PROFILE='<profile_name>';

Update profile

ALTER PROFILE <profile_name> LIMIT PASSWORD_LIFE_TIME UNLIMITED;

Check the password status

SELECT ACCOUNT_STATUS FROM DBA_USERS WHERE USERNAME='<user_id>'

Change password

# sqlplus <user_id>/<pwd>@xepdb1
...

SQL> password
Changing password for <user_id>
Old password:
New password:
Retype new password:
Password changed
SQL> quit

References

How to resolve ORA-28002: the password will expire

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>


The reCAPTCHA verification period has expired. Please reload the page.