0
点赞
收藏
分享

微信扫一扫

oracle数据库使用情况

萨摩斯加士奇 2022-03-14 阅读 104

select name,
total,
round(total - free, 2) used,
round(free, 2) free,
round((total - free) / total 100, 2) pctused
from (select 'SGA' name,
(select sum(value / 1024 / 1024) from v$sga) total,
(select sum(bytes / 1024 / 1024)
from v$sgastat
where name = 'free memory') free
from dual)
union
select name,
total,
round(used, 2) used,
round(total - used, 2) free,
round(used / total
100, 2) pctused
from (select 'PGA' name,
(select value / 1024 / 1024 total
from v$pgastat
where name = 'aggregate PGA target parameter') total,
(select value / 1024 / 1024 used
from v$pgastat
where name = 'total PGA allocated') used
from dual);

举报

相关推荐

0 条评论