加入收藏 | 设为首页 | 会员中心 | 我要投稿 上饶站长网 (https://www.0793zz.com.cn/)- 数据库平台、视觉智能、智能搜索、决策智能、迁移!
当前位置: 首页 > 站长百科 > 正文

Oracle解决用户锁的问题

发布时间:2021-02-24 08:45:02 所属栏目:站长百科 来源:网络整理
导读:sqlplus / as sysdba 登录数据库以最高权限登录 SQL*Plus: Release 11.2.0.1.0 Production on Thu Apr 11 09:00:05 2019 Copyright (c) 1982,2009,Oracle. All rights reserved. Connected to an idle instance. SQL show user; 产看当前登录用户 USER is "S
ANONYMOUS EXPIRED & LOCKED 此时状态为过期并且锁住 APEX_030200 EXPIRED & LOCKED APEX_PUBLIC_USER EXPIRED & LOCKED APPQOSSYS EXPIRED & LOCKED BI EXPIRED & LOCKED CTXSYS EXPIRED & LOCKED DBSNMP OPEN 开放的 DIP EXPIRED & LOCKED EXFSYS EXPIRED & LOCKED FLOWS_FILES EXPIRED & LOCKED HR EXPIRED 过期的 IX EXPIRED & LOCKED MDDATA EXPIRED & LOCKED MDSYS EXPIRED & LOCKED MGMT_VIEW OPEN OE EXPIRED & LOCKED OLAPSYS EXPIRED & LOCKED ORACLE_OCM EXPIRED & LOCKED ORDDATA EXPIRED & LOCKED ORDPLUGINS EXPIRED & LOCKED ORDSYS EXPIRED & LOCKED OUTLN EXPIRED & LOCKED OWBSYS EXPIRED & LOCKED OWBSYS_AUDIT EXPIRED & LOCKED PM EXPIRED & LOCKED SCOTT OPEN SH EXPIRED & LOCKED SI_INFORMTN_SCHEMA EXPIRED & LOCKED SPATIAL_CSW_ADMIN_USR EXPIRED & LOCKED SPATIAL_WFS_ADMIN_USR EXPIRED & LOCKED SYS OPEN SYSMAN OPEN SYSTEM OPEN WMSYS EXPIRED & LOCKED XDB EXPIRED & LOCKED XS$NULL EXPIRED & LOCKED

SQL> alter user hr account unlock;

更改用户hr帐户为未锁

SQL> alter user hr identified by hr;

更改用户hr密码为hr

SQL> conn hr /hr

切换用为hr/密码为hr

Connected.

SQL> show user

查看当前登录账号

USER is "HR"

SQL>

(编辑:上饶站长网)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

sqlplus / as sysdba

登录数据库以最高权限登录

SQL*Plus: Release 11.2.0.1.0 Production on Thu Apr 11 09:00:05 2019

Copyright (c) 1982,2009,Oracle. All rights reserved.

Connected to an idle instance.

SQL> show user;

产看当前登录用户

USER is "SYS"

SQL> startup

启动数据库

ORACLE instance started.

Total System Global Area 784998400 bytes

Fixed Size 2217464 bytes

Variable Size 482347528 bytes

Database Buffers 293601280 bytes

Redo Buffers 6832128 bytes

Database mounted.

Database opened.

SQL> select username,account_status from dba_users order by username;

查看OracleDBA_USER视图
DBA_USERS视图中ACCOUNT_STATUS记录的用户的当前状态,一般情况下在使用的正常用户均处于OPEN状态。
例如我们查看sec用户的当前状态,此时该用户处于OPEN状态,可以正常使用。

USERNAME ACCOUNT_STATUS 状态
    热点阅读