Bug 493296 - When embedded Oracle server does not run, service oracle stop still says OK
Summary: When embedded Oracle server does not run, service oracle stop still says OK
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Server
Version: 530
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Tomas Lestach
QA Contact: Michael Mráka
URL:
Whiteboard:
Depends On:
Blocks: 456985
TreeView+ depends on / blocked
 
Reported: 2009-04-01 10:20 UTC by Jan Pazdziora
Modified: 2009-09-10 20:35 UTC (History)
2 users (show)

Fixed In Version: sat530
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-09-10 20:35:03 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Jan Pazdziora 2009-04-01 10:20:33 UTC
Description of problem:

When embedded Oracle server does not run, maybe because it was just stopped using

   service oracle stop

the (following)

   service oracle stop

command prints [ OK ].

Version-Release number of selected component (if applicable):

Satellite-5.3.0-RHEL5-re20090327.0 on i386
# rpm -qf /etc/init.d/oracle 
oracle-server-i386-10.2.0.4-40.el5sat

How reproducible:

Deterministic.

Steps to Reproduce:
1. Run # service oracle stop.
2. Verify that no oracle process is running, using # ps -U oracle.
3. Run # service oracle stop again.
  
Actual results:

# service oracle stop
Shutdown Oracle: Processing Database instance "rhnsat": log file /opt/apps/oracle/web/product/10.2.0/db_1/log/shutdown.log
                                                           [  OK  ]
# ps -U oracle
  PID TTY          TIME CMD
# service oracle stop
Shutdown Oracle: Processing Database instance "rhnsat": log file /opt/apps/oracle/web/product/10.2.0/db_1/log/shutdown.log
                                                           [  OK  ]

Expected results:

# service oracle stop
Shutdown Oracle: Processing Database instance "rhnsat": log file /opt/apps/oracle/web/product/10.2.0/db_1/log/shutdown.log
                                                           [  OK  ]
# ps -U oracle
  PID TTY          TIME CMD
# service oracle stop
Shutdown Oracle: Processing Database instance "rhnsat": log file /opt/apps/oracle/web/product/10.2.0/db_1/log/shutdown.log
                                                           [FAILED]

Of course, if the Oracle server did not run before the first service oracle stop command, the first output should be FAILED as well.

Additional info:

My expectation of service printing FAILED stems from httpd behaving that way:

# service httpd stop
Stopping httpd:                                            [  OK  ]
# ps -U apache
  PID TTY          TIME CMD
# service httpd stop
Stopping httpd:                                            [FAILED]

Comment 1 Tomas Lestach 2009-04-10 10:26:05 UTC
/etc/init.d/oracle calls oracle script dbstop (and dbstart), that doesn't report any return value that could be used to determine whether the stop (or start) action was successful or not. To prevent modifying scripts distributed by Oracle (and after consultation with colleges), we decided to re-write /etc/init/d/oracle completely to start and stop oracle services directly without making any use out of the original dbstop (and dbstart). I tried to keep the main behaviour features of the original scripts.

/etc/init.d/oracle re-writen

tagged as:
oracle-server-i386-10.2.0.4-43
oracle-server-x86_64-10.2.0.4-43
oracle-server-s390x-10.2.0.4-43

Comment 2 Tomas Lestach 2009-04-10 11:45:39 UTC
commits in thirdparty.git:
oracle-server.spec:               8202e14f0831d565e9103cc533d6ad9d690c6b46
oracle-server-i386-10.2.0.4-43:   084a432112df17c20f9ae4dab8e453056a7d9bab
oracle-server-x86_64-10.2.0.4-43: d1ebffd6745f5d9b21af8b4e18f8675d87f3b94c
oracle-server-s390x-10.2.0.4-43:  66178377083c917f916365d00047297baa399b80

Comment 3 Tomas Lestach 2009-05-05 14:14:33 UTC
Available in composes since Satellite-5.3.0-RHELx-re20090409.1

Comment 4 Michael Mráka 2009-05-07 12:21:00 UTC
Verified. Satellite-5.3.0-RHEL5-re20090501.1-i386

Comment 5 Miroslav Suchý 2009-08-24 15:29:11 UTC
[root@xen5 ~]# service oracle stop
Shutting down Oracle Net Listener ...                      [  OK  ]
Shutting down Oracle DB instance "rhnsat" ...              [  OK  ]
[root@xen5 ~]# service oracle stop
Shutting down Oracle Net Listener ...                      [FAILED]
Shutting down Oracle DB instance "rhnsat" ...              [FAILED]


verified in stage on xen5

Comment 6 Brandon Perkins 2009-09-10 20:35:03 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHEA-2009-1434.html


Note You need to log in before you can comment on or make changes to this bug.