X-MimeOLE: Produced By Microsoft Exchange V6.5
Received: by onstor-exch02.onstor.net 
	id <01C880A3.7F4285B4@onstor-exch02.onstor.net>; Fri, 7 Mar 2008 14:35:08 -0800
MIME-Version: 1.0
Content-Type: multipart/alternative;
	boundary="----_=_NextPart_001_01C880A3.7F4285B4"
Content-class: urn:content-classes:message
Subject: FW: Review request : Defect  TED00020613
Date: Fri, 7 Mar 2008 14:35:08 -0800
Message-ID: <BB375AF679D4A34E9CA8DFA650E2B04E08C0F3DC@onstor-exch02.onstor.net>
X-MS-Has-Attach: 
X-MS-TNEF-Correlator: 
Thread-Topic: Review request : Defect  TED00020613
Thread-Index: AciAoATB2kmDyeueSya7zC+C6oqZRAAAtgHQAAAM70A=
From: "Kumar Vakacharla (HCL)" <kumarv@onstor.com>
To: "Andy Sharp" <andy.sharp@onstor.com>
Cc: "Tim Gardner" <tim.gardner@onstor.com>

This is a multi-part message in MIME format.

------_=_NextPart_001_01C880A3.7F4285B4
Content-Type: text/plain;
	charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Andy,=20

=20

            Can you please review this fix.=20

           =20

Thanks,

Kumar.

=20

________________________________

From: Tim Gardner=20
Sent: Friday, March 07, 2008 2:31 PM
To: Kumar Vakacharla (HCL)
Subject: RE: Review request : Defect TED00020613

=20

Please have Andy Sharp do the code review.

Thanks for your effort on this.

	=20

=09
________________________________


	From: Kumar Vakacharla (HCL)=20
	Sent: Friday, March 07, 2008 2:10 PM
	To: Tim Gardner
	Subject: Review request : Defect TED00020613

	Tim,

	=20

	I have done a fix for the defect TED00020613 and it needs to be
reviewed. =20

	Please let me know whom can I send it for review.

	=20

	Here are the details about the fix:

	=20

	=20

	Defect Description:=20

	=20

	can't create two system get alls without renaming the first

	=20

	=20

	Cause:=20

	=20

	This is happening only in Cougar machines.  Generally <.N> is
appended if there are more than one directories output by=20

	support.sh in one day. But this behavior is failing in Linux
because of the following two reasons.=20

	=20

	1.       In Linux, echo command doesn't interpret backslash
escapes unless "-e" option is provided.  In the support.sh while
creating new directory (in function setup_new_target_dir)=20

	      "echo" has been used (without "-e" option) to pass the
arguments to the binary filesh.   This is working fine in bobcat and
cheetah because this feature is enabled by default (irrespective of "-e"
option) in=20

	      shell "sh" used by openbsd.=20

	=20

	2.       Having resolved the above issue, there is one more
issue in Linux which is related to the alignment of the buffer
containing directory entry records. =20

	In function cmd_readdir (in sm-file/filesh.c) we use a global
character buffer readBuf which is used to hold the directory entry
records. This buffer has been populated with the record data=20

	using memcpy in the function file_req_read_dir in
sm-file/file-server.c.=20

	=20

	Each directory record will be aligned to 8 bytes(sizeof(uint64))
internally. We use this rule to traverse to the next directory record in
the buffer.=20

	But in Linux I found that starting address of readBuf is not 8
byte aligned but only 4 byte aligned and this has triggered the problem.


	Because of this it is traversing to an offset which may not be
the beginning of the next record and hence reading the directory entries
fail eventually.=20

	=20

	Files Modified:=20

	=20

=09
/homes/kumarv/work/dev/nfx-tree/code/ssc-support/support.sh

=09
/homes/kumarv/work/dev/nfx-tree/code/sm-file/filesh.c=20

	=20

	=20

	P4CLIENT=3Dkumarv-DEV

	Location: /homes/kumarv/work/dev           =20

	=20

	Please let me know if you need any clarifications.

	=20

	Thanks,

	Kumar.

	=20


------_=_NextPart_001_01C880A3.7F4285B4
Content-Type: text/html;
	charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

<html xmlns:v=3D"urn:schemas-microsoft-com:vml" =
xmlns:o=3D"urn:schemas-microsoft-com:office:office" =
xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns=3D"http://www.w3.org/TR/REC-html40">

