Databases
cancel
Showing results for 
Search instead for 
Did you mean: 

Oracle DB fails to shutdown.

John Flanagan
Regular Advisor

Oracle DB fails to shutdown.

DB version 8.1.7 32 bit
OS HP-UX 11i

The database is shutdown every night for backup. On 2 out of the last 4 nights I get the following error

SHUTDOWN: waiting for logins to complete.

To get the database to shutdown I have to use shutdown abort. When I try to start up the db I get an end of file on communication channel error.

On the other 2 nights there was no problem and the database allways stops and starts without a problem when I do it manually.

How can I check what process or application is trying to connect to the database? and why to I get the end of file on communication channel error on startup?

Regards,

John.
22 REPLIES
Eric Antunes
Honored Contributor

Re: Oracle DB fails to shutdown.

Hi John,

You must use the instruction "immediate" with the shutdown command:

SQL>shutdown immediate;

Regards,

Eric Antunes
Each and every day is a good day to learn.
Sivakumar TS
Honored Contributor

Re: Oracle DB fails to shutdown.

Hi John,

Check if any running oracle process are available,

#ps -ef | grep oracle

and try
shutdown immediate once

and try to startup and shutdown normallly.

WIth Regards,

Siva.
Nothing is Impossible !
John Flanagan
Regular Advisor

Re: Oracle DB fails to shutdown.

All shutdowns are done with shutdown immediate. I should have stated that in the question.

Sanjay Kumar Suri
Honored Contributor

Re: Oracle DB fails to shutdown.

Check these links:

http://www.praetoriate.com/oracle_tips_process_detail.htm

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=997654

sks
A rigid mind is very sure, but often wrong. A flexible mind is generally unsure, but often right.
Eric Antunes
Honored Contributor

Re: Oracle DB fails to shutdown.

Hi John,

