成功安裝oracle後會有一個預設密碼略,比如使用者的密碼有效期間和鎖定策略...,在預設情況下oracle使用者密碼有效期間是180天,失敗登入嘗試次數最大10次然後就被鎖定。
650) this.width=650;" title="1.jpg" src="http://www.bkjia.com/uploads/allimg/131229/21532B0b-0.jpg" width="535" height="307" />
如果想密碼有效期間設定用雩都有效、使用者可以無限次去嘗試登入,這時候需要修改下預設策略
查看oracle預設的密碼有效期間策略180天)
SQL> Select * FROM dba_profiles s Where s.profile='DEFAULT' AND resource_name='PASSWORD_LIFE_TIME';
PROFILE RESOURCE_NAME RESOURCE
------------------------------ -------------------------------- --------
LIMIT
----------------------------------------
DEFAULT PASSWORD_LIFE_TIME PASSWORD
180
設定oracle預設策略為永久有效
SQL> Alter PROFILE DEFAULT LIMIT PASSWORD_LIFE_TIME UNLIMITED;
Profile altered.
再次查看
SQL> Select * FROM dba_profiles s Where s.profile='DEFAULT' AND resource_name='PASSWORD_LIFE_TIME';
PROFILE RESOURCE_NAME RESOURCE
------------------------------ -------------------------------- --------
LIMIT
----------------------------------------
DEFAULT PASSWORD_LIFE_TIME PASSWORD
UNLIMITED
查看oracle預設密碼鎖定策略
SQL> Select * FROM dba_profiles s Where s.profile='DEFAULT' AND resource_name='FAILED_LOGIN_ATTEMPTS';
PROFILE RESOURCE_NAME RESOURCE
------------------------------ -------------------------------- --------
LIMIT
----------------------------------------
DEFAULT FAILED_LOGIN_ATTEMPTS PASSWORD
設定為無數次
SQL> Alter PROFILE DEFAULT LIMIT FAILED_LOGIN_ATTEMPTS UNLIMITED;
Profile altered.
SQL> Select * FROM dba_profiles s Where s.profile='DEFAULT' AND resource_name='FAILED_LOGIN_ATTEMPTS';
PROFILE RESOURCE_NAME RESOURCE
------------------------------ -------------------------------- --------
LIMIT
----------------------------------------
DEFAULT FAILED_LOGIN_ATTEMPTS PASSWORD
UNLIMITED
SQL> commit
2 ;
Commit complete.
本文出自 “神奇的網路” 部落格,請務必保留此出處http://wxlxiao5.blog.51cto.com/4284565/1294286