Bug 1099334

Summary: [Nagios] - When smb is killed /stopped, nagios UI does not reflect the staus as critical.
Product: [Red Hat Storage] Red Hat Gluster Storage Reporter: RamaKasturi <knarra>
Component: nagios-server-addonsAssignee: Ramesh N <rnachimu>
Status: CLOSED ERRATA QA Contact: RamaKasturi <knarra>
Severity: medium Docs Contact:
Priority: medium    
Version: rhgs-3.0CC: dpati, kmayilsa, rhsc-qe-bugs, rnachimu, tjeyasin
Target Milestone: ---   
Target Release: RHGS 3.0.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: nagios-server-addons-0.1.1-2.el6rhs, gluster-nagios-addons-0.1.1-1.el6rhs Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-09-22 19:09:57 UTC 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:
Bug Depends On: 1104574, 1105123    
Bug Blocks:    

Description RamaKasturi 2014-05-20 05:36:48 UTC
Description of problem:
When smb service is killed or stopped, nagios ui shows the status as "OK" with status information "OK:No gluster volume uses smb".

Version-Release number of selected component (if applicable):
nagios-server-addons-0.1.0-75.git2efd1bf.el6rhs.x86_64
gluster-nagios-addons-0.1.0-66.gitaa44342.el6rhs.x86_64

How reproducible:
Always

Steps to Reproduce:
1. Install nagios on RHS nodes.
2. start smb on the node by running "service smb start" 
3. Now kill the smb process by running the command "service smb stop" or ps aux | grep smb, kill -9 <PID>

Actual results:
When smb is killed, smb status is shown as "OK" and status information as "OK:NO gluster volume uses smb".

Expected results:
When smb is killed, status should be shown as "CRITICAL" and status information as "CRITICAL: smb process is not running".

Additional info:

Comment 1 Timothy Asir 2014-05-21 12:09:03 UTC
is there any volume using smb in that node? If there is no volume or no volume using SMB, it will simply says OK.

Comment 2 Ramesh N 2014-05-22 13:08:03 UTC
Fixed in patch http://review.gluster.org/7847

Comment 3 Ramesh N 2014-05-22 13:15:18 UTC
By default, SMB is enabled for all volumes. So even if there is no "user.cifs" or "user.smb" volume option is specified in the volume, we have consider this as SMB enabled. Also if either of the("user.cifs" , "user.smb") values is disabled, it means SMB is disabled. 

 With this fix and above assumption, whenever SMB is enabled for any volume in the cluster and SMB service is not running, corresponding service in Nagios UI will go to CRITICAL. Whenever SMB process is not running and SMB is not enabled for any of the volume, corresponding service in Nagios UI will be in OK state with message as "OK: No gluster volume uses smb".

Comment 4 RamaKasturi 2014-06-04 10:20:43 UTC
Moving this bug back to assigned bcoz when user.smb is set to disabled, smb process start even if it is not started before.

Filed a bug for the same. Here is the bug.

https://bugzilla.redhat.com/show_bug.cgi?id=1104574

Comment 5 Kanagaraj 2014-06-06 05:35:44 UTC
This is bug is about service is not going to CRITICAL when smb is killed/stopped. RHS bug 1104574 is about smb is getting start when user.smb is set to disable.

So this bug can still be verified.

Comment 6 RamaKasturi 2014-06-09 08:29:09 UTC
Verified and works fine with the build "nagios-server-addons-0.1.1-2.el6rhs.x86_64" , gluster-nagios-addons-0.1.1-1.el6rhs.x86_64.

As per comment 3, considering smb is enabled for all volumes by default,

1)smb status to "CRITICAL" with status information as "CRITICAL:Process smb is not running", when smb process is not running.

2)smb status shows "OK" with status information as process smb is running", when smb process is up and running.

3)smb status shows "OK" with status information as "OK:No gluster volume uses smb" when smb is disabled and no smb process is not running.

Comment 8 errata-xmlrpc 2014-09-22 19:09:57 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHEA-2014-1277.html