› Fóruns › Banco de dados Oracle › RMAN – Recover para Standby › RMAN – Recover para Standby
Opa!!!…
Tenho sim carinha..segue ai pra ti :
esse é o Nivel 01:
run {
allocate channel t1 type disk format '/u02/backup/bkp_hotbackup_n1_%d_%t_%s.rman';
allocate channel t2 type disk format '/u02/backup/bkp_hotbackup_n1_%d_%t_%s.rman';
allocate channel t3 type disk format '/u02/backup/bkp_hotbackup_n1_%d_%t_%s.rman';
allocate channel t4 type disk format '/u02/backup/bkp_hotbackup_n1_%d_%t_%s.rman';
allocate channel t5 type disk format '/u02/backup/bkp_hotbackup_n1_%d_%t_%s.rman';
backup as compressed backupset incremental level 1 database tag 'bkp_hotback_n1'
current controlfile tag 'bkp_CF'
spfile tag 'bkp_SPFILE';
sql 'alter system archive log current';
backup archivelog all delete all input tag 'bkp_archives';
release channel t1;
release channel t2;
release channel t3;
release channel t4;
release channel t5;
}
Nivel 02:
run {
allocate channel t1 type disk format '/u02/backup/bkp_hotbackup_n2_%d_%t_%s.rman';
allocate channel t2 type disk format '/u02/backup/bkp_hotbackup_n2_%d_%t_%s.rman';
allocate channel t3 type disk format '/u02/backup/bkp_hotbackup_n2_%d_%t_%s.rman';
allocate channel t4 type disk format '/u02/backup/bkp_hotbackup_n2_%d_%t_%s.rman';
allocate channel t5 type disk format '/u02/backup/bkp_hotbackup_n2_%d_%t_%s.rman';
backup as compressed backupset incremental level 2 database tag 'bkp_hotback_n2'
current controlfile tag 'bkp_CF'
spfile tag 'bkp_SPFILE';
sql 'alter system archive log current';
backup archivelog all delete all input tag 'bkp_archives';
release channel t1;
release channel t2;
release channel t3;
release channel t4;
release channel t5;
}
OBS.: è muito importante que você entenda que são modelos, você deve adequar sua estratégia de Backup a necessidade do seu negócio, divindo em quantas janelas achar necessário e da maneira que achar mais proveitosa e conveniente para seu ambiente.
Abração e boa sorte.