Home  >  Article  >  Database  >  Oracle表空间数据文件丢失的恢复

Oracle表空间数据文件丢失的恢复

WBOY
WBOYOriginal
2016-06-07 17:01:431209browse

创建不了Oracle表,就登陆服务器看下了,我试着创建了一个表,提示表空间不足,那这个好办扩大表空间就OK了呗,正在得意洋洋的时候,出

创建不了Oracle表,就登陆服务器看下了,我试着创建了一个表,提示表空间不足,那这个好办扩大表空间就OK了呗,正在得意洋洋的时候,出现了如下的2个错误:

ORA-01157: cannot identify/lock data file 10 - see DBWR trace file

ORA-01110: data file 10: '/home/oracle/oradata/ora10/xxt_mt_msg09.ora'

郁闷,居然出现了错误,看了当前目录居然这个文件不知道被谁删除了,我直接狂汗,通过千辛万苦找了解决的方法:

SQL>  startup mount ;
SQL>  alter database create datafile '/home/oracle/oradata/ora10/xxt_mt_msg09.ora';
SQL>  set autorecovery on;
SQL>  recover datafile '/home/oracle/oradata/ora10/xxt_mt_msg09.ora';
SQL>  alter database datafile '/home/oracle/oradata/ora10/xxt_mt_msg09.ora' online;

SQL>  alter   tablespace   XXT_mt_as_msg   online;

SQL>  alter database open;

现在再到当前的数据库文件目录发现这个xxt_mt_msg09.ora已经还原回来了,然后重新扩大了下表空间,这下又可以创建表了.

linux

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn