Skip to main content

Posts

Drop Unmounted Diskgroup

<<Back to Oracle Main Page How to Drop Unmounted Diskgroup You can drop an unmounted diskgroup from ASM with force option. You will encounter error if you will not specify force and including keywords SQL>drop diskgroup TEST_DG force INCLUDING contents; SQL> drop diskgroup TEST_DG ; drop diskgroup TEST_DG * ERROR at line 1: ORA-15039: diskgroup not dropped ORA-15001: diskgroup "TEST_DG" does not exist or is not mounted SQL> select name ,state from v$asm_diskgroup; NAME            STATE --------------- ----------- TEST_DG         DISMOUNTED DG_TEST_DATA    MOUNTED DG_TEST_FRA     MOUNTED DG_TEST_REDO    MOUNTED DG_FORCE        MOUNTED SQL> drop diskgroup TEST_DG force INCLUDING contents; Diskgroup dropped.

mismatch on 'Physical Sector Size' with target disk group [512] [4096]

<<Back to Oracle ASM Main Page SQL> CREATE DISKGROUP TEST_DG NORMAL REDUNDANCY FAILGROUP FG1 DISK 'AFD:TEST06' FAILGROUP FG2 DISK 'AFD:TEST07' ATTRIBUTE 'compatible.asm' = '12.2', 'compatible.rdbms' = '12.2', 'sector_size'='4096', 'logical_sector_size'='4096'; CREATE DISKGROUP TEST_DG NORMAL REDUNDANCY * ERROR at line 1: ORA-15018: diskgroup cannot be created ORA-15038: disk 'AFD:TEST07' mismatch on 'Physical Sector Size' with target disk group [512] [4096] ORA-15038: disk 'AFD:TEST06' mismatch on 'Physical Sector Size' with target disk group [512] [4096] Let us check the Physical sector size of the disk $ asmcmd afd_lsdsk -------------------------------------------------------------------------------- Label                     Filtering   Path ================================================================================ TEST06    ...

How to Unplug and Plug a PDB Having TDE from One Container to Another

<<Back to DB Administration Main Page How to Unplug and Plug a PDB Having Encryption (TDE) from One Container to Another Setup Overview Source Container: CDB01 No of PDB's in Source Container 2 (PDB01 and PDB02) PDB01 using TDE PDB02  using TDE Target Container: CDB02 Note : Even if the PDB you are unplugging and re-plugging to another container, don't have any encrypted object but Wallet keys, are treated exactly same as PDB having encrypted objects. Task: In this post I will unplug the PDB02 from CDB01 and Plug it in CDB002 on the same host without copying the datafile (using NOCOPY Method). Precheck 1) Perform Full PDB backup of PDB02 database. 2) Create PDB description XML file for PDB(PDB02) SQL> exec dbms_pdb.describe (PDB_DESCR_FILE=>'/u01/app/oracle/PDB02.xml', PDB_NAME=>'PDB02'); 3) Verify the status of the PDB. SQL> select pdb_name, status from cdb_pdbs where pdb_name in ('PDB02'); 4)  Checking the Comp...

How to Create ASM Diskgroup

<<Back to Oracle ASM Main Page There are several ways to create the Diskgroup in ASM (eg Using OEM, ASMCA,ASMCMD,SQLPLUS). I will explain some of them in this post. Check available candidate (Free) Disk s We need free disks which we can use to create the diskgroup. Again there are several ways to check the same. I am checking it here using asmcmd $asmcmd lsdsk --candidate -p Creating Disk Groups Using SQL statement SQL> create diskgroup TEST_DG normal redundancy disk 'AFD:TEST06','AFD:TEST07'; Creating Disk Group Using ASMCA $asmca -silent -createDiskGroup -diskGroupName TEST_DG -diskList  'AFD:TEST06','AFD:TEST07' -redundancy normal Creating Disk Group Using ASMCMD Creating a DiskGroup using asmca requires to create the xml configuration file first. The xml configuration file is then used as input parameter to asmcmd mkdg to create the diskgroup. Configure XML Configuration File [oragrid@TEST05]$cat create_dg.xml <d...

Do We Need Flex ASM Enabled to Create ASM Diskgroup with Flex Redundancy

<<Back to Oracle ASM Main Page How to Create ASM Diskgroup with Flex Redundancy There is no change in the command. You just need to specify the redundancy type as FLEX. Also you don't need Flex ASM to be enabled to create an ASM Diskgroup with Flex or Extended redundancy Check if Flex ASM is Enabled $asmcmd showclustermode ASM cluster : Flex mode disabled So its not enabled. Lets create a DG with  Flex redundancy SQL> create diskgroup TEST_FLEX flex redundancy disk 'AFD:TEST05','AFD:TEST06','AFD:TEST07'; Diskgroup created.

Check Whether Oracle Flex ASM is enabled or not

<<Back to Oracle ASM Main Page How to Check if Oracle Flex ASM is Configured? Checking oracle Flex ASM is configured or not is super easy. Just oracle ASM environment and execute the below command $asmcmd showclustermode ASM cluster : Flex mode disabled

ORA-15260: permission denied on ASM disk group

<<Back to Oracle ASM Main Page How to Resolve ORA-15260 SQL> CREATE DISKGROUP DG_TEST EXTERNAL REDUNDANCY DISK 'AFD:TEST01'; CREATE DISKGROUP DG_TEST EXTERNAL REDUNDANCY DISK 'AFD:TEST01' * ERROR at line 1: ORA-15260: permission denied on ASM disk group Cause : Error message appears if you are performing the diskgroup (create diskgroup, alter diskgroup etc...) operation as sysdba Solution: Login to ASM as sysasm and re-execute the command