- 最后登录
- 2017-5-4
- 在线时间
- 81 小时
- 威望
- 999
- 金钱
- 2391
- 注册时间
- 2013-9-11
- 阅读权限
- 150
- 帖子
- 1124
- 精华
- 5
- 积分
- 999
- UID
- 1220
|
1#
发表于 2017-4-13 10:47:06
|
查看: 1320 |
回复: 0
我在测试资料库中发现
tablespace ----drsys是在offline状态,原因是由于上次作备份的时候没有备份dr01.dbf文件,当时没有恢复此datafile便启用resetlog模式登陆资料库
现在我试着进入mount 状态下online 此datafile,在alter database open的时候,出现了错误,之后又出现无法启动资料库的错误,操作过程如下:
请问我如何登入,又如何online此datafile在没有resetlog之前的备份情况下?
SQL> connect internal/manager
已連接
SQL> shutdown immediate
資料庫關閉.
資料庫已卸載.
已關閉 ORACLE 執行項次.
SQL> startup mount
已啟動 ORACLE 執行項次.
Total System Global Area 109758492 bytes
Fixed Size 75804 bytes
Variable Size 77557760 bytes
Database Buffers 32047104 bytes
Redo Buffers 77824 bytes
資料庫已掛載.
SQL> select file#,status,name from v$data;
select file#,status,name from v$data
*
ERROR 在行 1:
ORA-01219: ??????????: ????????????????
SQL> select file#,status,name from v$datafile; FILE# STATUS
---------- -------
NAME
------------------------------------------------------------------------------
1 SYSTEM
D:\ORACLE\ORADATA\RUBY\SYSTEM01.DBF
2 ONLINE
D:\ORACLE\ORADATA\RUBY\RBS01.DBF
3 ONLINE
D:\ORACLE\ORADATA\RUBY\USERS01.DBF
FILE# STATUS
---------- -------
NAME
------------------------------------------------------------------------------
4 ONLINE
D:\ORACLE\ORADATA\RUBY\TEMP01.DBF
5 ONLINE
D:\ORACLE\ORADATA\RUBY\TOOLS01.DBF
6 ONLINE
D:\ORACLE\ORADATA\RUBY\INDX01.DBF
FILE# STATUS
---------- -------
NAME
------------------------------------------------------------------------------
7 OFFLINE
D:\ORACLE\ORADATA\RUBY\DR01.DBF
8 ONLINE
D:\ORACLE\ORADATA\RUBY\RCVCAT.ORA
選取了 8 列
SQL> alter database datafile 7 online;
資料庫已被更改
SQL> alter database open;
alter database open
*
ERROR 在行 1:
ORA-01190: ??????? 7 ?????? RESETLOGS ??
ORA-01110: ??? 7: 'D:\ORACLE\ORADATA\RUBY\DR01.DBF'
SQL> alter database open resetlogs;
alter database open resetlogs
*
ERROR 在行 1:
ORA-01139: RESETLOGS ?????????????????????
SQL> recover database
ORA-00283: ???????????????
ORA-01190: ??????? 7 ?????? RESETLOGS ??
ORA-01110: ??? 7: 'D:\ORACLE\ORADATA\RUBY\DR01.DBF'
SQL> alter database open noresetlogs
2 ;
alter database open noresetlogs
*
ERROR 在行 1:
ORA-01139: RESETLOGS ?????????????????????
SQL> alter database datafile 7 offline;
alter database datafile 7 offline
*
ERROR 在行 1:
ORA-03113: end-of-file on communication channel
SQL> alter database datafile 7 offline drop;
alter database datafile 7 offline drop
*
ERROR 在行 1:
ORA-03114: 未與 ORACLE 相連
SQL> startup
ORA-24323: 不允許數值
ORA-01031: insufficient privileges
SQL> alter database open;
alter database open
*
ERROR 在行 1:
ORA-03114: 未與 ORACLE 相連
SQL> shutdwon immediate
SP2-0734: 未知的命令, 以 "shutdwon i..." 為開始 - 忽略其他命令行.
SQL> shutdown immediate
ORA-24323: 不允許數值
ORA-01012: not logged on
SQL> alter database close;
alter database close
*
ERROR 在行 1:
ORA-03114: 未與 ORACLE 相連
SQL> shutdown abort
ORA-24323: 不允許數值
ORA-01031: insufficient privileges
SQL> connect internal/manager
ERROR:
ORA-24327: 需要外顯連接在授權給使用者之前
SQL> exit
D:\>sqlplus internal/manager
SQL*Plus: Release 8.1.7.0.0 - Production on 星期四 6月 3 09:59:14 2004
(c) Copyright 2000 Oracle Corporation. All rights reserved.
ERROR:
ORA-24327: 需要外顯連接在授權給使用者之前
輸入使用者名稱:
ERROR:
ORA-01017: 使用者名稱/密碼無效; 登入遭拒
輸入使用者名稱:
ERROR:
ORA-01017: 使用者名稱/密碼無效; 登入遭拒
SP2-0157: 已試了 3 次, 仍然無法 CONNECT 到 ORACLE 上, 正在跳出 SQL*Plus
D:\>
D:\>svrmgrl
Oracle Server Manager Release 3.1.7.0.0 - Production
Copyright (c) 2000, Oracle Corporation. All Rights Reserved.
Oracle8i Enterprise Edition Release 8.1.7.0.0 - Production
With the Partitioning option
JServer Release 8.1.7.0.0 - Production
SVRMGR> connect internal/manager
連線.
SVRMGR> alter database open;
alter database open
*
ORA-03114: not connected to ORACLE
SVRMGR> startup
ORA-01031: insufficient privileges
SVRMGR> startup mount
ORA-01031: insufficient privileges
SVRMGR>
在上叙启动失败后重新启动资料库
連到:
Oracle8i Enterprise Edition Release 8.1.7.0.0 - Production
With the Partitioning option
JServer Release 8.1.7.0.0 - Production
SQL> select file#,status,name from v$datafile;
FILE# STATUS
---------- -------
NAME
------------------------------------------------------------------------------
1 SYSTEM
D:\ORACLE\ORADATA\RUBY\SYSTEM01.DBF
2 ONLINE
D:\ORACLE\ORADATA\RUBY\RBS01.DBF
3 ONLINE
D:\ORACLE\ORADATA\RUBY\USERS01.DBF
FILE# STATUS
---------- -------
NAME
------------------------------------------------------------------------------
4 ONLINE
D:\ORACLE\ORADATA\RUBY\TEMP01.DBF
5 ONLINE
D:\ORACLE\ORADATA\RUBY\TOOLS01.DBF
6 ONLINE
D:\ORACLE\ORADATA\RUBY\INDX01.DBF
FILE# STATUS
---------- -------
NAME
------------------------------------------------------------------------------
7 ONLINE
D:\ORACLE\ORADATA\RUBY\DR01.DBF
8 ONLINE
D:\ORACLE\ORADATA\RUBY\RCVCAT.ORA
選取了 8 列
不知道算不算恢复成功呢? |
|