Standard GIS storage recommendations favor keeping index and log files separate from vector and tabular business tables. For performance reasons, it is better to position the business, feature, and spatial index tables separately and position tablespace data files based on their usage pattern. For a multi-versioned, highly active editing geodatabase, database files of the VERSIONS tablespace may be separated and dispersed across available disks to avoid input/output contention.
Create new tablespaces to store the workspace feature classes and tables.
The following table lists the tablespaces that are going to be created in the SQL example.
tablespace | CONFIGURATION KEYWORD_PARAMETER |
---|---|
NIS_BDATA | Business table |
NIS_BINDEX | Business table index |
NIS_SDATA | Spatial Index table |
NIS_SINDEX | Spatial Index table index |
NIS_ADATA | Adds table (versioned) |
NIS_AINDEX | Adds table index |
NIS_DDATA | Deletes table (versioned) |
NIS_DINDEX | Deletes table index |
NIS_XMLDOC | XML documents |
NIS_XMLIDX | XML documents indexes |
NIS_SDEDICT | Data dictionary (if implementing user-schema geodatabase) |
NIS_SDEDICTINDEX | Data dictionary index (if implementing user-schema geodatabase) |
The following script can be used to create tablespaces using Oracle SQL*Plus or Oracle SQL Developer.
ALTER SYSTEM SET WALLET OPEN IDENTIFIED BY "nisadmin";
CREATE SMALLFILE TABLESPACE "NIS_BDATA"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_BDATA01.dbf'SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_BINDEX"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_BINDEX01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_FDATA"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_FDATA01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_FINDEX"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_FINDEX01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_SDATA"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_SDATA01.dbf'SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_SINDEX"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_SINDEX01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_ADATA"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_ADATA01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_AINDEX"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_AINDEX01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_DDATA"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_DDATA01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_DINDEX"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_DINDEX01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_XMLDOC"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_XMLDOC01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_XMLINDEX"
DATAFILE 'D:\ORACLE\ORADATA\NISDB\NIS_XMLINDEX01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_SDEDICT"
DATAFILE D:\ORACLE\ORADATA\NISDB\NIS_SDEDICT01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
CREATE SMALLFILE TABLESPACE "NIS_SDEDICTINDEX"
DATAFILE D:\ORACLE\ORADATA\NISDB\NIS_SDEDICTINDEX01.dbf' SIZE 10M AUTOEXTEND ON NEXT 1M MAXSIZE 400M
LOGGING EXTENT MANAGEMENT LOCAL UNIFORM SIZE 128K
SEGMENT SPACE MANAGEMENT AUTO
DEFAULT COMPRESS FOR OLTP STORAGE ( ENCRYPT ) ENCRYPTION USING 'AES256';
Set the data files’ initial size to 10 MB so there is no delay in the creation of the tablespaces. You can then resize the data files to avoid fragmentation.
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Bdata01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Bindex01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Fdata01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Findex01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Sdata01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Sindex01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Adata01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Aindex01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Ddata01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Dindex01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Xmldoc01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Xmlindex01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Sdedict01.dbf' RESIZE 400M;
ALTER DATABASE DATAFILE 'D:\ORACLE\ORADATA\NISDB\nis_Sdedictindex01.dbf' RESIZE 400M;