<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=gb2312" http-equiv=Content-Type>
<STYLE>
BLOCKQUOTE {
        MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px; MARGIN-LEFT: 2em
}
OL {
        MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px
}
UL {
        MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px
}
BODY {
        LINE-HEIGHT: 1.5; FONT-FAMILY: &#23435; COLOR: #000000; FONT-SIZE: 10.5pt; 20307: 
}
P {
        MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px
}
</STYLE>

<META name=GENERATOR content="MSHTML 9.00.8112.16455"></HEAD>
<BODY style="MARGIN: 10px; FONT-SIZE: 12pt">
<DIV style="FONT-SIZE: 12pt">I am also interested in the way that how glusterfs 
can use FSCache/Cachefiles. I think the FUSE is the important part to change to 
use the local cache function of FSCache/Cachefiles.</DIV>
<DIV style="FONT-SIZE: 12pt">In our case, we have to cache a lot of small files 
about 100KB average to improve the reading performance. The IO-cache xlator in 
Gluster surely does its work,but we want cache data much more than the memory 
can hold.</DIV>
<DIV style="FONT-SIZE: 12pt">We have tested the NFS mount mode of GlusterFS, it 
works well. :)</DIV>
<DIV style="FONT-SIZE: 12pt">And you know, the NFS mount method is not the 
best&nbsp;way to get/put data from/into the Gluster Volume, so I am still 
interested in the function of the local cache of gluster native client.</DIV>
<DIV style="FONT-SIZE: 12pt">The gluster dev group has added the problem to 
their bug list:&nbsp;</DIV>
<DIV style="FONT-SIZE: 12pt">
<DIV><SPAN 
style="WIDOWS: 2; TEXT-TRANSFORM: none; TEXT-INDENT: 0px; LETTER-SPACING: normal; DISPLAY: inline !important; FONT: medium Tahoma; WHITE-SPACE: normal; ORPHANS: 2; FLOAT: none; COLOR: rgb(0,0,0); WORD-SPACING: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px">&nbsp;</SPAN><A 
style="WIDOWS: 2; TEXT-TRANSFORM: none; TEXT-INDENT: 0px; LETTER-SPACING: normal; FONT: medium Tahoma; WHITE-SPACE: normal; ORPHANS: 2; WORD-SPACING: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px" 
href="https://bugzilla.redhat.com/show_bug.cgi?id=883785">https://bugzilla.redhat.com/show_bug.cgi?id=883785</A></DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>Thanks for everybody.</DIV></DIV>
<HR style="WIDTH: 210px; HEIGHT: 1px" align=left color=#b5c4df SIZE=1>

