Wednesday, April 29, 2015

How to find out mapped oracle ASM disk.

First you need enter into root.

sudo su -

Then change directory into cd /etc/init.d

[root@test200 init.d]# ./oracleasm listdisks
DATA01
FRA01
OCRVOTE01

If you want find which ASM disk is mapped which device, then you must use oracleasm querydisk with ASM disk name.


[root@test200 init.d]# oracleasm querydisk -d DATA01
Disk "DATA01" is a valid ASM disk on device [8,15]

As see you, DATA01 is valid ASM disk on device [8,15].

What is means?
It means DATA01 is mapped to device [8,15].

How to find [8,15] device?
We must use Linux ls –l  command as below.

[root@test200 init.d]# ls -l /dev/* | grep 8, | grep 15
brw-rw---- 1 root disk      8,  15 Jan  12 13:22 /dev/sdf

Now, we can say DATA01 is mapped to /dev/sdf

Tuesday, April 21, 2015

ORA-17628, ORA-19505 during RMAN DUPLICATE FROM ACTIVE

The following error is reported trying to create a Physical Standby database or clone  your database different location    using "duplicate from active database" :


input datafile file number=00032 name=+test/datafile/test01.425.877491083
RMAN-03009: failure of backup command on ch01 channel at 04/20/2015 20:39:29
ORA-17628: Oracle error 19505 returned by remote Oracle server
continuing other job steps, job failed will not be re-run
channel ch01: starting datafile copy
input datafile file number=00035 name=+test/datafile/test02.386.877491081
RMAN-03009: failure of backup command on ch02 channel at 04/20/2015 20:39:30
ORA-17628: Oracle error 19505 returned by remote Oracle server
continuing other job steps, job failed will not be re-run
channel ch02: starting datafile copy
input datafile file number=00115 name=+test/datafile/test03.260.877491083
RMAN-03009: failure of backup command on ch01 channel at 04/20/2015 20:39:30
ORA-17628: Oracle error 19505 returned by remote Oracle server

One datafile  is not using OMF name while the rest of the datafiles are using OMF name.

It is not oracle bug and this expected behavior.

The reason the duplicate of the database is failing is because there is no db_file_name_convert and the datafile that has an alias is not using an OMF name, so a new OMF name is not created for it and the filename is unchanged.

The parameter "parameter_value_convert"  changes the string  from 'xxx' to 'yyy' in other  initialization parameters, but not in the datafile names.  If the names of the datafiles are desired to be changed,  then  db_file_name_convert should be used


Solution:

1. Use the parameter DB_FILE_NAME_CONVERT and specify the complete location of the datafile using alias :

SET DB_FILE_NAME_CONVERT='+DATA/xxx/datafile','+DATA/yyy/datafile/'


or

2. Create the directory "xxx" in the diskgroup where the image copy is being created by the auxiliary database.