專案中遇到的undo表空間不足的替換

2022-08-03 06:36:14 字數 1440 閱讀 5822

1.查詢資料庫的undo表空間名

select name from v$tablespace;

2.檢查資料庫undo表空間占用空間情況以及資料檔案存放位置;

select   file_name, bytes/1024/1024 from dba_data_files;

3.檢視回滾段的使用情況,哪個使用者正在使用回滾段的資源,如果有使用者最好更換時間。

select   s.username, u.name, d.tablespace_name

from   v$transaction t,v$rollstat r, v$rollname u, v$session s, dba_rollback_segs d

where   s.taddr=t.addr and t.xidusn=r.usn and r.usn=u.usn and r.usn=d.segment_id   order by s.username;

4.檢查undo   segment狀態

select usn,   xacts, rssize/1024/1024/1024, hwmsize/1024/1024/1024, shrinks

from v$rollstat order by rssize;

5.建立新的undo表空間,並設定自動擴充套件引數;

create undo tablespace undotbs2  

datafile '

/home/oracle/product/11.2.0/oradata/srcl/undotbs02.dbf

' size 1000m reuse autoextend on next 800m maxsize

10g;

6.動態更改spfile配置檔案;

alter   system set undo_tablespace=undotbs2

scope=both;

7.等待原undo表空間所有undo   segment offline;

select   segment_name, tablespace_name, status from dba_rollback_segs;

8.再執行看undo表空間所有undo   segment online;

select   segment_name, tablespace_name, status from dba_rollback_segs;

9.刪除原有的undo表空間;

drop   tablespace undotbs1

including   contents;

10.確認刪除是否成功;

select name   from v$tablespace;

11.冊除原undo表空間的資料檔案,其檔名為步驟中執行的結果。

#rm /home/oracle/product/11.2.0/oradata/srcl/undotbs01.dbf

UNDO表空間不足解決方法

確認undo表空間名稱 select name from v tablespace 檢查資料庫undo表空間占用空間情況以及資料檔案存放位置 select file name,bytes 1024 1024 from dba data files where tablespace name like...

ORACLE的undo表空間操作

1.檢視undo表空間 select file id,file name,tablespace name,sum bytes 1024 1024 total mb,autoextensible from dba data files group by file name,file id,tables...

專案中遇到的問題

1.今天第乙個問題是滑動衝突,scrollview和recyclerview的滑動衝突,以前一直是直接用 拿焦點 今天查了一下有其他解決方法,記錄一下,方便還蠻好用,nestedscrollview 和 recyclerview 需要設定乙個這個屬性 recyclerview setnestedsc...