<DIV style="FONT-SIZE: 12pt"><SPAN>Wei Wu</SPAN></DIV>
<DIV>&nbsp;</DIV>
<DIV 
style="BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: 0cm; PADDING-LEFT: 0cm; PADDING-RIGHT: 0cm; BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; PADDING-TOP: 3pt">
<DIV 
style="PADDING-BOTTOM: 8px; PADDING-LEFT: 8px; PADDING-RIGHT: 8px; BACKGROUND: #efefef; COLOR: #000000; FONT-SIZE: 12px; PADDING-TOP: 8px">
<DIV><B>发件人:</B>&nbsp;<A href="mailto:sjayaraman@suse.com">Suresh 
Jayaraman</A></DIV>
<DIV><B>发送时间:</B>&nbsp;2012-12-06&nbsp;17:47</DIV>
<DIV><B>收件人:</B>&nbsp;<A href="mailto:wuwei.tsh@gmail.com">吴巍</A></DIV>
<DIV><B>抄送:</B>&nbsp;<A href="mailto:anand.avati@gmail.com">Anand Avati</A>; <A 
href="mailto:ricwheeler@gmail.com">Ric Wheeler</A>; <A 
href="mailto:gluster-users@gluster.org">gluster-users</A>; <A 
href="mailto:linux-cachefs@redhat.com">linux-cachefs</A>; <A 
href="mailto:gluster-devel@nongnu.org">gluster-devel</A></DIV>
<DIV><B>主题:</B>&nbsp;Re: [Gluster-users] [Linux-cachefs] [Gluster-devel] Can I 
use FSCache/Cachefiles with Gluster Native Client mode?</DIV></DIV></DIV>
<DIV>
<DIV>On&nbsp;12/06/2012&nbsp;12:24&nbsp;AM,&nbsp;Anand&nbsp;Avati&nbsp;wrote:</DIV>
<DIV>&gt;&nbsp;I&nbsp;believe&nbsp;FSCache&nbsp;must&nbsp;first&nbsp;be&nbsp;implemented&nbsp;in&nbsp;FUSE&nbsp;before&nbsp;any&nbsp;userspace</DIV>
<DIV>&gt;&nbsp;filesystem&nbsp;(like&nbsp;GlusterFS)&nbsp;can&nbsp;make&nbsp;use&nbsp;of&nbsp;it?</DIV>
<DIV>&gt;&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>Sounds&nbsp;about&nbsp;right&nbsp;to&nbsp;me.&nbsp;&nbsp;Then,&nbsp;FUSE&nbsp;can&nbsp;ask&nbsp;FS-Cache&nbsp;to&nbsp;store&nbsp;/&nbsp;fetch</DIV>
<DIV>data&nbsp;on&nbsp;behalf&nbsp;of&nbsp;Glusterfs.</DIV>
<DIV>&nbsp;</DIV>
<DIV>&gt;&nbsp;On&nbsp;Wed,&nbsp;Dec&nbsp;5,&nbsp;2012&nbsp;at&nbsp;1:29&nbsp;AM,&nbsp;吴巍&nbsp;&lt;wuwei.tsh@gmail.com</DIV>
<DIV>&gt;&nbsp;&lt;mailto:wuwei.tsh@gmail.com&gt;&gt;&nbsp;wrote:</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;__</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Now&nbsp;I'm&nbsp;sure&nbsp;that&nbsp;Gluster&nbsp;FS&nbsp;native&nbsp;client&nbsp;don't&nbsp;support&nbsp;FSCache.</DIV>
<DIV>&nbsp;</DIV>
<DIV>But&nbsp;wait,&nbsp;why&nbsp;do&nbsp;you&nbsp;really&nbsp;need&nbsp;FS-Cache&nbsp;in&nbsp;your&nbsp;case?&nbsp;If&nbsp;improving</DIV>
<DIV>(re)-read&nbsp;performance&nbsp;is&nbsp;what&nbsp;matters&nbsp;to&nbsp;you,&nbsp;have&nbsp;you&nbsp;already&nbsp;taken&nbsp;a</DIV>
<DIV>look&nbsp;at&nbsp;the&nbsp;IO-Cache&nbsp;translator&nbsp;the&nbsp;Glusterfs&nbsp;provides?</DIV>
<DIV>&nbsp;</DIV>
<DIV>Do&nbsp;you&nbsp;have&nbsp;a&nbsp;really&nbsp;slow&nbsp;network?&nbsp;Do&nbsp;you&nbsp;intend&nbsp;to&nbsp;keep&nbsp;your&nbsp;cache&nbsp;on</DIV>
<DIV>an&nbsp;SSD?</DIV>
<DIV>Note&nbsp;that&nbsp;FS-Cache/Cachefiles&nbsp;is&nbsp;not&nbsp;supposed&nbsp;to&nbsp;improve&nbsp;performance&nbsp;for</DIV>
<DIV>all&nbsp;kinds&nbsp;of&nbsp;workloads.</DIV>
<DIV>&nbsp;</DIV>
<DIV>May&nbsp;be&nbsp;one&nbsp;way&nbsp;to&nbsp;know&nbsp;if&nbsp;your&nbsp;workload&nbsp;can&nbsp;benefit&nbsp;with&nbsp;FS-Cache&nbsp;or&nbsp;not&nbsp;is:</DIV>
<DIV>&nbsp;&nbsp;&nbsp;-&nbsp;enable&nbsp;FS-Cache&nbsp;in&nbsp;NFS&nbsp;and&nbsp;try&nbsp;accessing&nbsp;the&nbsp;Gluster&nbsp;namespace&nbsp;via&nbsp;NFS</DIV>
<DIV>&nbsp;&nbsp;&nbsp;-&nbsp;compare&nbsp;its&nbsp;performance&nbsp;with&nbsp;FS-Cache&nbsp;on&nbsp;NFS&nbsp;disabled</DIV>
<DIV>&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;There&nbsp;are&nbsp;no&nbsp;codes&nbsp;about&nbsp;FSCache&nbsp;in&nbsp;the&nbsp;source&nbsp;code&nbsp;of&nbsp;Gluster&nbsp;FS.</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;the&nbsp;command&nbsp;&nbsp;"mount&nbsp;-t&nbsp;glusterfs&nbsp;server1:/test-volume&nbsp;/mnt/glusterfs</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-o&nbsp;fsc"&nbsp;&nbsp;will&nbsp;be&nbsp;executed&nbsp;by&nbsp;/sbin/mount.glusterfs,&nbsp;and&nbsp;the&nbsp;"-o&nbsp;fsc"</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;option&nbsp;will&nbsp;be&nbsp;ignored&nbsp;silently.&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks&nbsp;for&nbsp;everybody.</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;------------------------------------------------------------------------</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Wei&nbsp;Wu</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*From:*&nbsp;Suresh&nbsp;Jayaraman&nbsp;&lt;mailto:sjayaraman@suse.com&gt;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*Date:*&nbsp;2012-12-05&nbsp;15&nbsp;&lt;tel:2012-12-05%C2%A015&gt;:06</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*To:*&nbsp;吴巍&nbsp;&lt;mailto:wuwei.tsh@gmail.com&gt;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*CC:*&nbsp;Ric&nbsp;Wheeler&nbsp;&lt;mailto:ricwheeler@gmail.com&gt;;&nbsp;gluster-users</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;mailto:gluster-users@gluster.org&gt;;&nbsp;linux-cachefs</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;mailto:linux-cachefs@redhat.com&gt;;&nbsp;gluster-devel</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;mailto:gluster-devel@nongnu.org&gt;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*Subject:*&nbsp;Re:&nbsp;[Linux-cachefs]&nbsp;[Gluster-devel]&nbsp;Can&nbsp;I&nbsp;use</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;FSCache/Cachefiles&nbsp;with&nbsp;Gluster&nbsp;Native&nbsp;Client&nbsp;mode?</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;On&nbsp;12/03/2012&nbsp;05:59&nbsp;PM,&nbsp;Ric&nbsp;Wheeler&nbsp;wrote:</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&nbsp;On&nbsp;12/02/2012&nbsp;10:29&nbsp;PM,&nbsp;吴巍&nbsp;wrote:</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&gt;&nbsp;Hey,</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&gt;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&gt;&nbsp;I&nbsp;Download&nbsp;the&nbsp;GlusterFS&nbsp;3.2.7&nbsp;Release&nbsp;and&nbsp;it&nbsp;works&nbsp;well.&nbsp;And&nbsp;I&nbsp;want</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&gt;&nbsp;to&nbsp;improve&nbsp;the&nbsp;reading&nbsp;performance&nbsp;with&nbsp;FSCache/Cachefiles&nbsp;model.</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&gt;&nbsp;I&nbsp;use&nbsp;the&nbsp;command&nbsp;line:</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&gt;&nbsp;mount&nbsp;-t&nbsp;glusterfs&nbsp;server1:/test-volume&nbsp;/mnt/glusterfs&nbsp;-o&nbsp;fsc</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&gt;&nbsp;and&nbsp;no&nbsp;error&nbsp;reported.&nbsp;But&nbsp;the&nbsp;local&nbsp;cache&nbsp;function&nbsp;of&nbsp;FSCache&nbsp;is&nbsp;not</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Does&nbsp;Glusterfs&nbsp;support&nbsp;fscache?&nbsp;File&nbsp;systems&nbsp;typically&nbsp;have&nbsp;to&nbsp;be</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;modified&nbsp;to&nbsp;include&nbsp;support&nbsp;for&nbsp;fscache&nbsp;(see&nbsp;fs/cifs/fscache*.[c,h]&nbsp;or</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;fs/nfs/fscache*.[c,h]&nbsp;in&nbsp;the&nbsp;kernel&nbsp;source&nbsp;for&nbsp;example).&nbsp;IOW,&nbsp;they&nbsp;have</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;to&nbsp;be&nbsp;fscache&nbsp;aware&nbsp;to&nbsp;be&nbsp;able&nbsp;to&nbsp;use&nbsp;the&nbsp;persistent&nbsp;disk&nbsp;caching.</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Have&nbsp;you&nbsp;checked&nbsp;if&nbsp;the&nbsp;option&nbsp;'fsc'&nbsp;is&nbsp;being&nbsp;silently&nbsp;ignored?&nbsp;Try</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;mounting&nbsp;with&nbsp;'-vvv'&nbsp;to&nbsp;see&nbsp;whether&nbsp;it&nbsp;reveals&nbsp;more.</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;What&nbsp;do&nbsp;you&nbsp;mean&nbsp;by&nbsp;"local&nbsp;cache&nbsp;function&nbsp;of&nbsp;FSCache&nbsp;is&nbsp;not&nbsp;active"?&nbsp;Did</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;you&nbsp;mean&nbsp;that&nbsp;the&nbsp;files&nbsp;are&nbsp;not&nbsp;getting&nbsp;cached?&nbsp;or&nbsp;File&nbsp;are&nbsp;not&nbsp;being</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;fetched&nbsp;from&nbsp;the&nbsp;cache&nbsp;when&nbsp;re-read?</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If&nbsp;it&nbsp;is&nbsp;already&nbsp;supported,&nbsp;are&nbsp;you&nbsp;running&nbsp;the&nbsp;cachefilesd&nbsp;user-space</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;daemon?</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;FS-Cache&nbsp;by&nbsp;default&nbsp;uses&nbsp;/var/cache/fscache&nbsp;dir&nbsp;for&nbsp;caching.&nbsp;You&nbsp;could</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;check&nbsp;whether&nbsp;the&nbsp;cached&nbsp;files&nbsp;are&nbsp;being&nbsp;seen&nbsp;there.</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Also,&nbsp;/proc/fs/fscache/stats&nbsp;might&nbsp;reveal&nbsp;more&nbsp;details&nbsp;about&nbsp;pages</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;marked&nbsp;for&nbsp;caching,&nbsp;retrieved&nbsp;successfully&nbsp;from&nbsp;cache&nbsp;or&nbsp;cache&nbsp;returned</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-ENODATA&nbsp;etc.</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&gt;&nbsp;active.&nbsp;How&nbsp;can&nbsp;I&nbsp;use&nbsp;the&nbsp;local&nbsp;cache&nbsp;function&nbsp;of&nbsp;FSCache&nbsp;with&nbsp;Gluster</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&gt;&nbsp;Native&nbsp;Client&nbsp;&nbsp;mount&nbsp;mode?</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&gt;</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&nbsp;Adding&nbsp;in&nbsp;the&nbsp;fscache&nbsp;list&nbsp;to&nbsp;see&nbsp;if&nbsp;anyone&nbsp;there&nbsp;has&nbsp;experimented&nbsp;with</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&nbsp;this,</DIV>
<DIV>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&gt;&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV>--&nbsp;</DIV>
<DIV>Suresh&nbsp;Jayaraman</DIV></DIV></BODY></HTML>