Operating System - HP-UX
1828582 Members
2048 Online
109982 Solutions
New Discussion

checking databases are running

 
Ravinder Singh Gill
Regular Advisor

checking databases are running

is a disk array is rebooted....and you want to check that all the databases on the server are working fine once the disk array is up...

is it simply a matter of doing:

ps -ef | grep pmon

& checking that the databases are there?
4 REPLIES 4
RAC_1
Honored Contributor

Re: checking databases are running

ps -ef will suffice in this case. A better way would be checking with exact program names to avoid grep errors.


ps -ef | grep pmon will grep for

pmon_xxx
pmon_yyy, so you can do it as follows.

UNIX95= ps -C"pmon"

Anil
There is no substitute to HARDWORK
Geoff Wild
Honored Contributor

Re: checking databases are running

tnsping would do it for you...

Should be in the /app/oracle/product//bin/ dir...

Example:

/app/oracle/product/9.2.0/bin/tnsping mydb

TNS Ping Utility for HPUX: Version 9.2.0.4.0 - Production on 13-JUL-2005 07:28:03

Copyright (c) 1997 Oracle Corporation. All rights reserved.

Used parameter files:
/app/oracle/admin/network/sqlnet.ora

Used ONAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=prdbf)(PORT=1527))(CONNECT_DATA=(SID=prd)(SERVER=DEDICATED)))
OK (10 msec)


Rgds...Geoff
Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
Yogeeraj_1
Honored Contributor

Re: checking databases are running

hi,

you should check the following:
1. the listener is still up
e.g. lsnrctl status
2. can connect to the database
e.g. sqlplus scott/tiger

with the appropriate script, you can be dead sure that your database is up and accessible.

if you need further help, let us know

kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Rick Garland
Honored Contributor

Re: checking databases are running

Check for the pmon processes
Make sure the listener is up
Connect to the database and do a simple SELECT statement.

e.g SQL> select * from dba_users;

If you get a return from this SELECT you are talking to the database.

This is for Oracle.


If all comes back OK, you have a running database