Bug 1210557 - gluster peer probe with selinux enabled throws error
Summary: gluster peer probe with selinux enabled throws error
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: GlusterFS
Classification: Community
Component: glusterd
Version: mainline
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Kaushal
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: qe_tracker_everglades
TreeView+ depends on / blocked
 
Reported: 2015-04-10 05:12 UTC by Bhaskarakiran
Modified: 2016-11-23 23:11 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-04-14 17:09:18 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Bhaskarakiran 2015-04-10 05:12:11 UTC
Description of problem:
=======================
With selinux enabled and set to enforcing mode, gluster peer probe throws out error message. Now that testing to be done with selinux enabled, this should work.

[root@transformers ~]# gluster peer probe ninja
peer probe: failed: Probe returned with unknown errno 107

Version-Release number of selected component (if applicable):
=============================================================
[root@transformers ~]# gluster --version
glusterfs 3.7dev built on Apr  9 2015 01:10:22
Repository revision: git://git.gluster.com/glusterfs.git
Copyright (c) 2006-2011 Gluster Inc. <http://www.gluster.com>
GlusterFS comes with ABSOLUTELY NO WARRANTY.
You may redistribute copies of GlusterFS under the terms of the GNU General Public License.

How reproducible:
=================
100%

Actual results:


Expected results:


Additional info:
===============

cli log snippet :

[2014-10-13 18:04:51.925839] I [cli.c:710:main] 0-cli: Started running gluster with version 3.7dev
[2014-10-13 18:04:52.072269] I [event-epoll.c:629:event_dispatch_epoll_worker] 0-epoll: Started thread with index 1
[2014-10-13 18:04:52.072453] I [socket.c:2409:socket_event_handler] 0-transport: disconnecting now
[2014-10-13 18:04:52.110605] I [cli-rpc-ops.c:133:gf_cli_probe_cbk] 0-cli: Received resp to probe
[2014-10-13 18:04:52.110665] E [cli-rpc-ops.c:138:gf_cli_probe_cbk] 0-cli: Probe returned with unknown errno 107
[2014-10-13 18:04:52.110759] I [input.c:36:cli_batch] 0-: Exiting with: -1

Comment 1 Atin Mukherjee 2015-04-10 05:15:17 UTC
Have you ensured that no additional firewall settings are there. Is ping to the new server responding ?

Comment 2 Bhaskarakiran 2015-04-10 05:36:22 UTC
I have flushed the iptables and ping is working..

[root@transformers glusterfs]# ping ninja
PING ninja.lab.eng.blr.redhat.com (10.70.34.68) 56(84) bytes of data.
64 bytes from ninja.lab.eng.blr.redhat.com (10.70.34.68): icmp_seq=1 ttl=64 time=0.435 ms
64 bytes from ninja.lab.eng.blr.redhat.com (10.70.34.68): icmp_seq=2 ttl=64 time=0.206 ms
^C
--- ninja.lab.eng.blr.redhat.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1558ms
rtt min/avg/max/mdev = 0.206/0.320/0.435/0.115 ms
[root@transformers glusterfs]# iptables -L
Chain INPUT (policy ACCEPT)
target     prot opt source               destination         

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination         

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination         
[root@transformers glusterfs]# 



[root@ninja ~]# iptables -L
Chain INPUT (policy ACCEPT)
target     prot opt source               destination         

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination         

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination         
[root@ninja ~]# ping transformers 
PING transformers.lab.eng.blr.redhat.com (10.70.34.44) 56(84) bytes of data.
64 bytes from transformers.lab.eng.blr.redhat.com (10.70.34.44): icmp_seq=1 ttl=64 time=0.230 ms
64 bytes from transformers.lab.eng.blr.redhat.com (10.70.34.44): icmp_seq=2 ttl=64 time=0.174 ms
^C
--- transformers.lab.eng.blr.redhat.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1726ms
rtt min/avg/max/mdev = 0.174/0.202/0.230/0.028 ms
[root@ninja ~]#

Comment 3 Kaushal 2015-04-10 07:17:16 UTC
Solving problems arising due to SELinux almost always mean writing a correct SELinux policy. As far as I understand, writing SELinux policies for a package is done by the distribution shipping the package.

Fedora, CentOS (atleast CentOS7) and RHEL 7 ship a GlusterD policy (/etc/selinux/targeted/modules/active/modules/glusterd.pp) in their selinux-policy-targetted package. I also checked with RHEL-6.6, which also contains apparently has the policy file, but is not owned by any package (we need to find how it got there, but that is another problem in itself).

Which distribution and GlusterFS package are you using? As I understand, QE testing for RHS-3.1 is being done on RHEL-6.6 and RHEL-7.1.

Can you check if you have the above mentioned policy file on your systems? If you do have it, can you attempt do a SELinux relabeling and check if that solves your issue.

In any case this is not an issue with GlusterFS itself. I recommend closing this bug. I'll wait for the answers to my questions above before closing.

Comment 4 Bhaskarakiran 2015-04-10 08:56:00 UTC
Distribution : RHEl 6.6
Gluster version : glusterfs 3.7dev built on Apr  9 2015 01:10:22
The file do exist and i tried relabelling with fixfiles but doesn't solve the problem.

Comment 5 SATHEESARAN 2015-04-10 09:06:34 UTC
Bhaskarakiran,

I am using RHEL 6.6 with glusterfs-3.7 nightly builds and I am not seeing any such problems.

Could you explain further on how did you eneded up with this problem as selinux issue ?
And provide some info on the setup related information - Is it the RHEL 6.6 you installed from ISO ?

Comment 6 SATHEESARAN 2015-04-10 09:07:06 UTC
Missed to set need_info as a part of comment5

Comment 7 Bhaskarakiran 2015-04-10 09:24:35 UTC
Installed RHEL6.6 through pxe. Did a rebelling with fixfiles and rebooted the machine. I am able to probe on server but now on the other it gives a different error :

[root@vertigo modules]# gluster peer probe transformers
peer probe: failed: Error through RPC layer, retry again later
[root@vertigo modules]# gluster peer probe transformers
peer probe: failed: Error through RPC layer, retry again later
[root@vertigo modules]#

Comment 8 SATHEESARAN 2015-04-13 08:59:14 UTC
With my last chat with Bhaskarakiran, he says everything worked well after restarting glusterd on that node.

I suppose this is not a problem with selinux in any means, as I am using the setup of RHEL 6.6 machines + glusterfs-3.7 nightly builds, with selinux enabled and I don't see this problem

Comment 9 SATHEESARAN 2015-04-14 17:09:18 UTC
This is not a bug really caused by selinux and closing the bug


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