Bug 837731

Summary: Script Server not working for mongoDB
Product: [Other] RHQ Project Reporter: Charles Leow <chows86>
Component: PluginsAssignee: Nobody <nobody>
Status: NEW --- QA Contact:
Severity: medium Docs Contact:
Priority: unspecified    
Version: 4.4CC: hrupp, mazz
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Charles Leow 2012-07-05 02:59:06 UTC
Description of problem:
We’ve setup three nodes with RHEL5.3 and same hardware specifications. One node installed with RHQ server and remaining two each installed with mongoDB and RHQ agent to monitor mongoDB. 

I’ve discovered that RHQ 4.4 Script Server plugin is not working for mongoDB version 2.0.3. The initial availability scan indicates mongoDB is UP but thereafter it unable to detect the availability change (Goes Down and Goes UP). After the initial scan It is always showing UP. 


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


How reproducible:
Create a new script server to monitor mongoDB. After the initial availability scan it unable to detect the availability change thereafter. 

Steps to Reproduce:
1. Create a new script server
2. Executable value is /etc/init.d/mongod
3. Availability Execute Check set to YES
4. Availability Output Regex value is .*running.*
5. Availability Arguments value is status
  
Actual results:
Unable to detect availability change (Goes Up and Goes Down).

Expected results:
Should be able to update availability change very quickly.

Additional info:

Comment 1 Heiko W. Rupp 2012-07-18 19:02:56 UTC
Charles,

could you please append the output when runnign /etc/init.d/mongod 

- the server is running
- the server is not running

Could it be that the script needs a 'status' keyword appended as many services 
support?

I don't have a test instance handy to directly check it.

I also wonder if some more simple script that shows above behavior could be 
created so that we can add that as a test case to the plugin.

Comment 2 Heiko W. Rupp 2013-07-01 12:13:13 UTC
This may be related to Bug 848258

Comment 3 John Mazzitelli 2013-07-01 17:40:49 UTC
I think this is probably related to bug #848258 as heiko mentioned. That bug has been addressed, so this issue might be fixed already with that one.