【Oracle】ORA-01157: cannot identify/lock data file 201 - see DBWR trace file


今天數據庫在查詢數據的時候顯示了這個錯誤:

ORA-01157: cannot identify/lock data file 201 - see DBWR trace file ORA-01110: data file 201: '/u01/app/oracle/oradata/ORA11GR2/temp01.dbf'
---查看臨時表空間 SYS@GOOD> select FILE_NAME, TABLESPACE_NAME from dba_temp_files; select FILE_NAME, TABLESPACE_NAME from dba_temp_files * ERROR at line 1: ORA-01157: cannot identify/lock data file 201 - see DBWR trace file ORA-01110: data file 201: '/u01/app/oracle/oradata/ORA11GR2/temp01.dbf'

很明顯這是我的臨時表空間數據文件丟失了,導致不能查看數據文件

解決辦法:

---刪除文件 SYS@GOOD> alter database tempfile '/u01/app/oracle/oradata/ORA11GR2/temp01.dbf'drop; Database altered. ---重建文件 SYS@GOOD> alter tablespace temp add tempfile'/u01/app/oracle/oradata/GOOD/temp01.dbf'size 100M; Tablespace altered. ---驗證文件 SYS@GOOD> select file_name,tablespace_name from dba_temp_files; FILE_NAME TABLESPACE_NAME ---------------------------------------------- ------- /u01/app/oracle/oradata/GOOD/temp01.dbf TEMP 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM