Oracle rac模式下undo表空間爆滿的解決方案
前言
一、確認(rèn)對(duì)應(yīng)實(shí)例的undo表空間
show parameter undo
二、確認(rèn)對(duì)應(yīng)實(shí)例undo的文件位置
select file_name, bytes / 1024 / 1024 / 1024 from dba_data_files where tablespace_name like 'UNDOTBS%';
三、確認(rèn)回滾段使用情況
#如果為空則證明該表空間可以被刪除,否則要放其他時(shí)間處理尤其生產(chǎn)環(huán)境下。
select s.username, u.name from gv$transaction t, gv$rollstat r, v$rollname u, gv$session s where s.taddr = t.addr and t.xidusn = r.usn and r.usn = u.usn order by s.username;
四、檢查undo segment狀態(tài)
select usn, xacts, status, rssize / 1024 / 1024, hwmsize / 1024 / 1024, shrinks from v$rollstat order by rssize;
五、創(chuàng)建新的undo表空間并進(jìn)行切換
SQL> create pfile='/home/oracle/t1.txt' from spfile; ファイルが作成されました。 SQL> SQL> SQL> create undo tablespace undotbs02 datafile '+DATA' size 10240m autoextend on next 10m; 表領(lǐng)域が作成されました。 SQL> SQL> create undo tablespace undotbs01 datafile '+DATA' size 10240m autoextend on next 10m; 表領(lǐng)域が作成されました。 SQL> SQL> SQL> alter system set undo_tablespace=undotbs02 sid='cxldb2' scope=both; システムが変更されました。 SQL> SQL> SQL> show parameter undo NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ temp_undo_enabled boolean FALSE undo_management string AUTO undo_retention integer 10800 undo_tablespace string UNDOTBS02 SQL> ##inst_id=1 SQL> SQL> show parameter undo NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ temp_undo_enabled boolean FALSE undo_management string AUTO undo_retention integer 10800 undo_tablespace string UNDOTBS1 SQL> SQL> SQL> alter system set undo_tablespace=undotbs01 sid='cxldb1' scope=both; システムが変更されました。 SQL> SQL> show parameter undo NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ temp_undo_enabled boolean FALSE undo_management string AUTO undo_retention integer 10800 undo_tablespace string UNDOTBS01 SQL>
六、等待原undo表空間segment狀態(tài)變更為offline
select t.segment_name, t.tablespace_name, t.segment_id, t.status from dba_rollback_segs t where t.tablespace_name in ('UNDOTBS1','UNDOTBS2') and t.status != 'OFFLINE';
七、刪除原undo表空間以及數(shù)據(jù)文件
SQL> drop tablespace UNDOTBS1 including contents and datafiles; 表領(lǐng)域が削除されました。 SQL> drop tablespace UNDOTBS2 including contents and datafiles; 表領(lǐng)域が削除されました。 SQL>
以上就是Oracle rac模式下undo表空間爆滿的解決方案的詳細(xì)內(nèi)容,更多關(guān)于Oracle undo表空間爆滿的資料請(qǐng)關(guān)注腳本之家其它相關(guān)文章!
相關(guān)文章
Oracle創(chuàng)建新undo表空間最佳實(shí)踐(包含段檢查)
這篇文章主要介紹了Oracle創(chuàng)建新undo表空間最佳實(shí)踐(包含段檢查),非常不錯(cuò),具有一定的參考借鑒價(jià)值,需要的朋友可以參考下2019-04-04基于OGG實(shí)現(xiàn)Oracle實(shí)時(shí)同步MySQL的全過程
這篇文章詳細(xì)闡述了基于OGG實(shí)現(xiàn)Oracle實(shí)時(shí)同步MySQL全過程,文中通過圖文結(jié)合和代碼示例給大家講解的非常詳細(xì),對(duì)大家的學(xué)習(xí)或工作有一定的幫助,需要的朋友可以參考下2023-11-11Oracle將字符編碼從GBK轉(zhuǎn)到UTF8,如何操作比較穩(wěn)妥?
有個(gè)學(xué)校oracle數(shù)據(jù)庫的編碼是GBK,而且?guī)炖镞呉呀?jīng)有很多生產(chǎn)數(shù)據(jù)了,現(xiàn)在想改成UTF8的,如果執(zhí)行了這步操作,會(huì)出現(xiàn)哪些問題2014-02-02oracle創(chuàng)建用戶時(shí)報(bào)錯(cuò)ORA-65096:公用用戶名或角色名無效解決方式
這篇文章主要給大家介紹了關(guān)于oracle創(chuàng)建用戶時(shí)報(bào)錯(cuò)ORA-65096:公用用戶名或角色名無效的解決方式,ORA-65096錯(cuò)誤意味著你在創(chuàng)建一個(gè)新的用戶或角色時(shí),使用了一個(gè)已經(jīng)存在的公用用戶名或角色名,需要的朋友可以參考下2024-05-05oracle中add_months()函數(shù)及用法總結(jié)
這篇文章主要介紹了oracle中add_months()函數(shù)及用法總結(jié),非常不錯(cuò),具有一定的參考借鑒價(jià)值,需要的朋友可以參考下2019-08-08Oracle的數(shù)據(jù)字典技術(shù)簡(jiǎn)析
Oracle的數(shù)據(jù)字典技術(shù)簡(jiǎn)析...2007-03-03