Friday, September 20, 2013

Strange...

I was checking Oracle 12c again, because of a beta exam end of october, and noticed something strange.

This time I decided to install 12c Grid software first to use the 12c ASM for the 12c database.

After installing ASM, I tried to check the disks available in ASM...


[oracle@localhost ~]$ . oraenv
ORACLE_SID = [oracle] ? +ASM
The Oracle base has been set to /opt/oracle
[oracle@localhost ~]$ sqlplus / as sysasm

SQL*Plus: Release 12.1.0.1.0 Production on Fri Sep 20 16:17:22 2013

Copyright (c) 1982, 2013, Oracle.  All rights reserved.

Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production
With the Automatic Storage Management option

SQL> select name  from v$asm_disk;

NAME
------------------------------
DBDATA_0000
GRIDDATA_0000


Nothing strange so far..
But before getting this result I made mistake in the query.. instead of v$asm_disk I try to query v$asm_disks. Let's see what happens...

SQL> select name from v$asm_disks;
select name from v$asm_disks
                 *
ERROR at line 1:
ORA-01219: database or pluggable database not open: queries allowed on fixed
tables or views only


A ORA-01219 is the result of this typo ? Strange, I was expecting the ORA-00942 ??

Let's check the Oracle 12c database..

[oracle@localhost ~]$ . oraenv
ORACLE_SID = [+ASM] ? orcl12c
The Oracle base remains unchanged with value /opt/oracle
[oracle@localhost ~]$ sqlplus / as sysdba

SQL*Plus: Release 12.1.0.1.0 Production on Fri Sep 20 16:23:04 2013

Copyright (c) 1982, 2013, Oracle.  All rights reserved.

Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production
With the Partitioning, Automatic Storage Management, OLAP, Advanced Analytics
and Real Application Testing options

SQL> select name from v$asm_disk;

NAME
------------------------------
DBDATA_0000
GRIDDATA_0000

SQL> select name from v$asm_disks;
select name from v$asm_disks
                 *
ERROR at line 1:
ORA-00942: table or view does not exist

This time the right error is shown.
Just to be sure, how does this look in the 11g version ??

[oracle@localhost ~]$ sqlplus / as sysasm

SQL*Plus: Release 11.2.0.1.0 Production on Fri Sep 20 16:25:18 2013

Copyright (c) 1982, 2009, Oracle.  All rights reserved.

Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
With the Real Application Clusters and Automatic Storage Management options

SQL> select name from v$asm_disks;
select name from v$asm_disks
                 *
ERROR at line 1:
ORA-01219: database not open: queries allowed on fixed tables/views only


Same error. So, it's not something in 12c. It looks like normal behaviour...

1 comment:

Keerthi Sri said...

Valuable information thanks for sharing Oracle DBA Online Training