Bug 1084413 - [SNAPSHOT]: gluster snapshot config should only accept the decimal numeric value
Summary: [SNAPSHOT]: gluster snapshot config should only accept the decimal numeric value
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat Storage
Component: snapshot
Version: rhgs-3.0
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: ---
: RHGS 3.0.0
Assignee: Sachin Pandit
QA Contact: Rahul Hinduja
URL:
Whiteboard: SNAPSHOT
Depends On:
Blocks: 1087203
TreeView+ depends on / blocked
 
Reported: 2014-04-04 09:36 UTC by Rahul Hinduja
Modified: 2016-09-17 13:00 UTC (History)
6 users (show)

Fixed In Version: glusterfs-3.6.0-3.0.el6rhs
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1087203 (view as bug list)
Environment:
Last Closed: 2014-09-22 19:34:55 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2014:1278 0 normal SHIPPED_LIVE Red Hat Storage Server 3.0 bug fix and enhancement update 2014-09-22 23:26:55 UTC

Description Rahul Hinduja 2014-04-04 09:36:47 UTC
Description of problem:
=======================

gluster snapshot config does accept the following

1. Decimal values like (1.1.1.1) => It converts into 1%
2. 0112 is converted into 74% (Binary to decimal conversion)
3. 0XA is converted into 10% (Hexadecimal to decimal conversion) but 0XAB fails.

In my opinion we should only expect the whole integer value between 1-100 rest all should fail with proper message.


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

glusterfs-devel-3.4.1.7.snap.mar27.2014git-1.el6.x86_64

How reproducible:
=================
1/1


Steps to Reproduce:
1. Set the config value with 1.1.1 , 0112, 0XA


Actual results:
===============

Setting values is successful.

Expected results:
=================
It should fail with proper message

Comment 3 Nagaprasad Sathyanarayana 2014-04-21 06:18:14 UTC
Marking snapshot BZs to RHS 3.0.

Comment 4 Sachin Pandit 2014-05-06 07:21:00 UTC
The patch which fixes this bug can be found in http://review.gluster.org/#/c/7457/

Comment 5 Nagaprasad Sathyanarayana 2014-05-19 10:56:33 UTC
Setting flags required to add BZs to RHS 3.0 Errata

Comment 6 senaik 2014-05-20 11:15:29 UTC
version : glusterfs-3.6.0.4-1.el6

gluster snapshot config snap-max-soft-limit 1.1.1.1
Please enter an integer value greater than zero for snap-max-soft-limit
Usage: snapshot config [volname] [snap-max-hard-limit <count>] [snap-max-soft-limit <percent>]


gluster snapshot config snap-max-soft-limit 0112
snap-max-soft-limit value cannot be more than 100
Usage: snapshot config [volname] [snap-max-hard-limit <count>] [snap-max-soft-limit <percent>]


gluster snapshot config snap-max-soft-limit 0XA
Please enter an integer value greater than zero for snap-max-soft-limit
Usage: snapshot config [volname] [snap-max-hard-limit <count>] [snap-max-soft-limit <percent>]


Marking the bug as 'Verified'

Comment 8 errata-xmlrpc 2014-09-22 19:34:55 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-1278.html


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