ON CALL DBA SUPPORT

— Database blog

ARCHIVE LOGS COUNT

Posted by ssgottik on 06/01/2011

ARCHIVE LOG COUNT CHECK—-AVERAGE OF 1 MONTH

select ‘+ Daily (max) : ‘||max(no)||’ switches. Size: ‘||round((max(no) * max(logsize ))/1024,2)||’Gb’||chr(10)||’+ Daily (avg) : ‘||trunc(avg(no))||’ switches. Size: ‘||round((avg(no) * max(logsize ))/1024,2)||’Gb’||chr(10)|| ‘+ Daily (min) : ‘||min(no)||’ switches. Size: ‘||round((min(no) * maxlogsize ))/1024,2)||’Gb’
from (
select trunc(FIRST_TIME,’DD’), count(*)  no
from v$log_history
where FIRST_TIME > sysdate – 30
group by trunc(FIRST_TIME,’DD’)),
(select max(bytes/1024/1024) logsize from v$log);

Advertisements

One Response to “ARCHIVE LOGS COUNT”

  1. Rajesh said

    Hi,

    This is very useful and informative. Keep up the good work.

    Rajesh

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: