因為晚上就要進行數(shù)據(jù)庫的考試了,所以今中午開始就努力奮斗,爭取把沒復(fù)習完的東西搞完,結(jié)果就遇見了很久以前遇見的一個錯誤,想想,這個錯誤當初在同學當中比較常見,所以寫出,希望對有這個問題的朋友有所幫助.
01033, 00000, "ORACLE initialization or shutdown in progress"
// *Cause: An attempt was made to log on while Oracle is being started up
// or shutdown.
// *Action: Wait a few minutes. Then retry the operation.
所以在http://www.sou3w.com/database16/database254111.htm就有網(wǎng)友建議重啟,效果如何.我不知道,有興趣可以自己去試.下面是我的解決的步驟.其實主要參考自下面的文章.
http://www.helpdiy.com/bbs/redirect.php?tid=208&goto=lastpost&fpage=1&sid=t2VqoX當然我的電腦沒有斷電,起因是我在做表空間練習的時候刪除了我所創(chuàng)建的數(shù)據(jù)文件,
以sys登錄為sysdba
sqlplus /NOLOG
SQL>connect sys/用戶口令as sysdba
SQL>shutdown normal
SQL>startup mount
SQL>alter database open
SQL>shutdown normal
SQL>startup
結(jié)果出現(xiàn)
SQL> alter database open
2 ;
alter database open
*
第 1 行出現(xiàn)錯誤:
ORA-01157: 無法標識/鎖定數(shù)據(jù)文件 5 - 請參閱 DBWR 跟蹤文件
ORA-01110: 數(shù)據(jù)文件 5: 'F:\ORACLE\TEST01.DBF'
由此可得出是我剛才的數(shù)據(jù)文件刪除操作引起的,怎么辦呢?
下面是我的命令行的貼圖,希望不是太亂.
ORA-01157: 無法標識/鎖定數(shù)據(jù)文件 5 - 請參閱 DBWR 跟蹤文件
ORA-01110: 數(shù)據(jù)文件 5: 'F:\ORACLE\TEST01.DBF'
SQL> alter database create datafile 5;
數(shù)據(jù)庫已更改。
SQL> conn scott/tiger
ERROR:
ORA-01033: ORACLE initialization or shutdown in progress
警告: 您不再連接到 ORACLE。
SQL> alter database datafile 5 offline drop;
SP2-0640: 未連接
SQL> conn sys/oracle
ERROR:
ORA-01033: ORACLE initialization or shutdown in progress
SQL> conn sys/oracle as sysdba;
已連接。
SQL> alter database datafile 5 offline drop;
數(shù)據(jù)庫已更改。
SQL> conn scott/tiger
ERROR:
ORA-01033: ORACLE initialization or shutdown in progres
怎么還回出現(xiàn)相同的錯誤呢?重復(fù)上面的步驟,你會發(fā)現(xiàn)
ORA-01157: 無法標識/鎖定數(shù)據(jù)文件 6- 請參閱 DBWR 跟蹤文件
ORA-01110: 數(shù)據(jù)文件 6: 'F:\ORACLE\TEST01.DBF'
和上面出現(xiàn)同一個錯誤,不過,看清楚哦,, 是數(shù)據(jù)文件6 而不是數(shù)據(jù)文件5,
那么的話,繼續(xù)吧SQL> alter database create datafile 6;
知道你重復(fù)上面的步驟,發(fā)現(xiàn)能用scott登陸為止,其實你刪除了幾個數(shù)據(jù)文件,你就要重復(fù)刪除幾次.
呵呵,抓緊時間,馬上復(fù)習.希望考個好成績!