<head>
<meta http-equiv=3DContent-Type content=3D"text/html; =
charset=3Dus-ascii">
<meta name=3DGenerator content=3D"Microsoft Word 11 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]-->
<style>
<!--
 /* Font Definitions */
 @font-face
	{font-family:Tahoma;
	panose-1:2 11 6 4 3 5 4 4 2 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0in;
	margin-bottom:.0001pt;
	font-size:12.0pt;
	font-family:"Times New Roman";}
a:link, span.MsoHyperlink
	{color:blue;
	text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
	{color:purple;
	text-decoration:underline;}
span.EmailStyle17
	{mso-style-type:personal;
	font-family:Arial;
	color:windowtext;}
span.EmailStyle18
	{mso-style-type:personal-reply;
	font-family:Arial;
	color:navy;}
@page Section1
	{size:8.5in 11.0in;
	margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
	{page:Section1;}
-->
</style>

</head>

<body lang=3DEN-US link=3Dblue vlink=3Dpurple>

<div class=3DSection1>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>Andy, <o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Can
you please review this fix. <o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>Thanks,<o:p></o:p></span></font></p>=


<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'>Kumar.<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<div>

<div class=3DMsoNormal align=3Dcenter style=3D'text-align:center'><font =
size=3D3
face=3D"Times New Roman"><span style=3D'font-size:12.0pt'>

<hr size=3D2 width=3D"100%" align=3Dcenter tabindex=3D-1>

</span></font></div>

<p class=3DMsoNormal><b><font size=3D2 face=3DTahoma><span =
style=3D'font-size:10.0pt;
font-family:Tahoma;font-weight:bold'>From:</span></font></b><font =
size=3D2
face=3DTahoma><span style=3D'font-size:10.0pt;font-family:Tahoma'> Tim =
Gardner <br>
<b><span style=3D'font-weight:bold'>Sent:</span></b> Friday, March 07, =
2008 2:31
PM<br>
<b><span style=3D'font-weight:bold'>To:</span></b> Kumar Vakacharla =
(HCL)<br>
<b><span style=3D'font-weight:bold'>Subject:</span></b> RE: Review =
request :
Defect TED00020613</span></font><o:p></o:p></p>

</div>

<p class=3DMsoNormal><font size=3D3 face=3D"Times New Roman"><span =
style=3D'font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dblue face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:blue'>Please have Andy Sharp do the code =
review.</span></font><o:p></o:p></p>

<p class=3DMsoNormal><font size=3D2 color=3Dblue face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:blue'>Thanks for your effort on =
this.</span></font><o:p></o:p></p>

<blockquote style=3D'border:none;border-left:solid blue =
1.5pt;padding:0in 0in 0in 4.0pt;
margin-left:3.75pt;margin-top:5.0pt;margin-right:0in;margin-bottom:5.0pt'=
>

<p class=3DMsoNormal><font size=3D3 face=3D"Times New Roman"><span =
style=3D'font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<div class=3DMsoNormal align=3Dcenter style=3D'text-align:center'><font =
size=3D3
face=3D"Times New Roman"><span style=3D'font-size:12.0pt'>

<hr size=3D2 width=3D"100%" align=3Dcenter tabIndex=3D-1>

</span></font></div>

<p class=3DMsoNormal style=3D'margin-bottom:12.0pt'><b><font size=3D2 =
face=3DTahoma><span
style=3D'font-size:10.0pt;font-family:Tahoma;font-weight:bold'>From:</spa=
n></font></b><font
size=3D2 face=3DTahoma><span =
style=3D'font-size:10.0pt;font-family:Tahoma'> Kumar
Vakacharla (HCL) <br>
<b><span style=3D'font-weight:bold'>Sent:</span></b> Friday, March 07, =
2008 2:10
PM<br>
<b><span style=3D'font-weight:bold'>To:</span></b> Tim Gardner<br>
<b><span style=3D'font-weight:bold'>Subject:</span></b> Review request : =
Defect
TED00020613</span></font><o:p></o:p></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>Tim,<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>I have done a fix for the =
defect TED00020613
and it needs to be reviewed. &nbsp;<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>Please let me know whom can =
I send
it for review.<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'><o:p>&nbsp;</o:p></span></fo=
nt></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>Here are the details about =
the fix:<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'><o:p>&nbsp;</o:p></span></fo=
nt></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'><o:p>&nbsp;</o:p></span></fo=
nt></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><b><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial;font-weight:bold'>Defect =
Description:
<o:p></o:p></span></font></b></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'><o:p>&nbsp;</o:p></span></fo=
nt></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>can't create two system get =
alls
without renaming the first<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'><o:p>&nbsp;</o:p></span></fo=
nt></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'><o:p>&nbsp;</o:p></span></fo=
nt></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><b><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial;font-weight:bold'>Cause: =
<o:p></o:p></span></font></b></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'><o:p>&nbsp;</o:p></span></fo=
nt></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>This is happening only in =
Cougar machines.
&nbsp;Generally &lt;.N&gt; is appended if there are more than one =
directories
output by <o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>support.sh in one day. But =
this
behavior is failing in Linux because of the following two reasons. =
<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'text-indent:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'><o:p>&nbsp;</o:p></span></fo=
nt></p>

<p class=3DMsoNormal =
style=3D'margin-left:.75in;text-indent:-.25in'><font size=3D2
face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial'>1.</span></font><font
size=3D1><span =
style=3D'font-size:7.0pt'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
</span></font><font
size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial'>In Linux,
echo command doesn&#8217;t interpret backslash escapes unless =
&#8220;-e&#8221;
option is provided.&nbsp; In the support.sh while creating new directory =
(in
function <b><span =
style=3D'font-weight:bold'>setup_new_target_dir</span></b>) =
<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;
&#8220;echo&#8221; has been used (without &#8220;-e&#8221; option) to =
pass the
arguments to the binary <b><span =
style=3D'font-weight:bold'>filesh</span></b>.
&nbsp;&nbsp;This is working fine in bobcat and cheetah because this =
feature is
enabled by default (irrespective of &#8220;-e&#8221; option) in =
<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p; shell
&#8220;sh&#8221; used by openbsd. <o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.5in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'><o:p>&nbsp;</o:p></span></fo=
nt></p>

<p class=3DMsoNormal =
style=3D'margin-left:.75in;text-indent:-.25in'><font size=3D2
face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial'>2.</span></font><font
size=3D1><span =
style=3D'font-size:7.0pt'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
</span></font><font
size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;font-family:Arial'>Having
resolved the above issue, there is one more issue in Linux which is =
related to
the alignment of the buffer containing directory entry records. =
&nbsp;<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.75in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>In function <b><span
style=3D'font-weight:bold'>cmd_readdir (</span></b>in sm-file/filesh.c) =
we use a
global character buffer <b><span style=3D'font-weight:bold'>readBuf =
</span></b>which
is used to hold the directory entry records. This buffer has been =
populated
with the record data <o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.75in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>using memcpy in the =
function <b><span
style=3D'font-weight:bold'>file_req_read_dir </span></b>in =
sm-file/file-server.c.
<o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.75in'><b><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial;font-weight:bold'><o:p>&nbsp;=
</o:p></span></font></b></p>

<p class=3DMsoNormal style=3D'margin-left:.75in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>Each directory record will =
be
aligned to 8 bytes(sizeof(uint64)) internally. We use this rule to =
traverse to
the next directory record in the buffer. <o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.75in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>But in Linux I found =
that<font
color=3Dnavy><span style=3D'color:navy'> </span></font>starting address =
of readBuf
is not 8 byte aligned but only 4 byte aligned and this has triggered the
problem. <o:p></o:p></span></font></p>

<p class=3DMsoNormal style=3D'margin-left:.75in'><font size=3D2 =
face=3DArial><span
style=3D'font-size:10.0pt;font-family:Arial'>Because of this it is =
traversing to
an offset which may not be the beginning of the next record and hence =
reading
the directory entries fail eventually. <o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 color=3Dnavy face=3DArial><span =
style=3D'font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>Files Modified: <o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=
&nbsp;&nbsp;
/homes/kumarv/work/dev/nfx-tree/code/ssc-support/support.sh<o:p></o:p></s=
pan></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=
&nbsp;&nbsp;
/homes/kumarv/work/dev/nfx-tree/code/sm-file/filesh.c =
<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>P4CLIENT=3Dkumarv-DEV<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>Location: =
/homes/kumarv/work/dev&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb=
sp;&nbsp;&nbsp;
<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>Please let me know if you need any =
clarifications.<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'><o:p>&nbsp;</o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>Thanks,<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'>Kumar.<o:p></o:p></span></font></p>

<p class=3DMsoNormal><font size=3D2 face=3DArial><span =
style=3D'font-size:10.0pt;
font-family:Arial'><o:p>&nbsp;</o:p></span></font></p>

</blockquote>

</div>

</body>

</html>

------_=_NextPart_001_01C880A3.7F4285B4--
