Bug 134117

Summary: clvmd returns 0 on failure
Product: [Retired] Red Hat Cluster Suite Reporter: Derek Anderson <danderso>
Component: gfsAssignee: Christine Caulfield <ccaulfie>
Status: CLOSED CURRENTRELEASE QA Contact: GFS Bugs <gfs-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 4   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-09-30 14:52:11 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Derek Anderson 2004-09-29 17:54:10 UTC
Description of problem:  For init scripts and troubleshooting the
clmvd should return non-zero if it cannot be started.  In this case
the dlm module was not loaded.  The only way (I can see) to get more
info on this is by running it with the -d flag.

[root@link-10 root]# clvmd
[root@link-10 root]# echo $?
0
[root@link-10 root]# pidof clvmd

[root@link-10 root]# clvmd -d
  Unable to create lockspace for CLVM

  Can't initialise cluster interface

[root@link-10 root]# modprobe dlm
[root@link-10 root]# clvmd
[root@link-10 root]# echo $?
0
[root@link-10 root]# pidof clvmd
5000
[root@link-10 root]#


Version-Release number of selected component (if applicable):
[root@link-10 root]# clvmd -V

Cluster LVM Daemon version 0.2.1

How reproducible:


Steps to Reproduce:
1. Quorate cman cluster
2. Do not have the dlm module loaded
3. Start clvmd
  
Actual results:
clvmd did not start.  returned 0.

Expected results:
Return non-zero on failure.

Additional info:

Comment 1 Christine Caulfield 2004-09-30 14:22:25 UTC
This was because clvmd forked before trying to open the cluster
manager socket. So what it was saying was "success...I've forked",
then it failed whilst a daemon.

I've moved the fork to later on in the startup sequence now so it can
return error codes for the most basic problems. For others you'll just
have to watch syslog :)

Comment 2 Derek Anderson 2004-09-30 14:52:11 UTC
Verified:

[root@link-12 root]# clvmd
  Unable to create lockspace for CLVM

  Can't initialise cluster interface

[root@link-12 root]# echo $?
5
[root@link-12 root]#

Comment 3 Kiersten (Kerri) Anderson 2004-11-16 19:05:15 UTC
Updating version to the right level in the defects.  Sorry for the storm.