Saturday, August 27, 2011

How to check the database size

select round ((a.data_size+b.temp_size+c.redo_size)/1024/1024/1024,2) "DB_size_in_GB"
from ( select sum(bytes) data_size
from dba_data_files ) a,
( select nvl(sum(bytes),0) temp_size
from dba_temp_files ) b,
( select sum(bytes) redo_size
from sys.v_$log ) c;

Error while running Autoconfig after Refresh Activity

 Got Error while running autoconfig at Refresh
==============================================
On MT Node

Autoconfig Lof file Error...
---------------------------------------------------------------
                   ADX Database Utility
---------------------------------------------------------------

getConnection() -->
    sDbHost    : abcgemmsd57
    sDbDomain  : contappssourcing.com
    sDbPort    : 10929
    sDbSid     : STAGE
    sDbUser    : APPS
    Trying to connect using SID...
getConnectionUsingSID() -->
    JDBC URL: jdbc:oracle:thin:@abcgemmsd57.contappssourcing.com:10929:STAGE
   Exception occurred: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
    Trying to connect using SID as ServiceName
getConnectionUsingServiceName() -->    JDBC URL: jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=abcgemmsd57.contappssourcing.com)(PORT=10929))(CONNECT_DATA=(SERVICE_NAME=STAGE)))
    Exception occurred: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
    Trying to connect using SID as ServiceName.DomainName
getConnectionUsingServiceName() -->    JDBC URL: jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=abcgemmsd57.contappssourcing.com)(PORT=10929))(CONNECT_DATA=(SERVICE_NAME=STAGE.contappssourcing.com)))
    Exception occurred: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
    Connection could not be obtained; returning null

-------------------ADX Database Utility Finished---------------
        Verifying connection to the Database   : Could not be stablished
        No Restore Profile file created.

Restore Profile utility ran successfully
===========================================================================

Solution
=========

Here abcgemmsd57 is DB Host.
As per the Error i found that on DB Host abcgemmsd57 ..Listener was down
Bring up the Listener on Host 57 and run autoconfig again on MT Node..it will works

Autoconfig Log File Location:
=====================
Log File --> $APPL_TOP/admin/sid/log/timestamp/adconfig.log