[lustre-devel] Reserve OBD_CONNECT2 flag for truncate(0) degraded layout replace
Keguang Xu via lustre-devel <[email protected]> Thu, 16 Jul 2026 03:32:52 +0000
| Newsgroups | org.lustre.lists.lustre-devel |
|---|---|
| Message-ID | <LV3PR19MB8480BCD127068088198B9E07BDC72@LV3PR19MB8480.namprd19.prod.outlook.com> |
--===============7960146449628285450==
Content-Language: zh-CN
Content-Type: multipart/alternative;
boundary="_000_LV3PR19MB8480BCD127068088198B9E07BDC72LV3PR19MB8480namp_"
--_000_LV3PR19MB8480BCD127068088198B9E07BDC72LV3PR19MB8480namp_
Content-Type: text/plain; charset="gb2312"
Content-Transfer-Encoding: base64
SGkgQW5kcmVhcywNCg0KSSdkIGxpa2UgdG8gcmVzZXJ2ZSBhIG5ldyBPQkRfQ09OTkVDVDIgYml0
IGZvciBhbiB1cGNvbWluZyBmZWF0dXJlIChjdXJyZW50bHkgZHJhZnRlZCBhcyBPQkRfQ09OTkVD
VDJfTEFZT1VUX1JFUExBQ0VELCBtYXliZSAweDQwMDAwMDAwMDAwMFVMTCA/KS4NCg0KRmVhdHVy
ZQ0KUGxlYXNlIGNoZWNrIGh0dHBzOi8vamlyYS53aGFtY2xvdWQuY29tL2Jyb3dzZS9MVS0yMDIx
MSwgb24gdHJ1bmNhdGUoMCksIGlmIHRoZSBjdXJyZW50IGZpbGUgbGF5b3V0IGhhcyB1bmF2YWls
YWJsZS9kZWdyYWRlZCBzdHJpcGVzIChlLmcuIE9TVCBtYXJrZWQgZGVncmFkZWQpLCB0aGUgTURT
IG1heSByZXBsYWNlIHRoZSBsYXlvdXQgKG9ycGhhbiArIHN3YXBfbGF5b3V0cykgc28gdGhlIGNs
aWVudCBjYW4gY29udGludWUgd2l0aCBhIHVzYWJsZSBsYXlvdXQuIEFmdGVyIGEgc3VjY2Vzc2Z1
bCByZXBsYWNlLCB0aGUgc2V0YXR0ciByZXBseSByZXR1cm5zIHRoZSBuZXcgTE9WRUEuDQpUaGUg
Y2xpZW50IG11c3QgZGlzY2FyZCB0aGUgb2xkIHBhZ2UvT1NDIGNhY2hlIGR1cmluZyBsYXlvdXQg
YXBwbHksIGluc3RlYWQgb2YgZG9pbmcgQ0xfRlNZTkNfTE9DQUwgd3JpdGViYWNrIHRvIHRoZSBv
bGQgKHBvc3NpYmx5IGRlZ3JhZGVkKSBzdHJpcGVzLiBPdGhlcndpc2UgbGF5b3V0IGNoYW5nZSBm
YWlscyB3aXRoIC1FSU5WQUwsIHdoaWxlIHRoZSBNRFMgaGFzIGFscmVhZHkgY29tbWl0dGVkIHRy
dW5jYXRlICsgbGF5b3V0IHJlcGxhY2UuDQoNCldoeSBhIG5ldyBjb25uZWN0IGZsYWcgaXMgbmVl
ZGVkDQpUaGlzIGJlaGF2aW9yIHJlcXVpcmVzIGNvb3JkaW5hdGVkIGNsaWVudC9NRFMgc3VwcG9y
dDoNCg0KICAqICAgTmV3IE1EUyArIG9sZCBjbGllbnQ6IGlmIHRoZSBNRFMgcmVwbGFjZXMgdGhl
IGxheW91dCBhbnl3YXksIHRoZSBvbGQgY2xpZW50IHN0aWxsIHdyaXRlYmFja3Mgb24gbGF5b3V0
IGNoYW5nZSBhbmQgY2FuIGZhaWwgdHJ1bmNhdGUgd2l0aCAtRUlOVkFMLCBsZWF2aW5nIHNlcnZl
ci9jbGllbnQgc3RhdGUgaW5jb25zaXN0ZW50Lg0KICAqDQpXaXRoIGEgY29ubmVjdCBmbGFnLCB0
aGUgTURTIGNhbiBza2lwIGxheW91dCByZXBsYWNlIHVubGVzcyB0aGUgY2xpZW50IGFkdmVydGlz
ZWQgc3VwcG9ydCwgYW5kIHRoZSBjbGllbnQga25vd3MgdG8gZGlzY2FyZC1wcnVuZS4NCg0KVGhh
bmtzLA0KS2VndWFuZyBYdQ0KDQo=
--_000_LV3PR19MB8480BCD127068088198B9E07BDC72LV3PR19MB8480namp_
Content-Type: text/html; charset="gb2312"
Content-Transfer-Encoding: quoted-printable
<html>
<head>
<meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3Dgb2312">
<style type=3D"text/css" style=3D"display:none;"> P {margin-top:0;margin-bo=
ttom:0;} </style>
</head>
<body dir=3D"ltr">
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Hi Andreas,</div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
color: rgb(0, 0, 0);">
<span style=3D"font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService,=
Calibri, Helvetica, sans-serif; font-size: 12pt;">I'd like to reserve a ne=
w
</span><span style=3D"font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontS=
ervice, Calibri, Helvetica, sans-serif; font-size: 10pt;"><code>OBD_CONNECT=
2</code></span><span style=3D"font-family: Aptos, Aptos_EmbeddedFont, Aptos=
_MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt;">
bit for an upcoming feature (currently drafted as </span><span style=3D"fo=
nt-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helveti=
ca, sans-serif; font-size: 10pt;"><code>OBD_CONNECT2_LAYOUT_REPLACED,
</code></span><span style=3D"font-family: Aptos, Aptos_EmbeddedFont, Aptos_=
MSFontService, Calibri, Helvetica, sans-serif; font-size: 12pt;"><code styl=
e=3D"font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, =
Helvetica, sans-serif;">maybe</code></span><span style=3D"font-family: Apto=
s, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, sans-serif;=
font-size: 10pt;"><code> </code></span><span style=3D"font-family: mo=
nospace; font-size: 10pt;">0x400000000000ULL
?</span><span style=3D"font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFon=
tService, Calibri, Helvetica, sans-serif; font-size: 12pt;">).</span></div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<b><br>
</b></div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<b>Feature</b></div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; color: rgb(0, 0, 0);">
<span style=3D"font-size: 12pt;">Please check <a href=3D"https://jira.whamc=
loud.com/browse/LU-20211" target=3D"_blank" id=3D"OWA5e1e30d6-ab92-5f2f-6ab=
3-b224f17a6aa1" class=3D"fui-Link ___1q1shib f2hkw1w f3rmtva f1ewtqcl fyind=
8e f1k6fduh f1w7gpdv fk6fouc fjoy568 figsok6 f1s184ao f1mk8lai fnbmjn9 f1o7=
00av f13mvf36 f1cmlufx f9n3di6 f1ids18y f1tx3yz7 f1deo86v f1eh06m1 f1iescvh=
fhgqx19 f1olyrje f1p93eir f1nev41a f1h8hb77 f1lqvz6u f10aw75t fsle3fq f17a=
e5zn OWAAutoLink" title=3D"https://jira.whamcloud.com/browse/lu-20211" rel=
=3D"noreferrer noopener">
https://jira.whamcloud.com/browse/LU-20211</a>, on truncate(0), if the curr=
ent file layout has unavailable/degraded stripes (e.g. OST marked degraded)=
, the
</span><span style=3D"font-size: 10pt;">MDS</span><span style=3D"font-size:=
12pt;"> may replace the layout (orphan +
</span><span style=3D"font-size: 10pt;"><code>swap_layouts</code></span><sp=
an style=3D"font-size: 12pt;">) so the client can continue with a usable la=
yout. After a successful replace, the setattr reply returns the new
</span><span style=3D"font-size: 10pt;">LOVEA</span><span style=3D"font-siz=
e: 12pt;">.</span></div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; color: rgb(0, 0, 0);">
<span style=3D"font-size: 12pt;">The client must discard the old page/OSC c=
ache during layout apply, instead of doing
</span><span style=3D"font-size: 10pt;"><code>CL_FSYNC_LOCAL</code></span><=
span style=3D"font-size: 12pt;"> writeback to the old (possibly degraded) s=
tripes. Otherwise layout change fails with
</span><span style=3D"font-size: 10pt;"><code>-EINVAL</code></span><span st=
yle=3D"font-size: 12pt;">, while the
</span><span style=3D"font-size: 10pt;">MDS</span><span style=3D"font-size:=
12pt;"> has already committed truncate + layout replace.</span></div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<b><br>
</b></div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<b>Why a new connect flag is needed</b></div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; color: rgb(0, 0, 0);">
<span style=3D"font-size: 12pt;">This behavior requires coordinated client/=
</span><span style=3D"font-size: 10pt;">MDS</span><span style=3D"font-size:=
12pt;"> support:</span></div>
<ul>
<li style=3D"font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, C=
alibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); margin=
-top: 0px; margin-bottom: 0px;">
New <span style=3D"font-size: 10pt;" role=3D"presentation">MDS</span> + old=
client: if the
<span style=3D"font-size: 10pt;" role=3D"presentation">MDS</span> replaces =
the layout anyway, the old client still writebacks on layout change and can=
fail truncate with
<span style=3D"font-size: 10pt;" role=3D"presentation"><code>-EINVAL</code>=
</span>, leaving server/client state inconsistent.</li><li style=3D"font-fa=
mily: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helvetica, s=
ans-serif; font-size: 12pt; color: rgb(0, 0, 0); margin-top: 0px; margin-bo=
ttom: 0px;">
<div class=3D"elementToProof" role=3D"presentation">With a connect flag, th=
e <span style=3D"font-size: 10pt;">
MDS</span> can skip layout replace unless the client advertised support, an=
d the client knows to discard-prune.</div>
</li></ul>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Thanks,</div>
<div class=3D"elementToProof" style=3D"margin-top: 8px; margin-bottom: 8px;=
font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, Calibri, Helv=
etica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Keguang Xu</div>
<div style=3D"font-family: Aptos, Aptos_EmbeddedFont, Aptos_MSFontService, =
Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
</body>
</html>
--_000_LV3PR19MB8480BCD127068088198B9E07BDC72LV3PR19MB8480namp_--
--===============7960146449628285450==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
_______________________________________________
lustre-devel mailing list
[email protected]
http://lists.lustre.org/listinfo.cgi/lustre-devel-lustre.org
--===============7960146449628285450==--