Can you attach the last trace files of those 2 nights (usually in $ORACLE_HOME/admin//bdump)?

Regards,

Eric Antunes
Each and every day is a good day to learn.
Eric Antunes
Honored Contributor

Re: Oracle DB fails to shutdown.

One more question:

Is there a database link?
Each and every day is a good day to learn.
John Flanagan
Regular Advisor

Re: Oracle DB fails to shutdown.

There are no DB links.

I should have said that the backup uses the oracle provided script

/usr/bin/su oracle -c /home/oracle/8.1.7/bin/dbshut

I have just noticed that the backup logfile shows an end of file on communication channel error.

SVRMGR> Connected.
SVRMGR> ORA-03113: end-of-file on communication channel
SVRMGR>
Server Manager complete.
Database "paulive" shut down.


The errors from the udump file

*** SESSION ID:(46.1349) 2006-02-01 23:35:16.420
SHUTDOWN: waiting for logins to complete.
*** 2006-02-01 23:40:27.510
SHUTDOWN: waiting for logins to complete.
*** 2006-02-01 23:45:38.570
SHUTDOWN: waiting for logins to complete.
*** 2006-02-01 23:50:49.650
...........
.........

I am going to check the HP-UX patchs.
John Flanagan
Regular Advisor

Re: Oracle DB fails to shutdown.

All documentation I found relates to HP-UX 11.00 and not to 11.11.

Is there documentation relating to patch requirements on 11.11 for Oracle 8.1.7.

Yogeeraj_1
Honored Contributor

Re: Oracle DB fails to shutdown.

hi John,

Cold backups always presents these types of problems. cold backup typically implies unattended shutdown/startup.

A hot backup removes that worry. True, you could use a shutdown abort, startup/shutdown cycle to remove many of the issues with unattended shutdowns but not all (database won't restart without someone kicking something for example)...

I think a hot backup, especially with rman (don't even have to put it into backup mode) is easier than a cold for this reason.

I cannot see any disadvantages of doing so.

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

Re: Oracle DB fails to shutdown.

John,

All you have to do is

1. Ensure that users of off the system

2. Listner is shutdown

3. Then shutdown the database.

if 1 & 2 fails or takes time you may get into problems.

To avoid better add the command: sleep 30 or 60 before shutting down the database.

Also can you ensure that switchlogs are done twice or 3 times before shutting down, so your db is 100% for shutdown or abort.

Chan
Eric Antunes
Honored Contributor

Re: Oracle DB fails to shutdown.

Hi again John,

Since you are using "/usr/bin/su oracle -c /home/oracle/8.1.7/bin/dbshut", how are you sure it is a immediate shutdown? Are you able to exec the following as root:

#/usr/bin/su oracle -c /home/oracle/8.1.7/bin/dbshut immediate

Or is the immediate the only mode that the dbshut script shuts down the db?

Best Regards,

Eric Antunes

Each and every day is a good day to learn.
John Flanagan
Regular Advisor

Re: Oracle DB fails to shutdown.

The Answer is yes to all of the above.

Yogeeraj,
I have been checking your advice on the user of rman. From my reading of the docs it does not appear go give a consistent backup of an open database. Is there an option to force it to be consistent(similar to that with the exp command).

John.
Chan 007
Honored Contributor

Re: Oracle DB fails to shutdown.

John,

As per oracle, it is not recommended to go for hotbackup.

Only Cold backups works well with 8.x

Where if you have 9 and above you can go for hotbackup.

We have plenty of inst with both combinations.

As put in my prev ans to you we use sleep while shutting the DB.

It works well.

It is upto you to decide which backup you go for.

Chan
Bill Thorsteinson
Honored Contributor

Re: Oracle DB fails to shutdown.

Hot backups are not consistent. However,
you can recover to a point in time.

My backup script writes the commaand to
recover to a point in time (now) to the
backup directory. It then waits a few seconds
and forces a log rotation.

To recover I restore the files and run
the recovery script as part of the recovery.
This requires that the uncompressed archived
redo logs covering the period of the backup
be in the redo directory.

I have automated script to roll-back our
testing databases using this techniqure.

We also clone databases by restoring thme
to a new directory structure, recreating
the control files, and renaming the
database.
Simon Wickham_6
Regular Advisor

Re: Oracle DB fails to shutdown.

Hi John,

check your alert log as well as the bdump directory. Then You will either have to shutdown abort, or have a program kill all oracle connections and then to a shutdown immediate.

1. look at recent alert log entries.
2. Once backup shutdown immediate and look at logs.

Regards,
Simon
John Flanagan
Regular Advisor

Re: Oracle DB fails to shutdown.

I have modified the standard dbshut script to use sqlplus /nolog and not svrmgrl. It worked OK last night. If it fails aganin I will stop the listener and add the wait statement.

I am also looking at using rman.

Thanks everybody,

Yogeeraj_1
Honored Contributor

Re: Oracle DB fails to shutdown.

hi John,

I still believe RMAN is a much better option.

Good that you have started looking into it.

Read more at: http://download-west.oracle.com/docs/cd/B10501_01/server.920/a96566/rcmrecov.htm#1008603


kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Steven E. Protter
Exalted Contributor

Re: Oracle DB fails to shutdown.

Shalom John,

The dbshut that ships with oracle is flawed. We always modify the shutdown to shutdown immediate and have avoided the issues you seem to encounter.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
John Flanagan
Regular Advisor

Re: Oracle DB fails to shutdown.

Thanks for your help everybody. I think we have this one licked.

I am interested in rman. I did a trial backup to disk and it completed in just 8 minutes. I am still unsure about the recovery options but I will read further into the documentation.

Regards,

John.
Duncan Edmonstone
Honored Contributor

Re: Oracle DB fails to shutdown.

John,

If you're interested, I hates the standard dbstart/dbshut scripts so much, I ended up writing my own version which do a sight more...

http://duncane.squarespace.com/scripts/oracle_cntl_1_12.sh

Anyway, if you want them no problem, although I'd appreciate if you would feed back to many any issues/bugs etc.

HTH

Duncan

HTH

Duncan
John Flanagan
Regular Advisor

Re: Oracle DB fails to shutdown.

It looks like a lot of work went into that script. I think I have everything working correctly now. If I use it I will provide feed back.

Thanks,

John.
Eric Antunes
Honored Contributor

Re: Oracle DB fails to shutdown.

I suspected about that dbshut script since mine (8.0.5) is doing a normal shutdown...
Each and every day is a good day to learn.