After the successful installation of the Oracle database, the first use of the following problem occurs,
Here are just 3 ways to do this:
L Sql*plus
L OEM Control console
L Windows Console
1. Take the Windows console as an example
A. Run the cmd command as an administrator
B. Enter "Sqlplus/nolog"
C. Enter "Conn/as sysdba"
C. Enter "Startup"
2. Take Sql*plus as an example
A. Preparation
First use Sql*plus to connect to Oracle
"Sqlplus/nolog" starts sql*plus in a way that does not connect to the database
"Connect/as SYSDBA" connects to Oracle as DBA
B. Start
"Startup"
3.OEM console, more trouble, here does not introduce
To unlock the Scott account by installing the Oracle database
Completed Oracle 10g database and forgot to unlock the Scott account. This can be in the SQL Plus tool (start | All Programs |<oracle-home>| Application Development | SQL Plus), or you can unlock the Scott account from the console via the command line.
In the first case, log in to SQL Pluswith the SYSTEM account + password you set when you installed it,
Then use the command "alter user Scott account unlock;" To unlock it.
After the solution is finished, use the following command to view: "select Username,account_status from Dba_users;",
You can see that the Scott account has been unlocked, but the status is still "expired" (password expired) meaning.
Never mind, enter the command "alter user Scott identified by Tiger;" and give it a new password.
Exit and log in as Scott/tiger .
In the second case, use Windows's Console (program | run, enter CMD to open). Under command line, enter Sqlplus/nolog, carriage return, the sql> command prompt appears, and then enter the command in the following order:
Sql>conn/as SYSDBA
Sql>alter user Scott account unlock;
Sql>disconnect
Sql>conn scott/[email protected];
The password is now expired, please enter a new password. Then enter two new defined passwords to enter the password separately to confirm that the Scott account is given a new password. Open SQL Plus and log in with your Scott account.
PL/SQL Login
Oracle Startup/shutdown Scott unlock Login