Moneycontrol Brokerage Recos

Monday, September 26, 2016

Exadata Write-Back-Flash Cache



Great Article written by - Deiby Gómez on Exadata Write-Back-Flash Cache:


http://www.oracle.com/technetwork/articles/database/exadata-write-back-flash-2179184.html

Thursday, September 8, 2016

ORA-27054: NFS file system where the file is created or resides is not mounted with correct options



I was trying to catalog COLD backup of source database stored on an NFS mount point to RMAN on AIX 7.2 platform which failed with below errors.

ORA-19625: error identifying file /orabackup/PROD/ORADB/users01.dbf
ORA-27054: NFS file system where the file is created or resides is not mounted with correct options


From Alert Log:
--------------------

WARNING: NFS file system /orabackup mounted with incorrect options(bg,hard,intr,sec=sys,rw)
WARNING:Expected NFS mount options: rsize>=32768,wsize>=32768,hard,
Errors in file /oracle/diag/rdbms/prod/trace/PROD_ora_28573960.trc:
ORA-19625: error identifying file /orabackup/PROD/ORADB/users01.dbf
ORA-27054: NFS file system where the file is created or resides is not mounted with correct options
Additional information: 5
Additional information: 2
WARNING: NFS file system /orabackup mounted with incorrect options(bg,hard,intr,sec=sys,rw)
WARNING:Expected NFS mount options: rsize>=32768,wsize>=32768,hard,
Errors in file /oracle/diag/rdbms/prod/trace/PROD_ora_28573960.trc:
ORA-19625: error identifying file /orabackup/PROD/ORADB/users01.dbf.OLD
ORA-27054: NFS file system where the file is created or resides is not mounted with correct options
Additional information: 5
Additional information: 2


I checked the options used while mounting the mount point /orabackup


/orabackup:
        dev             = "/orabackup"
        vfs             = nfs
        nodename        = 192.168.90.11
        mount           = true
        type            = nfs
        options         = bg,hard,intr,sec=sys     --- not matching the expection thrown in error above
        account         = false



Above in the error message from alert log, Oracle RMAN expects NFS mount point options (rsize>=32768,wsize>=32768,hard) in order to proceed.





Workaround : I un-mounted the device and re-mounted that again with expected options as below.


$umount /orabackup

$mount -o rw,bg,hard,nointr,vers=3,timeo=300,rsize=32768,wsize=32768 92.168.90.11:/orabackup /orabackup


And again tried to catalog the COLD backup stored at that NFS mount point to RMAN.



RMAN> catalog start with '/orabackup/PROD/ORADB';

using target database control file instead of recovery catalog
searching for all files that match the pattern /orabackup/PROD/ORADB

List of Files Unknown to the Database
=====================================
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156187_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156188_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156189_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156190_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156191_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156192_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156193_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156194_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156195_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156196_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156197_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156198_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156199_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156200_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156201_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156202_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156203_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156204_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/old1_24972_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_1_921865254.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_2_921865254.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_3_921865254.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_4_921865254.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_5_921865254.dbf
.
.
.
.
.
.
.
File Name: /orabackup/PROD/ORADB/undotbs01.dbf
File Name: /orabackup/PROD/ORADB/users01.dbf
File Name: /orabackup/PROD/ORADB/users01.dbf.OLD

Do you really want to catalog the above files (enter YES or NO)? yes
cataloging files...
cataloging done

List of Cataloged Files
=======================
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156187_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156188_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156189_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156190_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156191_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156192_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156193_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156194_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156195_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156196_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156197_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156198_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156199_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156200_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156201_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156202_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156203_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_156204_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/old1_24972_674772839.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_1_921865254.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_2_921865254.dbf
File Name: /orabackup/PROD/ORADB/Archive_Logs/1_3_921865254.dbf
.
.
.
.
.


It worked fine.

ORA-19554: error allocating device, device type: SBT_TAPE, device name:


Received below error while restoring COLD backup of source database using RMAN at target server.



RMAN> run{
2> restore database;
3> }

Starting restore at 07-SEP-16
RMAN-06908: WARNING: operation will not run in parallel on the allocated channels
RMAN-06909: WARNING: parallelism require Enterprise Edition
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=391 device type=DISK
released channel: ORA_DISK_1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 09/07/2016 23:17:38
ORA-19554: error allocating device, device type: SBT_TAPE, device name:
ORA-27211: Failed to load Media Management Library
Additional information: 2



Cause : The reason of this failure is that on source database server has SBT_TAPE device type configured in RMAN( and we are using control file of source DB hence all SBT_TAPE decive configuration exists at target DB)  while on target server there was no Tape Drive attached to it.


RMAN> show all;

RMAN configuration parameters for database with db_unique_name ERPLN are:
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS;
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO 'SBT_TAPE';





Solution : On target server, just clear the device type from SBT_TAPE to default device type which is disk using below command or you can explicitly allocate channels of device type inside RUN{} RMAN block to override its permanent configuration. In this case, I have cleared SBT_TAPE device type setting to default.


RMAN> CONFIGURE DEFAULT DEVICE TYPE CLEAR;

old RMAN configuration parameters:
CONFIGURE DEFAULT DEVICE TYPE TO 'SBT_TAPE';
RMAN configuration parameters are successfully reset to default value



Now try restoring the database again.


RMAN> run{
2> restore database;
3> }

Starting restore at 07-SEP-16
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=391 device type=DISK

channel ORA_DISK_1: restoring datafile 00001
input datafile copy RECID=244 STAMP=921971779 file name=/orabackup/PROD/ORADB/system01.dbf
destination for restore of datafile 00001: /oracle/oradata/PROD/system01.dbf
channel ORA_DISK_1: copied datafile copy of datafile 00001
output file name=/oracle/oradata/PROD/system01.dbf RECID=0 STAMP=0
channel ORA_DISK_1: restoring datafile 00002
input datafile copy RECID=246 STAMP=921971780 file name=/orabackup/PROD/ORADB/undotbs01.dbf
destination for restore of datafile 00002: /oracle/oradata/PROD/undotbs01.dbf
channel ORA_DISK_1: copied datafile copy of datafile 00002
output file name=/oracle/oradata/PROD/undotbs01.dbf RECID=0 STAMP=0
channel ORA_DISK_1: restoring datafile 00003
input datafile copy RECID=243 STAMP=921971779 file name=/orabackup/PROD/ORADB/sysaux01.dbf
destination for restore of datafile 00003: /oracle/oradata/PROD/sysaux01.dbf
channel ORA_DISK_1: copied datafile copy of datafile 00003
output file name=/oracle/oradata/PROD/sysaux01.dbf RECID=0 STAMP=0
channel ORA_DISK_1: restoring datafile 00004
input datafile copy RECID=247 STAMP=921971780 file name=/orabackup/PROD/ORADB/users01.dbf
destination for restore of datafile 00004: /oracle/oradata/PROD/users01.dbf
channel ORA_DISK_1: copied datafile copy of datafile 00004
output file name=/oracle/oradata/PROD/users01.dbf RECID=0 STAMP=0
channel ORA_DISK_1: restoring datafile 00005
input datafile copy RECID=237 STAMP=921971779 file name=/orabackup/PROD/ORADB/erplntoolsdat01.dbf
destination for restore of datafile 00005: /oracle/oradata/PROD/erplntoolsdat01.dbf


Hope it would help someone ....!!