On Wed, Nov 16, 2016 at 3:31 AM, Ankireddypalle Reddy <are...@commvault.com> wrote:
> Kaushal/Pranith, > Thanks for clarifying this. As I > understand there are 2 id's. Please correct if there is a mistake in my > assumptions: > 1) HASH generated by DHT and this will > generate the same id for a given file all the time. > 2) GFID which is an version 4 UUID. As > per the below links this is supposed to contain a time stamp field in it. > So this will not generate the same id for a given file all the time. > https://en.wikipedia.org/wiki/ > Universally_unique_identifier > https://tools.ietf.org/html/rfc4122 That is correct. There is no involvement of parent gfid in either of this :-). > > > Thanks and Regards, > ram > -----Original Message----- > From: Kaushal M [mailto:kshlms...@gmail.com] > Sent: Tuesday, November 15, 2016 1:21 PM > To: Ankireddypalle Reddy > Cc: Pranith Kumar Karampuri; gluster-users@gluster.org; Gluster Devel > Subject: Re: [Gluster-users] gfid generation > > On Tue, Nov 15, 2016 at 11:33 PM, Ankireddypalle Reddy < > are...@commvault.com> wrote: > > Pranith, > > > > Thanks for getting back on this. I am trying to see > > how gfid can be generated programmatically. Given a file name how do > > we generate gfid for it. I was reading some of the email threads about > > it where it was mentioned that gfid is generated based upon parent > > directory gfid and the file name. Given a same parent gfid and file > > name do we always end up with the same gfid. > > You're probably confusing the hash as generated for the elastic hash > algorithm in DHT, with UUID. That is a combination of > > I always thought that the GFID was a UUID, which was randomly generated. > (The random UUID might be being modified a little to allow some leeway with > directory listing, IIRC). > > Adding gluster-devel to get more eyes on this. > > > > > > > > > Thanks and Regards, > > > > ram > > > > > > > > From: Pranith Kumar Karampuri [mailto:pkara...@redhat.com] > > Sent: Tuesday, November 15, 2016 12:58 PM > > To: Ankireddypalle Reddy > > Cc: gluster-users@gluster.org > > Subject: Re: [Gluster-users] gfid generation > > > > > > > > Sorry, didn't understand the question. Are you saying give a file on > > gluster how to get gfid of the file? > > > > #getfattr -d -m. -e hex /path/to/file shows it > > > > > > > > On Fri, Nov 11, 2016 at 9:47 PM, Ankireddypalle Reddy > > <are...@commvault.com> > > wrote: > > > > Hi, > > > > Is the mapping from file name to gfid an idempotent operation. > > If so please point me to the function that does this. > > > > > > > > Thanks and Regards, > > > > Ram > > > > ***************************Legal Disclaimer*************************** > > > > "This communication may contain confidential and privileged material > > for the > > > > sole use of the intended recipient. Any unauthorized review, use or > > distribution > > > > by others is strictly prohibited. If you have received the message by > > mistake, > > > > please advise the sender by reply email and delete the message. Thank > you." > > > > ********************************************************************** > > > > > > _______________________________________________ > > Gluster-users mailing list > > Gluster-users@gluster.org > > http://www.gluster.org/mailman/listinfo/gluster-users > > > > > > > > > > -- > > > > Pranith > > > > ***************************Legal Disclaimer*************************** > > "This communication may contain confidential and privileged material > > for the sole use of the intended recipient. Any unauthorized review, > > use or distribution by others is strictly prohibited. If you have > > received the message by mistake, please advise the sender by reply > > email and delete the message. Thank you." > > ********************************************************************** > > > > _______________________________________________ > > Gluster-users mailing list > > Gluster-users@gluster.org > > http://www.gluster.org/mailman/listinfo/gluster-users > ***************************Legal Disclaimer*************************** > "This communication may contain confidential and privileged material for > the > sole use of the intended recipient. Any unauthorized review, use or > distribution > by others is strictly prohibited. If you have received the message by > mistake, > please advise the sender by reply email and delete the message. Thank you." > ********************************************************************** > -- Pranith
_______________________________________________ Gluster-users mailing list Gluster-users@gluster.org http://www.gluster.org/mailman/listinfo/gluster-users