Bug 1098991

Summary: Dist-geo-rep: Invalid slave url (::: three or more colons) error out with unclear error message.
Product: [Community] GlusterFS Reporter: Aravinda VK <avishwan>
Component: geo-replicationAssignee: Kotresh HR <khiremat>
Status: CLOSED NEXTRELEASE QA Contact:
Severity: medium Docs Contact:
Priority: low    
Version: mainlineCC: avishwan, bugs, chrisw, csaba, khiremat, rhs-bugs, sankarshan, smohan
Target Milestone: ---Keywords: EasyFix
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 991086 Environment:
Last Closed: 2019-05-11 11:09:37 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: 991086, 1285192    
Bug Blocks:    

Description Aravinda VK 2014-05-19 10:08:06 UTC
+++ This bug was initially created as a clone of Bug #991086 +++

Description of problem:
While creating the geo-rep session, invalid slave url with single colon (:) gives proper and clear error message. But specifying three or more colons (:::) gives unclear error message.

Version-Release number of selected component (if applicable):
glusterfs-3.4.0.14rhs-1.el6rhs.x86_64

How reproducible:
Always

Steps to Reproduce:
1. gluster v geo master_vol slave_node:slave_vol create
2. gluster v geo master_vol slave_node:::slave_vol create

Actual results:
After step 1

[root@spitfire ]# gluster v geo master lightning:slave create
lightning:slave is not a valid slave url.
geo-replication command failed

[root@spitfire ]# gluster v geo master lightning:::slave create
Unable to create /var/lib/glusterd/geo-replication/master-:slave/ssh%3A%2F%2Froot%4010.70.43.145%3Agluster%3A%2F%2F127.0.0.1%3A%3Aslave.status. Error : Bad file descriptor
geo-replication command failed


Expected results:
It should say the slave url is not valid.

Additional info:

--- Additional comment from RHEL Product and Program Management on 2013-08-01 12:24:07 EDT ---

Since this issue was entered in bugzilla, the release flag has been
set to ? to ensure that it is properly evaluated for this release.

--- Additional comment from Nagaprasad Sathyanarayana on 2014-05-06 07:43:43 EDT ---

Dev ack to 3.0 RHS BZs

Comment 1 Anand Avati 2014-05-19 10:15:08 UTC
REVIEW: http://review.gluster.org/7796 (geo-rep: Validate slave URL in geo-rep create command) posted (#1) for review on master by Aravinda VK (avishwan)

Comment 2 Aravinda VK 2015-04-20 15:39:40 UTC
Need clean way of handling this via Gluster CLI parser changes. Moving this back to ASSIGNED.

Comment 3 Aravinda VK 2015-12-29 10:22:20 UTC
Fix to be done in $SRC/cli/src/cli-cmd-parser.c

Comment 4 Yaniv Kaul 2019-04-22 14:11:36 UTC
Status?

Comment 5 Worker Ant 2019-04-23 07:18:00 UTC
REVIEW: https://review.gluster.org/22605 (cli: Validate invalid slave url) posted (#1) for review on master by Kotresh HR

Comment 6 Kotresh HR 2019-04-23 07:18:23 UTC
(In reply to Yaniv Kaul from comment #4)
> Status?

Posted the patch

Comment 7 Worker Ant 2019-05-11 11:09:37 UTC
REVIEW: https://review.gluster.org/22605 (cli: Validate invalid slave url) merged (#3) on master by Amar Tumballi