暂无图片
暂无图片
12
暂无图片
暂无图片
暂无图片

Oracle的session_cached_cursors 与 open_cursors参数

1、查看当前参数值及使用率,判断是否需要修改

select 'session_cached_cursors' parameter,

       lpad(value, 5) value,

       decode(value, 0, '  n/a', to_char(100 * used / value, '990') || '%') usage

  from (select max(s.value) used

          from v$statname n, v$sesstat s

         where n.name = 'session cursor cache count'

           and s.statistic# = n.statistic#),

       (select value from v$parameter where name = 'session_cached_cursors')

union all

select 'open_cursors',

       lpad(value, 5),

       to_char(100 * used / value, '990') || '%'

  from (select max(sum(s.value)) used

          from v$statname n, v$sesstat s

         where n.name in

               ('opened cursors current', 'session cursor cache count')

           and s.statistic# = n.statistic#

         group by s.sid),

       (select value from v$parameter where name = 'open_cursors');


2、修改参数的方法

alter system set session_cached_cursors = 100;

alter system set open_cursors = 500;

「喜欢这篇文章,您的关注和赞赏是给作者最好的鼓励」
关注作者
【版权声明】本文为墨天轮用户原创内容,转载时必须标注文章的来源(墨天轮),文章链接,文章作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

评论