{"id":4349,"date":"2025-06-20T07:47:27","date_gmt":"2025-06-20T07:47:27","guid":{"rendered":"https:\/\/w3buddy.com\/?p=4349"},"modified":"2026-01-15T12:44:11","modified_gmt":"2026-01-15T07:14:11","slug":"how-to-fix-ora-28011-the-account-will-expire-soon-change-your-password-now","status":"publish","type":"post","link":"https:\/\/w3buddy.com\/blog\/how-to-fix-ora-28011-the-account-will-expire-soon-change-your-password-now\/","title":{"rendered":"How to Fix \u201cORA-28011: the account will expire soon; change your password now\u201d"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">If you&#8217;ve logged into your Oracle database and seen this message:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>ORA-28011: the account will expire soon; change your password now<\/code><\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">don\u2019t panic. It&#8217;s not an error that stops you from working\u2014it\u2019s more of a warning. But it <em>does<\/em> mean that Oracle is nudging you to take action soon.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Let\u2019s walk through <strong>why it happens<\/strong>, <strong>how to check your user\u2019s password policies<\/strong>, and <strong>how to make it go away permanently<\/strong>.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\ud83d\udccc What Does ORA-28011 Mean?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">When you see:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>SQL> conn SCOTT\/TIGER@orcl\nORA-28011: the account will expire soon; change your password now\nConnected.<\/code><\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">You&#8217;re still logged in successfully. The warning simply means your password is currently in the <strong>grace period<\/strong>\u2014a window after expiration where logins are still allowed, but Oracle wants you to change your password.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">This happens when Oracle\u2019s password expiration policy is in effect, even if you recently updated your profile to remove expiration.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Step 1: Check the Password Policy<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Oracle uses <em>profiles<\/em> to manage password policies. Let\u2019s find out what policy applies to your user:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>SELECT profile FROM dba_users WHERE username = 'SCOTT';<\/code><\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Assume the result is <code>DEFAULT<\/code>. Now, inspect that profile\u2019s password rules:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>COLUMN resource_name FORMAT A30\nCOLUMN limit FORMAT A30\n\nSELECT resource_name, limit \nFROM dba_profiles \nWHERE profile = 'DEFAULT' \n  AND resource_name LIKE 'PASSWORD%' \nORDER BY resource_name;<\/code><\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">A typical output might look like this:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>RESOURCE_NAME                 LIMIT\n---------------------------- ------------------------------\nPASSWORD_GRACE_TIME          7\nPASSWORD_LIFE_TIME           180\nPASSWORD_LOCK_TIME           1\nPASSWORD_REUSE_MAX           UNLIMITED\nPASSWORD_REUSE_TIME          UNLIMITED\nPASSWORD_VERIFY_FUNCTION     NULL<\/code><\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This tells us that passwords expire every 180 days, and after expiration, users have 7 days (grace period) to change them.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Step 2: Why the Warning Won\u2019t Go Away Automatically<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Even if you later alter the profile to remove expiration like this:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>ALTER PROFILE DEFAULT LIMIT PASSWORD_LIFE_TIME UNLIMITED;\nALTER PROFILE DEFAULT LIMIT PASSWORD_GRACE_TIME UNLIMITED;<\/code><\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u2026you may still see ORA-28011 <strong>until the user resets their password manually<\/strong>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">That\u2019s because Oracle tracks password status per user. If a password was already expired or in grace before you changed the profile, the warning persists until you refresh the password.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u2705 Step 3: Reset the Password (Even If It\u2019s the Same)<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">To clear the warning, simply reset the password. You can reuse the existing password:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>ALTER USER SCOTT IDENTIFIED BY TIGER;<\/code><\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">That\u2019s it. The next time you connect:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>SQL> conn SCOTT\/TIGER@orcl\nConnected.<\/code><\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">No more warning.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Bonus: Make Sure Future Users Don\u2019t See This<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">To apply no-expiry rules permanently to all future users, ensure your default profile is set like this:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>ALTER PROFILE DEFAULT LIMIT \n  PASSWORD_LIFE_TIME UNLIMITED \n  PASSWORD_GRACE_TIME UNLIMITED \n  PASSWORD_LOCK_TIME UNLIMITED \n  PASSWORD_REUSE_TIME UNLIMITED \n  PASSWORD_REUSE_MAX UNLIMITED;<\/code><\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">\ud83d\udca1 Summary<\/h3>\n\n\n\n<figure class=\"wp-block-table has-small-font-size\"><table><thead><tr><th>Step<\/th><th>Action<\/th><\/tr><\/thead><tbody><tr><td>1\ufe0f\u20e3<\/td><td>Check the user\u2019s profile and password limits<\/td><\/tr><tr><td>2\ufe0f\u20e3<\/td><td>If needed, update the profile to remove expiry<\/td><\/tr><tr><td>3\ufe0f\u20e3<\/td><td>Reset the user\u2019s password to clear the ORA-28011 warning<\/td><\/tr><tr><td>4\ufe0f\u20e3<\/td><td>Confirm successful login without warning<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\">Final Note<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">ORA-28011 is not an error you should ignore forever. If password security matters in your environment (and it usually should), consider keeping expiration policies in place\u2014but document them well and set up alerts before expiry, so users aren\u2019t surprised.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you&#8217;ve logged into your Oracle database and seen this message: don\u2019t panic. It&#8217;s not an error that stops you from working\u2014it\u2019s more of a warning. But it does mean that Oracle is nudging you to take action soon. Let\u2019s walk through why it happens, how to check your user\u2019s password policies, and how to [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"googlesitekit_rrm_CAowu461DA:productID":"","footnotes":""},"categories":[1225],"tags":[],"class_list":["post-4349","post","type-post","status-publish","format-standard","hentry","category-database"],"_links":{"self":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/posts\/4349","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/comments?post=4349"}],"version-history":[{"count":1,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/posts\/4349\/revisions"}],"predecessor-version":[{"id":4350,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/posts\/4349\/revisions\/4350"}],"wp:attachment":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/media?parent=4349"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/categories?post=4349"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/tags?post=4349"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}