oracle 11g rac undo表空间切换(三)
762171886$ ONLINE
UNDOTBS2 _SYSSMU12_4222198645$ ONLINE
UNDOTBS2 _SYSSMU11_4155293491$ ONLINE
UNDOTBS3 _SYSSMU30_2992889604$ OFFLINE
TABLESPACE_NAME SEGMENT_NAME STATUS
------------------------------ ------------------------------ ----------------
UNDOTBS3 _SYSSMU29_3198754354$ OFFLINE
UNDOTBS3 _SYSSMU28_3953353629$ OFFLINE
UNDOTBS3 _SYSSMU27_2811255809$ OFFLINE
UNDOTBS3 _SYSSMU26_3953879438$ OFFLINE
UNDOTBS3 _SYSSMU25_3485703372$ OFFLINE
UNDOTBS3 _SYSSMU24_1121934957$ OFFLINE
UNDOTBS3 _SYSSMU23_153918182$ OFFLINE
UNDOTBS3 _SYSSMU22_1502226063$ OFFLINE
UNDOTBS3 _SYSSMU21_3331829347$ OFFLINE
31 rows selected.
删除undotbs3
SQL> drop tablespace undotbs3 including contents and datafiles;
Tablespace dropped.
SQL>
节点2 操作类似:
s[oracle@db2 ~]$ sqlplus / as sysdba
SQL*Plus: Release 11.2.0.3.0 Production on Thu Oct 17 15:25:38 2013
Copyright (c) 1982, 2011, Oracle. All rights reserved.
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options
SQL> show parameter undo;
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
undo_management string AUTO
undo_retention integer 900
undo_tablespace string UNDOTBS2
创建undotbs3 5000m,用来替换undotbs2
SQL> CREATE UNDO TABLESPACE "UNDOTBS3" DATAFILE '+DATA' SIZE 500m;
Tablespace created.
修改系统undo为undotbs3
SQL> alter system set undo_tablespace=UNDOTBS3 scope=both;
System altered.
SQL> show parameter undo;
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
undo_management string AUTO
undo_retention integer 900
undo_tablespace string UNDOTBS3
查看数据库回滚段的 status,发现undotbs2 offline, undotbs3 online
SQL> select tablespace_name,segment_name,status from dba_rollback_segs;
TABLESPACE_NAME SEGMENT_NAME STATUS
------------------------------ ------------------------------ ----------------
SYSTEM SYSTEM ONLINE
UNDOTBS1 _SYSSMU31_1711600031$ ONLINE
UNDOTBS1 _SYSSMU9_2798512696$ ONLINE
UNDOTBS1 _SYSSMU8_995173842$ ONLINE
UNDOTBS1 _SYSSMU7_3917959301$ ONLINE
UNDOTBS1 _SYSSMU6_2267393390$ ONLINE
UNDOTBS1 _SYSSMU5_1243198418$ ONLINE
UNDOTBS1 _SYSSMU4_2867323$ ONLINE
UNDOTBS1 _SYSSMU3_4052593799$ ONLINE
UNDOTBS1 _SYSSMU2_3024038969$ ONLINE
UNDOTBS1 _SYSSMU1_2935730364$ ONLINE
TABLESPACE_NAME SEGMENT_NAME STATUS
------------------------------ -------