[Bugs] [Bug 1463191] gfapi: discard glfs object when volume is deleted

bugzilla at redhat.com bugzilla at redhat.com
Wed Aug 23 08:54:13 UTC 2017


https://bugzilla.redhat.com/show_bug.cgi?id=1463191



--- Comment #9 from Venkata R Edara <redara at redhat.com> ---
steps to reproduce the issue:

here is gfapi python program , volume name is "test2", hostname is "gluster2".

host 1. in client machine 
>>> from gluster import gfapi
>>> volume = gfapi.Volume('gluster2','test2')
>>> volume.mount()
>>> volume.mkdir('/dir1')
>>> volume.mkdir('/dir2')

host 2.in server machine, that is gluster2 
lets delete the test2 volume on server side and re-create the volume
gluster2 # gluster volume stop test2
gluster2 # gluster volume delete test2
gluster2 # rm -rf /storage/brick3/test2vol
gluster2 # mkdir /storage/brick3/test2vol
gluster2 # gluster volume create test2 gluster2:/storage/brick3/test2vol
gluster2 # gluster volume start test2

host 1. come back to client machine, continue python program, we have volume
object here. you will be able to create dir on old volume obj which should be
discarded.

>>> volume.listdir('/')
[]
>>> volume.mkdir('/dir3')
>>> volume.listdir('/')
['dir3']

This shows that if volume is re-created with same name on server side, client
program can access using old volume object. the fix to bug raises ENXIO err.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are on the CC list for the bug.


More information about the Bugs mailing list