Description of problem: ======================= When a snapshot is created, it creates the entry in /var/run/gluster/snaps/ but when the snapshot is deleted the entry is not removed. System has 10 snapshots: [root@snapshot-09 ~]# gluster snapshot list | wc 10 10 61 Number of entries are also 10: [root@snapshot-09 ~]# ls /var/run/gluster/snaps/ | wc 10 10 330 Now deleted 2 snaps, the number of total snaps are now 8 : [root@snapshot-09 ~]# gluster snapshot delete snap1 Deleting snap will erase all the information about the snap. Do you still want to continue? (y/n) y snapshot delete: snap1: snap removed successfully [root@snapshot-09 ~]# [root@snapshot-09 ~]# gluster snapshot delete snap2 Deleting snap will erase all the information about the snap. Do you still want to continue? (y/n) y snapshot delete: snap2: snap removed successfully [root@snapshot-09 ~]# [root@snapshot-09 ~]# gluster snapshot list | wc 8 8 49 [root@snapshot-09 ~]# But the number of entries in /var/run/gluster/snaps remain same 10. [root@snapshot-09 ~]# ls /var/run/gluster/snaps/ | wc 10 10 330 [root@snapshot-09 ~]# Version-Release number of selected component (if applicable): ============================================================= glusterfs-3.4.1.7.snap.mar27.2014git-1.el6.x86_64 How reproducible: ================= 1/1 Steps to Reproduce: =================== 1. Create few snaps of volume 2. Verify that respective entries are created under /var/run/gluster/snaps/ 3. Delete a snap 4. verify that respective entries are not deleted from /var/run/gluster/snaps/ Actual results: =============== Stale entries are not deleted from /var/run/gluster/snaps/ Expected results: ================= When a snapshot gets deleted its entry from /var/run/gluster/snaps/ should also delete.
Marking snapshot BZs to RHS 3.0.
Fixed with http://review.gluster.org/7128
Hitting the same issue with build: glusterfs-3.6.0.7-1.el6rhs.x86_64 . Steps remain exactly the same. [root@snapshot13 ~]# rpm -qa | grep glusterfs-3.6.0.7-1.el6rhs glusterfs-3.6.0.7-1.el6rhs.x86_64 [root@snapshot13 ~]# Currently 20 snaps are present in the system ============================================ [root@snapshot13 ~]# gluster snapshot list | wc 20 20 60 [root@snapshot13 ~]# ls /var/run/gluster/snaps/ | wc 20 20 660 [root@snapshot13 ~]# Delete 3 snaps ============== [root@snapshot13 ~]# for i in {1..3} ; do gluster --mode=script snapshot delete a$i ; done snapshot delete: a1: snap removed successfully snapshot delete: a2: snap removed successfully snapshot delete: a3: snap removed successfully List the number of entries again: ================================= [root@snapshot13 ~]# gluster snapshot list | wc 17 17 51 [root@snapshot13 ~]# ls /var/run/gluster/snaps/ | wc 20 20 660 [root@snapshot13 ~]# Snaps are deleted but the entries remain in /var/run/gluster/snaps/ Moving the bug to assigned state
Removing the blocker after discussing with Engineering Leads.
Verified with build: glusterfs-3.6.0.17-1.el6rhs.x86_64 Creation: ========== [root@snapshot13 ~]# ls /var/run/gluster/snaps/ | wc 0 0 0 [root@snapshot13 ~]# [root@snapshot13 ~]# for i in {1..10}; do gluster snapshot create snap$i vol0 ; done snapshot create: success: Snap snap1 created successfully snapshot create: success: Snap snap2 created successfully snapshot create: success: Snap snap3 created successfully snapshot create: success: Snap snap4 created successfully snapshot create: success: Snap snap5 created successfully snapshot create: success: Snap snap6 created successfully snapshot create: success: Snap snap7 created successfully snapshot create: success: Snap snap8 created successfully snapshot create: success: Snap snap9 created successfully snapshot create: success: Snap snap10 created successfully [root@snapshot13 ~]# df -h | grep /var/run | wc 10 50 1070 [root@snapshot13 ~]# ls /var/run/gluster/snaps/ | wc 10 10 330 [root@snapshot13 ~]# Deletion: ========== [root@snapshot13 ~]# for i in {1..10}; do gluster --mode=script snapshot delete snap$i ; done snapshot delete: snap1: snap removed successfully snapshot delete: snap2: snap removed successfully snapshot delete: snap3: snap removed successfully snapshot delete: snap4: snap removed successfully snapshot delete: snap5: snap removed successfully snapshot delete: snap6: snap removed successfully snapshot delete: snap7: snap removed successfully snapshot delete: snap8: snap removed successfully snapshot delete: snap9: snap removed successfully snapshot delete: snap10: snap removed successfully [root@snapshot13 ~]# [root@snapshot13 ~]# df -h | grep /var/run | wc 0 0 0 [root@snapshot13 ~]# ls /var/run/gluster/snaps/ | wc 0 0 0 [root@snapshot13 ~]# Moving the bug to verified state.
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