Monday, 21 June 2021

RMAN : ORA-19587: error occurred reading 1024 bytes at block number 1

 



RMAN - Crosscheck backup; commands fails with an error  ORA-19587: error occurred reading 1024 bytes at block number 1


RMAN> Run

 {

 Allocate channel c1 device type disk;

 Allocate channel c2 device type disk;

 Allocate channel c3 device type disk;

 Crosscheck backup;

 Crosscheck archivelog all;

 Delete noprompt expired backup;

 delete noprompt obsolete;

 Delete noprompt expired archivelog all;

 Backup as compressed backupset database format 'E:\Rman_Backup\backup\Full_Bkp_%d_on_%T_%s.bkp';

 sql 'alter system archive log current';

 Backup as compressed backupset archivelog all delete all input format 'E:\Rman_Backup\backup\Arch_%d_on_%T_%s.bkp';

 Delete noprompt backup completed before 'sysdate-2';

 backup current controlfile format'E:\Rman_Backup\backup\control_%d_on_%T_%s.ctl';

 backup spfile format 'E:\Rman_Backup\backup\spfile_%d_on_%T_%s.bkp';

 release channel c1;

 release channel c2;

 release channel c3;

 }


LOG :-

using target database control file instead of recovery catalog

allocated channel: c1

channel c1: SID=9 device type=DISK

allocated channel: c2

channel c2: SID=341 device type=DISK

allocated channel: c3

channel c3: SID=383 device type=DISK

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=E:\RMAN_BACKUP\BACKUP\ARCH_ORAPROD_ON_20210608_978.BKP RECID=940 STAMP=1074652241

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=E:\RMAN_BACKUP\BACKUP\ARCH_ORAPROD_ON_20210608_977.BKP RECID=941 STAMP=1074652240

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=E:\RMAN_BACKUP\BACKUP\ARCH_ORAPROD_ON_20210608_976.BKP RECID=942 STAMP=1074652239

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=E:\RMAN_BACKUP\BACKUP\CONTROL_ORAPROD_ON_20210608_980.CTL RECID=944 STAMP=1074653675

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=E:\RMAN_BACKUP\BACKUP\SPFILE_ORAPROD_ON_20210608_981.BKP RECID=945 STAMP=1074653677

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=E:\RMAN_BACKUP\BACKUP\FULL_BKP_ORAPROD_ON_20210609_984.BKP RECID=947 STAMP=1074736826

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=D:\APP\RECOVERY_AREA\ORAPROD\AUTOBACKUP\2021_06_08\O1_MF_S_1074653678_JCXDFYYC_.BKP RECID=946 STAMP=1074653678

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=E:\RMAN_BACKUP\BACKUP\FULL_BKP_ORAPROD_ON_20210609_983.BKP RECID=949 STAMP=1074736826

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=E:\RMAN_BACKUP\BACKUP\FULL_BKP_ORAPROD_ON_20210609_985.BKP RECID=948 STAMP=1074736826

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=E:\RMAN_BACKUP\BACKUP\ARCH_ORAPROD_ON_20210609_989.BKP RECID=951 STAMP=1074738622

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=D:\APP\RECOVERY_AREA\ORAPROD\AUTOBACKUP\2021_06_09\O1_MF_S_1074738612_JCZZD4PW_.BKP RECID=950 STAMP=1074738612

crosschecked backup piece: found to be 'AVAILABLE'

backup piece handle=E:\RMAN_BACKUP\BACKUP\ARCH_ORAPROD_ON_20210609_987.BKP RECID=952 STAMP=1074738620

released channel: c1

released channel: c2

released channel: c3

RMAN-00571: ===========================================================

RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

RMAN-00571: ===========================================================

RMAN-03009: failure of crosscheck command on c1 channel at 06/20/2021 02:00:10

ORA-19587: error occurred reading 1024 bytes at block number 1

ORA-27070: async read/write failed

OSD-04006: ReadFile() failure, unable to read from file

O/S-Error: (OS 38) Reached the end of the file.

ORA-27048: skgfifi: file header information is invalid

OSD-04004: invalid file header

Recovery Manager complete.



Solution :- 
To trace the exact issue we can enable debug for the RMAN session.

Enabling trace 

$ rman target / trace rman_deb.trc debug
RMAN> crosscheck backup;

The trace will list if there is any issues with existing backup pieces.

RMAN> crosscheck ARCHIVELOG ALL;

The trace will generate a log and list the archives where the issues lies. Mostly if the size of archives in ZERO, it results in above error.


 In my case I noticed that one of the back pieces for was of size 0 bytes, as of which the crosscheck command was not able to read the header of the backup piece. Removed the backup piece Manually and after that crosscheck command completed successfully.


thank you !







No comments:

Post a Comment