Display Storage Map for Database | Tablespace | Datafile Storage_1377458.1
How to Display Storage Map for Database | Tablespace | Datafile Storage (Doc ID 1377458.1)
In this Document
Applies to:Oracle Database - Enterprise Edition - Version 10.1.0.2 to 11.2.0.3 [Release 10.1 to 11.2]Information in this document applies to any platform. PurposeThis note will present a set of steps by which a map of used and free space can be displayed for one or more tablespaces / datafiles RequirementsAny command line interface (SQLPLUS .. ISQLPLUS etc) ConfiguringExecuting user must have been granted access to DBA_FREE_SPACE and DBA_EXTENTS Instructions
1) Create a 'holding table' table called SPACE_MAP Caution
This sample code is provided for educational purposes only, and is not supported by Oracle Support. It has been tested internally, however, we do not guarantee that it will work for you. Ensure that you run it in your test environment before using.
Script
-- Create a 'holding table' table called SPACE_MAP Sample Output
TABLESPACE EXAMPLE select FILE_NO FILE#, TBLSP_NAME TABLESPACE, BEGIN_BLOCK BEGIN, END_BLOCK END, SEGMENT_NAME NAME, CHUNK_TYPE TYPE from SPACE_MAP where TBLSP_NAME = 'USERS' order by FILE_NO, BEGIN_BLOCK; FILE# TABLESPACE BEGIN END NAME TYPE ----- ---------- -------- -------- -------------------- ------------ 4 USERS 128 135 DEAN.ID_IND INDEX 4 USERS 136 143 DEAN.ID_IND INDEX 4 USERS 144 151 .... 4 USERS 256 263 TEST.SPACE_MAP TABLE 4 USERS 264 271 TEST.SPACE_MAP TABLE 4 USERS 272 279 TEST.SPACE_MAP TABLE 4 USERS 312 12799
select FILE_NO FILE#, TBLSP_NAME TABLESPACE, BEGIN_BLOCK BEGIN, END_BLOCK END, SEGMENT_NAME NAME, CHUNK_TYPE TYPE from SPACE_MAP where FILE_NO = 3 order by BEGIN_BLOCK; FILE# TABLESPACE BEGIN END NAME TYPE ----- ---------- -------- -------- ------------------------------ ------------ 3 UNDOTBS1 9984 10111 SYS._SYSSMU10_16154620$ TYPE2 UNDO 3 UNDOTBS1 10112 10239 SYS._SYSSMU2_3913496631$ TYPE2 UNDO 3 UNDOTBS1 10240 10367 SYS._SYSSMU2_3913496631$ TYPE2 UNDO 3 UNDOTBS1 10368 10495 SYS._SYSSMU9_2823258255$ TYPE2 UNDO ... 3 UNDOTBS1 24192 24703 3 UNDOTBS1 24704 24831 SYS._SYSSMU10_16154620$ TYPE2 UNDO 3 UNDOTBS1 24832 25471 3 UNDOTBS1 25472 25599 SYS._SYSSMU10_16154620$ TYPE2 UNDO
select FILE_NO FILE#, TBLSP_NAME TABLESPACE, BEGIN_BLOCK BEGIN, END_BLOCK END, SEGMENT_NAME NAME, CHUNK_TYPE TYPE from SPACE_MAP order by TBLSP_NAME, FILE_NO, BEGIN_BLOCK; FILE# TABLESPACE BEGIN END NAME TYPE ----- ---------- -------- -------- ------------------------------ ------------ 2 SYSAUX 128 135 SYS.SQLLOG$_PKEY INDEX 2 SYSAUX 136 143 SYS.SMB$CONFIG TABLE 2 SYSAUX 144 151 SYS.I_SMB$CONFIG_PKEY INDEX ... 1 SYSTEM 128 135 SYS.SYSTEM ROLLBACK 1 SYSTEM 136 143 SYS.SYSTEM ROLLBACK 1 SYSTEM 144 151 SYS.C_OBJ# CLUSTER ... 3 UNDOTBS1 128 135 SYS._SYSSMU1_1002995750$ TYPE2 UNDO 3 UNDOTBS1 136 143 SYS._SYSSMU8_4175155633$ TYPE2 UNDO 3 UNDOTBS1 144 151 SYS._SYSSMU2_3913496631$ TYPE2 UNDO ... 4 USERS 128 135 DEAN.ID_IND INDEX 4 USERS 136 143 DEAN.ID_IND INDEX 4 USERS 144 151 4 USERS 152 159 TEST.TRACKING TABLE ... |
|
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/17252115/viewspace-1411348/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- cmu15545-資料儲存(Database Storage)Database
- RMAN-06214: Datafile Copy
- Oracle OCP(48):UNDO TABLESPACEOracle
- MySQL 5.7 InnoDB Tablespace EncryptionMySql
- [20201103]set newname for datafile.txt
- display:flex與display:box 區別Flex
- Tablespace表空間刪除
- tabBar DisplaytabBar
- offline tablespace 的幾種方式 (轉)
- ORA-19909: datafile 1 belongs to an orphan incarnation
- storage事件中的坑,storage.setItem()無法觸發storage事件事件
- Azure Storage 系列(六)使用Azure Queue Storage
- Azure Storage 系列(七)使用Azure File Storage
- css之displayCSS
- Collapse display box
- Local Storage
- The database owner SID recorded in the master database differs from the database owner SID recorded in database 'DB_NAME'DatabaseAST
- mysql5.7 General tablespace使用說明MySql
- alter tablespace ts_name autoextend_clause
- 【TABLESPACE】Oracle表空間最佳實踐Oracle
- display:inline-flex 和 display:flex有什麼區別inlineFlex
- css display 屬性CSS
- Azure Storage 系列(四)在.Net 上使用Table Storage
- Oracle Database Cloud - Database as a Service Quick StartOracleDatabaseCloudUI
- Error querying database. XXXXXXXXXXXXX, No database selected。ErrorDatabase
- Convert a Physical Standby Database into a Snapshot Standby DatabaseDatabase
- display:block display:inline-block 的屬性、呈現和作用BloCinline
- JavaScript storage 事件JavaScript事件
- Web Storage概述Web
- Password Storage - UserDetailsAI
- 2.6.8.2 UNDO_TABLESPACE 初始化引數
- unlimited tablespace許可權的授予和回收MIT
- 【TABLESPACE】Oracle 表空間結構說明Oracle
- 利用offline datafile檔案方式遷移資料
- Rename or Move a datafile In Oracle 19c RAC-20220117Oracle
- Database TimeoutDatabase
- Database OverallDatabase
- database no shardingDatabase
- 別再用 display: contents 了