Oracle 10g Automatic Undo Retention Tuning

| 4 Comments

Undo_retention Oracle 9i 开始出现新的初始化参数.Oracle 9i 的 Undo 管理特性使得 Ora-1555 错误大大减少, 但是 Undo_retention 的设置仍然会个别的时候出现问题.

Oracle 10g 有自动Automatic Undo Retention Tuning 这个特性.设置的 undo_retention 参数只是一个指导值, Oracle 会自动调整 Undo (会跨过 undo_retention 设定的时间) 来保证不会出现 Ora-1555 错误. 通过查询 V$UNDOSTAT 的 tuned_undoretention 字段可以得到 Oracle 根据事务量(如果是文件不可扩展,则会考虑剩余空间)采样后的自作主张的 retenton 时间. 这样对于一个 事务量分布不均匀的数据库来说, 就会引发潜在的问题--在批处理的时候可能 Undo 会用光. 而且这个状态将一直持续, 不会释放.

10g 中, 如果数据文件的属性是 autoextensible , 则 undo_retention 参数必须设置. 如果 undo 表空间的文件属性是不可扩展的, 则 undo_retention 将不会起到什么作用(修正的办法是把该 Undo 表空间属性设置为GUARANTEE ).

通过如下命令(undotbs01 是undo 表空间名字):

ALTER TABLESPACE undotbs01 RETENTION GUARANTEE;

然后可以查询 DBA_tablespaces 的 retention 列. undo 表空间的属性和普通表空间的属性是不一样的.

-End

4 Comments

Oracle没玩过,只会sqlserver,落伍啊

Oracle没玩过,只会sqlserver,落伍啊

这个blog似乎不提供全文输出feed.希望能够提供.谢谢.

多谢关注! 我将很快修改

关于本文

This page contains a single entry by Fenng published on April 28, 2006 8:46 PM.

"奖" , 读书 was the previous entry in this blog.

RSS Feed 提供全文输出 is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.