默认情况下oracle 数据库安装完成后,用户的密码有效期为180天,如果密码过期失效会影响业务运行,所以要修改为不限制
登录sqlplus
Connected to Oracle Database 11g Enterprise Edition Release 11.2.0.1.0
Connected as hml SQL> select username,profile from dba_users; **查看用户使用的配置文件 USERNAME PROFILE------------------------------ ------------------------------HML DEFAULTSCOTT DEFAULTGOLDENGATE DEFAULTORACLE_OCM DEFAULTXS$NULL DEFAULTMDDATA DEFAULTDIP DEFAULTAPEX_PUBLIC_USER DEFAULTSPATIAL_CSW_ADMIN_USR DEFAULTSPATIAL_WFS_ADMIN_USR DEFAULTDBSNMP MONITORING_PROFILESYSMAN DEFAULTFLOWS_FILES DEFAULTMDSYS DEFAULTORDSYS DEFAULTEXFSYS DEFAULTWMSYS DEFAULTAPPQOSSYS DEFAULTAPEX_030200 DEFAULTOWBSYS_AUDIT DEFAULT USERNAME PROFILE------------------------------ ------------------------------ORDDATA DEFAULTCTXSYS DEFAULTANONYMOUS DEFAULTXDB DEFAULTORDPLUGINS DEFAULTOWBSYS DEFAULTSI_INFORMTN_SCHEMA DEFAULTOLAPSYS DEFAULTMGMT_VIEW DEFAULTSYS DEFAULTSYSTEM DEFAULTOUTLN DEFAULT 32 rows selected SQL> select * from dba_profiles s where s.profile='DEFAULT' and resource_name='PASSWORD_LIFE_TIME'; ***查看DEFAULT配置文件中密码生命周期 PROFILE RESOURCE_NAME RESOURCE_TYPE LIMIT------------------------------ -------------------------------- ------------- ----------------------------------------DEFAULT PASSWORD_LIFE_TIME PASSWORD 180 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'; ***验证查看DEFAULT配置文件中密码生命周期 PROFILE RESOURCE_NAME RESOURCE_TYPE LIMIT------------------------------ -------------------------------- ------------- ----------------------------------------DEFAULT PASSWORD_LIFE_TIME PASSWORD UNLIMITED SQL>