Lisa,
This alias does it for me...
dbsup='ps -ef | grep pmon; ls -al
/u01/oracle/product/v733/dbs/sgadef*'
Output looks like this
>$ dbsup
oracle 12340 1 0 May 06 - 2:41 ora_pmon_SDB3
oracle 13562 1 0 Apr 27 - 7:17 ora_pmon_SDB4
jsmith 147106 40824 0 12:56:44 pts/1 0:00 grep pmon
-rw-r----- 1 oracle dba 376 May 06 04:01
/u01/oracle/product/v733/dbs/sgadefSDB3.dbf
-rw-r----- 1 oracle dba 376 Apr 27 09:37
/u01/oracle/product/v733/dbs/sgadefSDB4.dbf
The above is a pretty good indication that the database(s) are up.
You could also grep for the other oracle processes (such as smon). It
won't tell you what state (resticted, unmounted, etc.) they are in,
though.
HTH
pgp
Paul Polentz
Technical Consultant
SCT Global Education Solutions
ppolentz_at_sctcorp.com
- ** **
'I've always been crazy but
it's kept me from goin' insane'
- Waylon Jennings
>Hello -
>
>Does anyone have a script that checks if a series of databases are up
and
>available that they would be willing to share? I set out to write a
ksh script
>to do this and found that I would have to write C to do what I needed
to do,
>since trying to connect to a hung or down instance will result in a
hung
>process. There wasn't an easy way to fire off the connect process,
sleep, and
>kill it if it hadn't come back yet. I really don't want to spend my
day writing
>C code, it will exacerbate the headache my job gave me today.
>
>Any suggestions / script snippets are appreciated
>Thanks
>Lisa
>
>
>
>--
>Author:
> INET: Lisa_Koivu_at_gelco.com
>
>Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
>San Diego, California -- Public Internet access / Mailing
Lists
>--------------------------------------------------------------------
>To REMOVE yourself from this mailing list, send an E-Mail message
>to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
>the message BODY, include a line containing: UNSUB ORACLE-L
>(or the name of mailing list you want to be removed from). You may
>also send the HELP command for other information (like subscribing).
Received on Thu May 11 2000 - 15:22:50 CDT