Oracle users to solve the problem of lock

sqlplus / as sysdba

Log in Log in as the highest authority database

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;

Look currently logged on user productivity

USER is "SYS"

SQL> startup

Start the database

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;

See OracleDBA_USER view
user DBA_USERS ACCOUNT_STATUS view of the current state of the recording, in general, the normal user to use both in the OPEN state.
For example, we see sec user's current state, then the user is in the OPEN state, can be used normally.

USERNAME ACCOUNT_STATUS status
ANONYMOUS EXPIRED & LOCKED The status is expired and locked
APEX_030200 EXPIRED & LOCKED
APEX_PUBLIC_USER EXPIRED & LOCKED
APPQOSSYS EXPIRED & LOCKED
WITH A EXPIRED & LOCKED
CTXSYS EXPIRED & LOCKED
DBSNMP OPEN Open
DIP EXPIRED & LOCKED
EXFSYS EXPIRED & LOCKED
FLOWS_FILES EXPIRED & LOCKED
HR EXPIRED 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;

Changing user hr account is unlocked

SQL> alter user hr identified by hr;

Change the password for the user hr hr

SQL> conn hr /hr

Switching of hr / hr password

Connected.

SQL> show user

View current login account

USER is "HR"

SQL>

Guess you like

Origin blog.51cto.com/13660858/2403685
Recommended