tablespace management 表空间管理

TABLESPACE MANAGERMENT

including permanent,undo and temporary tablespace and some notices

 

1.the creation of general tablespace:

 

CREATE TABLESPACE tbsctnr1

DATAFILE '/opt/oracle/oradata/balance/ctnr01'

SIZE 10M AUTOEXTEND OFF

LOGGING

ONLINE

FLASHBACK ON

BLOCKSIZE 8192

EXTENT MANAGEMENT LOCAL UNIFORM. SIZE 128K

SEGMENT SPACE MANAGEMENT AUTO

;

 

2.the creation of general tablespace with multiple datafiles:

 

CREATE TABLESPACE tbstest1

DATAFILE

'/opt/oracle/oradata/balance/test1.dbf' SIZE 10M AUTOEXTEND OFF,

'/opt/oracle/oradata/balance/test2.dbf' SIZE 10M AUTOEXTEND OFF

LOGGING

ONLINE

FLASHBACK ON

BLOCKSIZE 8192

EXTENT MANAGEMENT LOCAL UNIFORM. SIZE 128K

SEGMENT SPACE MANAGEMENT AUTO

;

 

3.the modification of renaming the filename of the tablespace:

 

ALTER TABLESPACE tbsctnr1 OFFLINE;

ALTER TABLESPACE tbsctnr1 RENAME DATAFILE '/opt/oracle/oradata/balance/ctnr01' to '/opt/oracle/oradata/balance/ctnr01.dbf';

ALTER TABLESPACE tbsctnr1 ONLINE;

 

4.the deletion of the tablespace:

 

DROP TABLESPACE tbstest1 INCLUDING CONTENTS AND DATAFILES CASCADE CONSTRAINTS;

 

5.the creation of temporary tablespace(the temporay tablespace can't specify the non-default block size and just can use uniform. size to specify the extent management):

 

CREATE TEMPORARY TABLESPACE tmptbs

TEMPFILE '/opt/oracle/oradata/balance/tmptbs01.dbf'  SIZE 10M AUTOEXTEND OFF

BLOCKSIZE 8192

TABLESPACE GROUP ''

EXTENT MANAGEMENT LOCAL UNIFORM. SIZE 128K

;

 

5.the creation of undo tablespace(the undo tablespace can't specify the uniform. to extent management):

 

CREATE UNDO TABLESPACE tmptbs

DATAFILE '/opt/oracle/oradata/balance/tmptbs01.dbf'  SIZE 10M AUTOEXTEND OFF

BLOCKSIZE 8192

EXTENT MANAGEMENT LOCAL AUTOALLOCATE

RETENTION NOGUARANTEE

;

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/13605188/viewspace-609201/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/13605188/viewspace-609201/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值