Description of problem: gluster peer probe <single character hostname> returns the usage. The host name can also be of a 1 character. Version-Release number of selected component (if applicable): [root@QA-54 glusterfs]# gluster --version glusterfs 3.3.0qa45 built on Jun 1 2012 00:10:06 How reproducible: Steps to Reproduce: 1. use the cli "gluster peer probe" with single character hostname Actual results: [root@QA-54 glusterfs]# gluster --version glusterfs 3.3.0qa45 built on Jun 1 2012 00:10:06 [root@QA-54 glusterfs]# gluster peer probe Q Usage: peer probe <HOSTNAME> [root@QA-54 glusterfs]# Expected results: Additional info:
Kaushal, --- a/libglusterfs/src/common-utils.c +++ b/libglusterfs/src/common-utils.c @@ -1644,7 +1644,7 @@ valid_host_name (char *address, int length) char *temp_str = NULL; char *save_ptr = NULL; - if ((length > _POSIX_HOST_NAME_MAX) || (length == 1)) { + if ((length > _POSIX_HOST_NAME_MAX) || (length < 1)) { ret = 0; goto out; } fixed the issue. Check if that is right fix and submit it.
CHANGE: http://review.gluster.com/3516 (libglusterfs: valid_host_name() fix) merged in release-3.3 by Vijay Bellur (vijay)
Fixed in master.