Databases
cancel
Showing results for 
Search instead for 
Did you mean: 

database uptime and downtime report

Nirmalkumar
Frequent Advisor

database uptime and downtime report

Hello all,

can some one provide me the script to get oracle database uptime and downtime report.

Thanks in advance.


Thanks,
Nirmal
1 REPLY
avizen9
Esteemed Contributor

Re: database uptime and downtime report

Hello Nirmal,
below is sample script to check uptime.

SELECT SYSDATE - logon_time "DB Uptime in Days",
(SYSDATE - logon_time) * 24 "DB Uptime in Hours"
FROM v$session
WHERE program LIKE '%PMON%'

here one line where you can modify as per your requirement
http://www.windows-tech.info/15/2528abe2344ff12d.php