Oracle Controlli Automatici: differenze tra le versioni
Jump to navigation
Jump to search
Nessun oggetto della modifica |
|||
Riga 9: | Riga 9: | ||
select count(*) from v$log l inner join v$database d on (d.LOG_MODE='ARCHIVELOG') where l.ARCHIVED='NO' and l.status !='CURRENT'; |
select count(*) from v$log l inner join v$database d on (d.LOG_MODE='ARCHIVELOG') where l.ARCHIVED='NO' and l.status !='CURRENT'; |
||
with aa as (select count(*) as c from v$log l inner join v$database d on (d.LOG_MODE='ARCHIVELOG') where l.ARCHIVED='NO' and l.status !='CURRENT') |
|||
select aa.c/(select count(*) from v$log) as pct from aa; |
|||
=riempimento fra= |
=riempimento fra= |
Versione attuale delle 11:35, 20 apr 2023
backup rman
select sysdate - max(end_time) from v$rman_status where operation='BACKUP' and object_type in ('DB FULL','DB INCR') and status='COMPLETED';
log non archiviati
Controllo se ci sono log non archiviati, accade se la destinazione degli archive è piena o se ci sono altri problemi nell'archiviazione. Ritorna 0 se non ci sono log non archviati (OK), un numero maggiore di 0 se ci sono log da archiviare. Restituisce sempre 0 se il database non è in archivelog.
select count(*) from v$log l inner join v$database d on (d.LOG_MODE='ARCHIVELOG') where l.ARCHIVED='NO' and l.status !='CURRENT';
with aa as (select count(*) as c from v$log l inner join v$database d on (d.LOG_MODE='ARCHIVELOG') where l.ARCHIVED='NO' and l.status !='CURRENT') select aa.c/(select count(*) from v$log) as pct from aa;
riempimento fra
select sum(PERCENT_SPACE_USED) from v$flash_recovery_area_usage; select (SPACE_USED/SPACE_LIMIT)*100 from v$recovery_file_dest;