Bug 1323659

Summary: rpc: assign port only if it is unreserved
Product: [Community] GlusterFS Reporter: Prasanna Kumar Kalever <prasanna.kalever>
Component: rpcAssignee: Prasanna Kumar Kalever <prasanna.kalever>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: mainlineCC: bugs
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: glusterfs-3.8rc2 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1332838 (view as bug list) Environment:
Last Closed: 2016-06-16 14:03:04 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:    
Bug Blocks: 1332838    

Description Prasanna Kumar Kalever 2016-04-04 11:23:09 UTC
Description of problem:
basically we are assigning port first then checking if it is reserved

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

Fix:
we get unreserved port first and then assign it

Comment 1 Vijay Bellur 2016-04-04 11:25:04 UTC
REVIEW: http://review.gluster.org/13900 (rpc: assign port only if it is unreserved) posted (#1) for review on master by Prasanna Kumar Kalever (pkalever)

Comment 2 Vijay Bellur 2016-04-04 11:34:02 UTC
REVIEW: http://review.gluster.org/13900 (rpc: assign port only if it is unreserved) posted (#2) for review on master by Prasanna Kumar Kalever (pkalever)

Comment 3 Vijay Bellur 2016-04-06 17:08:50 UTC
COMMIT: http://review.gluster.org/13900 committed in master by Raghavendra G (rgowdapp) 
------
commit 7370633b6404bbd3c8238b464bc413689dcccf93
Author: Prasanna Kumar Kalever <prasanna.kalever>
Date:   Mon Apr 4 16:15:18 2016 +0530

    rpc: assign port only if it is unreserved
    
    Current order:
        assign port;
        check for port;
        if reserved {
            port--;
            continue to i;
        }
        bind();
    
    basically, we are assigning port first then checking if it is reserved
    
    Fix:
        get unreserved port;
        assign port;
        bind();
    
    from now, we get unreserved port first and then assign it
    
    Change-Id: I004580c5215e7c9cae3594af6405b20fcd9fa4ad
    BUG: 1323659
    Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever>
    Reviewed-on: http://review.gluster.org/13900
    Tested-by: Prasanna Kumar Kalever <pkalever>
    NetBSD-regression: NetBSD Build System <jenkins.org>
    Reviewed-by: Jeff Darcy <jdarcy>
    CentOS-regression: Gluster Build System <jenkins.com>
    Reviewed-by: Raghavendra Talur <rtalur>
    Smoke: Gluster Build System <jenkins.com>
    Reviewed-by: Raghavendra G <rgowdapp>

Comment 4 Niels de Vos 2016-06-16 14:03:04 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.8.0, please open a new bug report.

glusterfs-3.8.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://blog.gluster.org/2016/06/glusterfs-3-8-released/
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user