<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=gb2312"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:宋体;
        panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:"\@宋体";
        panose-1:2 1 6 0 3 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        text-align:justify;
        text-justify:inter-ideograph;
        font-size:10.5pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoPlainText, li.MsoPlainText, div.MsoPlainText
        {mso-style-priority:99;
        mso-style-link:"纯文本 Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.5pt;
        font-family:"Calibri","sans-serif";}
span.Char
        {mso-style-name:"纯文本 Char";
        mso-style-priority:99;
        mso-style-link:纯文本;
        font-family:"Calibri","sans-serif";}
.MsoChpDefault
        {mso-style-type:export-only;}
/* Page Definitions */
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 90.0pt 72.0pt 90.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=ZH-CN link=blue vlink=purple style='text-justify-trim:punctuation'><div class=WordSection1><p class=MsoPlainText><span lang=EN-US>We have met same performance issues when open a file. Sometime, it cost more than 10 seconds that a file open.<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>We add some debug info to locate this problem and test again and again, find it's will cost a few seconds when execute 'xdr_callmsg' function in 'rpc_request_to_xdr'.<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>A typical example of log is as below. From <span style='color:red'>[2013-06-06 13:34:59.471004] </span>to <span style='color:red'>[2013-06-06 13:35:04.890363]</span> , 'xdr_callmsg' function cost more than 5 seconds.<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>[2013-06-06 13:34:59.470991] I [rpc-clnt.c:1175:rpc_clnt_record_build_record] 0-gfs1-client-51: (thread_id is 140257410492160 )add for open_slow rpc_fill_request_end<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US style='color:red'>[2013-06-06 13:34:59.471004] I [xdr-rpcclnt.c:87:rpc_request_to_xdr] 0-rpc: (thread_id is 140257410492160 len = 131072 )add for open_slow xdrmem_create_end<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>[2013-06-06 13:34:59.570044] I [client.c:124:client_submit_request] 0-gfs1-client-86: (thread_id is 140257819739904 )add for open_slow rpc_clnt_submit<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>[2013-06-06 13:34:59.570091] I [rpc-clnt.c:1363:rpc_clnt_submit] 0-gfs1-client-86: (thread_id is 140257819739904 )add for open_slow callid end<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>......<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>[2013-06-06 13:34:59.579865] I [client3_1-fops.c:2235:client3_1_lookup_cbk] 0-gfs1-client-5: (thread_id is 140257819739904)add for open_slow lookup_cbk path=/xmail_dedup/gfs1_000/1FA/1B1<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>[2013-06-06 13:34:59.579917] I [client3_1-fops.c:2235:client3_1_lookup_cbk] 0-gfs1-client-6: (thread_id is 140257819739904)add for open_slow lookup_cbk path=/xmail_dedup/gfs1_000/1FA/1B1<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US style='color:red'>[2013-06-06 13:35:04.890363] I [xdr-rpcclnt.c:92:rpc_request_to_xdr] 0-rpc: (thread_id is 140257410492160 )add for open_slow xdr_callmsg_end<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>[2013-06-06 13:35:04.890366] I [client.c:110:client_submit_request] 0-gfs1-client-44: (thread_id is 140257785079552 )add for open_slow create the xdr payload<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>Native client and use 5 glusterfs in one server. When performance issues appear, the cpu usage is as below:<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>top - 13:45:37 up 57 days, 14:04,&nbsp; 4 users,&nbsp; load average: 6.98, 5.38, 4.67<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>Tasks: 712 total,&nbsp;&nbsp; 8 running, 704 sleeping,&nbsp;&nbsp; 0 stopped,&nbsp;&nbsp; 0 zombie<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>Cpu(s):&nbsp; 3.2%us, 63.5%sy,&nbsp; 0.0%ni, 31.5%id,&nbsp; 1.4%wa,&nbsp; 0.0%hi,&nbsp; 0.4%si,&nbsp; 0.0%st<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>Mem:&nbsp; 65956748k total, 55218008k used, 10738740k free,&nbsp; 3362972k buffers<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>Swap:&nbsp; 8388600k total,&nbsp;&nbsp;&nbsp; 41448k used,&nbsp; 8347152k free, 37370840k cached<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>&nbsp; PID USER&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; PR&nbsp; NI&nbsp; VIRT&nbsp; RES&nbsp; SHR S %CPU %MEM&nbsp;&nbsp;&nbsp; TIME+&nbsp; COMMAND<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>13905 root&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 20&nbsp;&nbsp; 0&nbsp; 554m 363m 2172 R 244.8&nbsp; 0.6&nbsp;&nbsp; 9:51.01 glusterfs<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>13650 root&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 20&nbsp;&nbsp; 0&nbsp; 766m 610m 2056 R 184.8&nbsp; 0.9&nbsp; 18:24.37 glusterfs<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>13898 root&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;20&nbsp;&nbsp; 0&nbsp; 545m 356m 2176 R 179.2&nbsp; 0.6&nbsp; 12:04.87 glusterfs<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>13919 root&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 20&nbsp;&nbsp; 0&nbsp; 547m 360m 2172 R 111.6&nbsp; 0.6&nbsp;&nbsp; 9:16.89 glusterfs<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>22460 root&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 20&nbsp;&nbsp; 0&nbsp; 486m 296m 2200 S 100.4&nbsp; 0.5 194:59.10 glusterfs <o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>13878 root&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 20&nbsp;&nbsp; 0&nbsp; 545m 361m 2176 R 99.7&nbsp; 0.6&nbsp;&nbsp; 8:35.88 glusterfs <o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>-----Original Message-----<br>From: gluster-users-bounces@gluster.org [mailto:gluster-users-bounces@gluster.org] On Behalf Of Stephan von Krawczynski<br>Sent: Thursday, June 06, 2013 10:07 PM<br>To: Pablo<br>Cc: gluster-users@gluster.org<br>Subject: Re: [Gluster-users] GlusterFS (3.3.1) - performance issues - large number of LOOKUP calls &amp; high CPU usage<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>On Thu, 06 Jun 2013 10:39:21 -0300<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>Pablo &lt;<a href="mailto:paa.listas@gmail.com"><span style='color:windowtext;text-decoration:none'>paa.listas@gmail.com</span></a>&gt; wrote:<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>&gt; I have never try this (In fact I'm just learning a bit more how to <o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>&gt; administer a Gluster server.), buy you may find it useful.<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>&gt; <o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>&gt; <a href="http://download.gluster.org/pub/gluster/glusterfs/doc/HA%20and%20Load%25"><span style='color:windowtext;text-decoration:none'>http://download.gluster.org/pub/gluster/glusterfs/doc/HA%20and%20Load%</span></a><o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>&gt; 20Balancing%20for%20NFS%20and%20SMB.html<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>&gt; <o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>&gt; Pablo.<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>The thing with this way of failover is though, that you will likely corrupt a currently written file. If your NFS-server (gluster) node dies while you write your file will be corrupt. If you use native glusterfs mounts it will not (should not). This is why I consider the NFS server feature nothing more than a bad hack. It does not deliver the safety that glusterfs promises, even if you solve the failover problem somehow.<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoPlainText><span lang=EN-US>--<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>Regards,<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>Stephan<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>_______________________________________________<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US>Gluster-users mailing list<o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><a href="mailto:Gluster-users@gluster.org"><span style='color:windowtext;text-decoration:none'>Gluster-users@gluster.org</span></a><o:p></o:p></span></p><p class=MsoPlainText><span lang=EN-US><a href="http://supercolony.gluster.org/mailman/listinfo/gluster-users"><span style='color:windowtext;text-decoration:none'>http://supercolony.gluster.org/mailman/listinfo/gluster-users</span></a><o:p></o:p></span></p></div></body></html>