RMAN: Teste de MML com sbttest
Outra forma de teste de uma API da MML (Media Management Library) do RMAN é o programa (instalado junto com o Oracle Database) sbttest.
Em sua forma de utilização mínima, deve ser especificado um nome de arquivo para o teste (abaixo eu coloquei como Teste), e em seguida qual a livraria que deve ser utilizada (no meu caso, a livraria de teste do próprio Oracle Database).
O programa também possui várias opções extras, como quantidade de blocos lidos e gravados, e tamanho destes blocos, para que você seja mais específico em seu teste.
C:\Users\Portilho>sbttest Teste -libname oracle.disksbt -block_count 1000 -block
_size 32768
The sbt function pointers are loaded from oracle.disksbt library.
-- sbtinit succeeded
-- sbtinit (2nd time) succeeded
sbtinit: vendor description string=WARNING: Oracle Test Disk API
sbtinit: Media manager is version 8.1.3.0
sbtinit: Media manager supports SBT API version 2.0
sbtinit: allocated sbt context area of 5528 bytes
sbtinit: proxy copy is supported
-- sbtinit2 succeeded
-- regular_backup_restore starts ................................
-- sbtbackup succeeded
write 1000 blocks
-- sbtwrite2 succeeded
-- sbtclose2 succeeded
sbtinfo2: SBTBFINFO_NAME=Teste
sbtinfo2: SBTBFINFO_METHOD=stream
sbtinfo2: SBTBFINFO_CRETIME=Wed Jul 31 10:39:52 2013
sbtinfo2: SBTBFINFO_LABEL=\rman
sbtinfo2: SBTBFINFO_LABEL=Teste
sbtinfo2: SBTBFINFO_SHARE=multiple users
sbtinfo2: SBTBFINFO_ORDER=random access
sbtinfo2: SBTBFINFO_COMMENT=Oracle disk API
-- sbtinfo2 succeeded
-- sbtrestore succeeded
file was created by this program:
seed=18109106, blk_size=32768, blk_count=1000
read 1000 buffers
-- sbtread2 succeeded
-- sbtclose2 succeeded
-- sbtremove2 succeeded
-- regular_backup_restore ends ................................
-- sbtcommand succeeded
create_osf_files: pctest01.osf succeeded
create_osf_files: pctest02.osf succeeded
create_osf_files: pctest03.osf succeeded
-- proxy_backup starts ................................
-- sbtpcquerybackup succeeded
sbtpcbackup:pctest01.osf (handle=-1) will be backed up to pctest01.bkf
sbtpcbackup:pctest02.osf (handle=-2) will be backed up to pctest02.bkf
sbtpcbackup:pctest03.osf (handle=-3) will be backed up to pctest03.bkf
-- sbtpcbackup succeeded
-- sbtpcvalidate succeeded
sbtpcstatus:handle=-1, status=SBTPCSTATUS_READY
sbtpcstatus:handle=-1, status=SBTPCSTATUS_END
sbtpcstatus:handle=-1, status=SBTPCSTATUS_DONE
sbtpcstatus:handle=-2, status=SBTPCSTATUS_READY
sbtpcstatus:handle=-2, status=SBTPCSTATUS_END
sbtpcstatus:handle=-2, status=SBTPCSTATUS_DONE
sbtpcstatus:handle=-3, status=SBTPCSTATUS_READY
sbtpcstatus:handle=-3, status=SBTPCSTATUS_END
sbtpcstatus:handle=-3, status=SBTPCSTATUS_DONE
-- sbtpcstatus succeeded
-- sbtpcend succeeded
-- proxy_backup ends ................................
-- proxy_restore starts ................................
-- sbtpcqueryrestore succeeded
sbtpcrestore: pctest01.bkf (handle=-1) will be restored to pctest01.rtf
sbtpcrestore: pctest02.bkf (handle=-2) will be restored to pctest02.rtf
sbtpcrestore: pctest03.bkf (handle=-3) will be restored to pctest03.rtf
-- sbtpcrestore succeeded
-- sbtpcvalidate succeeded
sbtpcstatus:handle=-1, status=SBTPCSTATUS_READY
sbtpcstatus:handle=-1, status=SBTPCSTATUS_END
sbtpcstatus:handle=-2, status=SBTPCSTATUS_READY
sbtpcstatus:handle=-2, status=SBTPCSTATUS_END
sbtpcstatus:handle=-3, status=SBTPCSTATUS_READY
sbtpcstatus:handle=-3, status=SBTPCSTATUS_END
-- sbtpcstatus succeeded
sbtremove2: pctest01.bkf was removed successfully
sbtremove2: pctest02.bkf was removed successfully
sbtremove2: pctest03.bkf was removed successfully
-- sbtpcend succeeded
krs_verify_rtf: pctest01.rtf verification succeeded
krs_verify_rtf: pctest02.rtf verification succeeded
krs_verify_rtf: pctest03.rtf verification succeeded
-- proxy_restore ends ................................
-- sbtend succeeded
*** The SBT API test was successful ***
C:\Users\Portilho>