Bug 1098087

Summary: [SNAPSHOT]: Snapshot restore fails if quota.conf is present and quota.cksum is not present
Product: [Red Hat Storage] Red Hat Gluster Storage Reporter: Sachin Pandit <spandit>
Component: snapshotAssignee: Sachin Pandit <spandit>
Status: CLOSED ERRATA QA Contact: Rahul Hinduja <rhinduja>
Severity: urgent Docs Contact:
Priority: urgent    
Version: rhgs-3.0CC: kparthas, nsathyan, rhs-bugs, sdharane, senaik, ssamanta, storage-qa-internal
Target Milestone: ---   
Target Release: RHGS 3.0.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: SNAPSHOT
Fixed In Version: glusterfs-3.6.0.16-1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1101483 (view as bug list) Environment:
Last Closed: 2014-09-22 19:37:59 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: 1101483, 1107575    

Description Sachin Pandit 2014-05-15 09:41:39 UTC
Description of problem:
When a snapshot is created and if quota is not enabled for that particular volume then ideally there should not be a presence of quota.conf in /var/lib/glusterd/snaps/<snapname>/<snap-id>.

Problem here is when is snapshot is taken quota.conf if not present initially, but during handshake betweeen glusterd, there is check made for presence of quota.conf. If quota.conf is not present then a 0 byte file is automatically created. Because of this snapshot restore fails. As presence of quota.conf and absence of quota.cksum is considered as an invalid scenario, we thought of failing the command.


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


How reproducible:
Everytime


Steps to Reproduce:
1. Create a volume (with quota disabled)
2. Start the volume.
3. Take a snapshot.
4. wait for handshake to take place completely (takes around 1-2 mins)
5. Stop the volume
6. restore the snap (restore fails)

Actual results:
Snapshot restore is failing.


Expected results:
Snapshot restore should be successful.


Additional info:
This is very much related to quota, so ideally if quota is not  enabled,
then 0 byte quota.conf should not be created.

Comment 2 Sachin Pandit 2014-05-26 06:51:19 UTC
I am not able to reproduce this with latest repo, I'll try to find
out which patch has corrected this issue. I'll update about the same
here very shortly.

Comment 3 Sachin Pandit 2014-05-27 09:40:39 UTC
A patch which fixes this issue has been posted upstream. Once that patch
is merged upstream, I'll send the relevant patch downstream.

Comment 9 senaik 2014-06-12 09:49:13 UTC
Version: glusterfs-3.6.0.16-1.el6rhs.x86_64
=======

Repeated the same steps as mentioned in "Steps to Reproduce", Snapshot restore is successful.

Marking the bug as 'Verified'

Comment 11 errata-xmlrpc 2014-09-22 19:37:59 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