Shrinking a Locally Managed Temporary Tablespace

翻译 2013年12月03日 16:58:17
Shrinking a Locally Managed Temporary Tablespace

 
   Large sortoperations performed by the database may result in a temporarytablespace growing and occupying a considerable amount of diskspace. After the sort operation completes, the extra space is notreleased; it is just marked as free and available for reuse.Therefore, a single large sort operation might result in a largeamount of allocated temporary space that remains unused after thesort operation is complete. For this reason, the database enablesyou to shrink locally managed temporary tablespaces and releaseunused space.

   执行大的排序操作可能导致临时表空间占用比较大的磁盘空间。排序操作完成后,临时表空间额外的空间的并不跟着回收。仅仅标记为空闲和可以被重新使用。因此,一个大的排序操作完成导致大量的临时表空间保持unused。基于这个原因,shrink本地管理的临时表空间,释放unused的空间。

    You use theSHRINK SPACE clause of the ALTER TABLESPACE statement to shrink atemporary tablespace, or the SHRINK TEMPFILE clause of the ALTERTABLESPACE statement to shrink a specific temp file of a temporarytablespace. Shrinking frees as much space as possible whilemaintaining the other attributes of the tablespace or temp file.The optional KEEP clause defines a minimum size for the tablespaceor temp file.

    使用带有子句SHRINKSPACE的ALTER TABLESPACE语句shrink一个临时表空间,或者带有子句SHRINK TEMPFILE的ALTERTABLESPACE语句shrink指定的临时表空间的临时文件。当维护其他属性的表空间和临时文件,Shrinking释放尽可能多的空间。KEEP子句定义了表空间或者临时文件的最小的尺寸。

    Shrinking isan online operation, which means that user sessions can continue toallocate sort extents if needed, and already-running queries arenot affected.

   Shrinking是一个online操作,意味着不会影响用户可以分配排序区和已经运行的查询。

    Thefollowing example shrinks the locally managed temporary tablespacelmtmp1 to a size of 20M.

   下面是一个Shrinks本地管理临时表空间lmtmp1到20M的例子:

    ALTERTABLESPACE lmtemp1 SHRINK SPACE KEEP 20M;

    Thefollowing example shrinks the temp file lmtemp02.dbf of the locallymanaged temporary tablespace lmtmp2. Because the KEEP clause isomitted, the database attempts to shrink the temp file to theminimum possible size.
   下面的例子是shrinks本地管理的临时表空间lmtmp2的临时文件lmtemp02.dbf。因为忽略KEEP子句,数据库尝试shrink临时文件可能最小的尺寸。

    ALTERTABLESPACE lmtemp2 SHRINK TEMPFILE'/u02/oracle/data/lmtemp02.dbf';

相关文章推荐

Oracle (temporary tablespace)临时表空间说明

首先从数据字典视图说起 v$dba_temp_files v$sort_segment v$tempseg_usage dba_temp_free_space 上面这几个视图是我总结的在...

Expert Tips on Drop Temporary Tablespace Hangs!!

Sometimes it happens that we issue the command for dropping temporary tablespace and the operation j...
  • gyanp
  • gyanp
  • 2012年04月11日 15:10
  • 588

Oracle10g新特性:临时表空间组(temporary tablespace group)

一个临时表空间组至少包含一个临时表空间。临时表空间组无法显式创建,当第一个临时表空间分配给该组时自动创建,当组内所有临时表空间被移除时自动删除。临时表空间组支持的操作:•可以将临时表空间从一个组移动到...
  • zxx2403
  • zxx2403
  • 2011年04月29日 09:00
  • 228

Oracle Temporary tablespace group

一个临时表空间组至少包含一个临时表空间。 临时表空间组无法显式创建,当第一个临时表空间分配给该组时自动创建,当组内所有临时表空间被移除时自动删除。 临时表空间组支持的操作: 可以将临时表空间...

Reducing the Number of Gray Levels,Zoming and Shrinking Images

摘 要:本实验主要是对图像进行灰度级数减小的操作以及对图像进行放大和缩小。本实验主要编写了三个程序来对图像进行处理。首先,编写了一个以2的幂次方将给定图像的灰度级数从256减少到2的程序;其次,...

数字图像处理实验(4):PROJECT 02-04 [Multiple Uses],Zooming and Shrinking Images by Bilinear Interpolation

实验要求: Zooming and Shrinking Images by Bilinear Interpolation Objective To manipulate another...

数字图像处理实验(3):PROJECT 02-03, Zooming and Shrinking Images by Pixel Replication

实验要求: Zooming and Shrinking Images by Pixel Replication Objective To manipulate a technique ...

Resource Shrinking去掉无用的资源

http://blog.csdn.net/nwsuafer/article/details/41943997 Resource Shrinking Th...

图像灰度级减少及基本缩放(Reducing the Number of Gray Levels, Zooming and Shrinking Images)

摘 要:本实验分为三部分:编写一个以2的幂次方将一幅图像的灰度级数从256减少到2;编写一个基于像素复制法的图像缩放程序,要求缩放因子为整数;编写一个基于双线性插值法的图像缩放程序,要求输入参数...
内容举报
返回顶部
收藏助手
不良信息举报
您举报文章:Shrinking a Locally Managed Temporary Tablespace
举报原因:
原因补充:

(最多只允许输入30个字)