暂无图片
dba_tablespace_usage_metrics中关于undo表空间使用率的问题
我来答
分享
手机用户3302
2020-04-29
dba_tablespace_usage_metrics中关于undo表空间使用率的问题
暂无图片 15M

oracle版本为11.2.0.3;
通过dba_tablespace_usage_metrics查询undo表空间使用率不到1%;
但通过dba_undo_extents查询sum(bytes/1024/1024)结果使用了几十G,占dba_data_files中undo表空间的sum(bytes/1024/1024)的90%,而且status都是unexpired的。
不理解是什么原理?
这undo表空间使用率应该按哪个为准?或者哪个更准确?

我来答
添加附件
收藏
分享
问题补充
5条回答
默认
最新
zouxiang

DBA_TABLESPACE_USAGE_METRICS Does Not Include Undo Tablespace Information (Doc ID 2491036.1)

Bug 28821847 : DBA_TABLESPACE_USAGE_METRICS IS NOT INCLUDING UNDO TABLESPACE INFO

暂无图片 评论
暂无图片 有用 0
手机用户3302

zouxiang
感谢。
再请教下,我开始通过dba_segments查询undo表空间的sum(bytes/1024/1024)和dba_undo_extents的sum(bytes/1024/1024)大小是一致的;后来再查询这两个值发现通过dba_segments查询的值要比dba_undo_extents大了。这是什么原因?

暂无图片 评论
暂无图片 有用 0
zouxiang

How to monitor Undo Tablespace Usage and the Free Space (Doc ID 1951400.1)

The Undo Space once allocated wont be deallocated to the OS, by default. But the space can be reused by other transactions once the UNDO_RETENION (or TUNED_UNDORETENTION period) is met.

暂无图片 评论
暂无图片 有用 0
手机用户3302
问题已关闭: 问题已经得到解决
暂无图片 评论
暂无图片 有用 0
你好我是李白

dba_tablespace_usage_metrics,使用比率,并不是对于表空间真实大小,而是相对于small tablespace单个datafile最大32GB即4194302的比率,单位为blocks:
也就是dba_tablespace_usage_metrics的used_percent=(used_space/TABLESPACE_SIZE)*100,所以查询dba_undo_extents更为准确一点。

暂无图片 评论
暂无图片 有用 0
回答交流
提交
问题信息
请登录之后查看
邀请回答
暂无人订阅该标签,敬请期待~~
暂无图片墨值悬赏