<div>Thanks Joe, I've read your blog post as well as your post regarding the .glusterfs directory.</div>
<div>&nbsp;</div>
<div>I found some unneeded duplicate files which were not being read properly. I then deleted the link file from the brick. This always removes the duplicate file from the listing, but the file does not always become readable. If I also delete the associated file in the .glusterfs directory on that brick, then some more files become readable. However this solution still doesn't work for all files.</div>
<div>&nbsp;</div>
<div>I know the file on the brick is not corrupt as it can be read directly from the brick directory.</div>
<div>&nbsp;</div>
<div>Hopefully you have some other ideas I could try.</div>
<div>&nbsp;</div>
<div>Otherwise, I may proceed by writing a script to handle the files one-by-one. Move the actual file from .glusterfs off the brick to a temporary location, remove all references to the file on the bricks, then copy the file back onto the mounted volume.. It's not ideal but hopefully this is a one-time occurence.</div>
<div>&nbsp;</div>
<div>Tom</div>
<div>&nbsp;</div>
<blockquote class="threadBlockQuote" style="border-left: 2px solid #C2C2C2; padding-left: 3px; margin-left: 4px;">--------- Original Message ---------
<div>Subject: Re: [Gluster-users] Hundreds of duplicate files<br />From: "Joe Julian" &lt;joe@julianfamily.org&gt;<br />Date: 12/27/14 3:28 pm<br />To: tbenzvi@3vgeomatics.com, gluster-users@gluster.org<br /><br />The linkfile you showed earlier was perfect. <br /> <br /> Check this article on my blog for the details on how dht works and how to calculate hashes: <a href="http://joejulian.name/blog/dht-misses-are-expensive/">http://joejulian.name/blog/dht-misses-are-expensive/</a><br /><br />
<div class="gmail_quote">On December 27, 2014 3:18:00 PM PST, tbenzvi@3vgeomatics.com wrote:
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid #cccccc; padding-left: 1ex;">
<div>That didn't fix it unfortunately. In fact, I've done a full rebalance after initially discovering the problem and after updating Gluster, but nothing was changed..</div>
<div>&nbsp;</div>
<div>I don't know too much about how Gluster works internally; is it possible to compute the hash for each duplicate filename - figure out on which brick it belong is and find where it actually resides, then recreate the link file or update the linkto attribute? Assuming broken link files are the problem..</div>
<div>&nbsp;</div>
<blockquote class="threadBlockQuote" style="border-left: 2px solid #C2C2C2; padding-left: 3px; margin-left: 4px;">--------- Original Message ---------
<div>Subject: Re: [Gluster-users] Hundreds of duplicate files<br />From: "Joe Julian" &lt;joe@julianfamily.org&gt;<br />Date: 12/27/14 1:55 pm<br />To: tbenzvi@3vgeomatics.com, gluster-users@gluster.org<br /><br />I'm wondering if this is from a corrupted failed rebalance. In a directory that has duplicates, do "setfattr -n trusted.distribute.fix.layout -v 1 ."<br /> <br /> If that fixes it, do a rebalance...fix-layout<br /><br />
<div class="gmail_quote">On December 27, 2014 12:38:01 PM PST, tbenzvi@3vgeomatics.com wrote:
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid #cccccc; padding-left: 1ex;">
<div>Ok, I am really tearing my hair out here. I tried doing this manually for several other files just to be sure. And in these cases it removed the duplicate file from the directory listing, but the file can still not be read.. Reading directly from the brick works fine.</div>
<div>&nbsp;</div>
<blockquote class="threadBlockQuote" style="border-left: 2px solid #C2C2C2; padding-left: 3px; margin-left: 4px;">--------- Original Message ---------
<div>Subject: Re: [Gluster-users] Hundreds of duplicate files<br />From: "Joe Julian" &lt;joe@julianfamily.org&gt;<br />Date: 12/27/14 12:01 pm<br />To: gluster-users@gluster.org<br /><br />Should be safe.<br /> <br /> Here's what I've done in the past to clean up rogue dht link files (not that yours looked rogue though):<br /> <br /> find $brick_root -type f -size 0 -perm 1000 -exec /bin/rm {} \;</div>
</blockquote>
</blockquote>
</div>
</div>
</blockquote>
</blockquote>
</div>
</div>
</blockquote>