Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: How to check the database is available

Re: How to check the database is available

From: Ralph Ganszky <ralph.ganszky_at_sap.com>
Date: Sun, 15 Aug 1999 15:36:17 +0200
Message-ID: <37B6C251.B9D57C8C@sap.com>


Hi,

You can read the alert log file and look for the last startup message. If there are a alter database open complete, and You have found the pmon process in the process list, the database must be up and open. If You know that the instance is running You also can make a connect with phantasy user and password. You'll get an error ORA-01033 if the Database is not open even the user does not exist, because the database cannot verify an user in mount state.

Sybrand Bakker is wrong with his check for the sgadef file because it disapears in Release 8.1.

kinwho_at_my-deja.com wrote:

> Hi,
>
> I need to write an UNIX script to detect whether the instance is up and
> the databse is online. The script is run on the same machine of the
> instance, but my database user login does not have sa role. I could
> grep on the Oracle process to detect the instance is up. But, I don't
> know how to detect the database is online. Any suggestion or idea?
>
> Thanks,
> Kin Ho
>
> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.

--
Best Regards,

Ralph Ganszky

Received on Sun Aug 15 1999 - 08:36:17 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US