From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) by lore.proxmox.com (Postfix) with ESMTPS id A0DAD1FF16B for ; Wed, 14 Jan 2026 08:48:01 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 91CABB2F8; Wed, 14 Jan 2026 08:48:02 +0100 (CET) Mime-Version: 1.0 Date: Wed, 14 Jan 2026 15:47:53 +0800 Message-Id: From: "Kefu Chai" To: "Thomas Lamprecht" , X-Mailer: aerc 0.20.0 References: <20260107104422.2919586-2-k.chai@proxmox.com> In-Reply-To: <20260107104422.2919586-2-k.chai@proxmox.com> X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1768376832253 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.195 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment RCVD_IN_VALIDITY_CERTIFIED_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_RPBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_SAFE_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record URIBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [ceph.com, bluefs.cc] Subject: Re: [pve-devel] [PATCH ceph reef-stable-8] bluefs: fix OSD crash caused by incorrect alignment assertion X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: Proxmox VE development discussion Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: pve-devel-bounces@lists.proxmox.com Sender: "pve-devel" Hi Thomas, Could you help review this change at your convenience? On Wed Jan 7, 2026 at 6:41 PM CST, Kefu Chai wrote: > A regression was introduced in PR #62174 that added a `ceph_assert()` > statement which incorrectly assumes alloc_unit is always aligned. This > causes OSD crashes when the assertion fails. > > This cherry-pick removes the faulty assertion, resolving the crash while > maintaining correct functionality for both aligned and unaligned alloc_unit > values. > > Cherry-picked from: https://github.com/ceph/ceph/pull/66056 > > References: > - Upstream issue: https://tracker.ceph.com/issues/71235 > - Introduced by: https://github.com/ceph/ceph/pull/62174 > > Fixes: #7211 > > Signed-off-by: Kefu Chai > --- > ...BlueFS-truncate-accept-wierd-alloc_u.patch | 41 +++++++++++++++++++ > 1 file changed, 41 insertions(+) > create mode 100644 patches/0018-os-bluestore-In-BlueFS-truncate-accept-wierd-alloc_u.patch > > diff --git a/patches/0018-os-bluestore-In-BlueFS-truncate-accept-wierd-alloc_u.patch b/patches/0018-os-bluestore-In-BlueFS-truncate-accept-wierd-alloc_u.patch > new file mode 100644 > index 00000000000..b2507924523 > --- /dev/null > +++ b/patches/0018-os-bluestore-In-BlueFS-truncate-accept-wierd-alloc_u.patch > @@ -0,0 +1,41 @@ > +From 87c90994b2f0c4274208028367cc8f376d0b1d6e Mon Sep 17 00:00:00 2001 > +From: Adam Kupczyk > +Date: Tue, 11 Mar 2025 10:52:15 +0000 > +Subject: [PATCH] os/bluestore: In BlueFS::truncate accept wierd alloc_unit > + > +The alignment of extents might not reflect current alloc_unit[bdev]. > +It might be caused be either fallback to alternate AU size for SLOW, > +or change of allocation unit in DB or WAL. > +In such cases, truncation just leaves extent untouched. > + > +Fixes: https://tracker.ceph.com/issues/71235 > + > +Signed-off-by: Adam Kupczyk > +(cherry picked from commit 0da7a2a58c207b97c9bcf4a1dfcd9d09f0e9b954) > +--- > + src/os/bluestore/BlueFS.cc | 8 +++++--- > + 1 file changed, 5 insertions(+), 3 deletions(-) > + > +diff --git a/src/os/bluestore/BlueFS.cc b/src/os/bluestore/BlueFS.cc > +index 3e7955f6433..93dc6e4753a 100644 > +--- a/src/os/bluestore/BlueFS.cc > ++++ b/src/os/bluestore/BlueFS.cc > +@@ -3736,10 +3736,12 @@ int BlueFS::truncate(FileWriter *h, uint64_t offset)/*_WF_L*/ > + changed_extents = true; > + ++p; > + } else { > +- // cut_off > p->length means that we misaligned the extent > +- ceph_assert(cut_off == p->length); > ++ // Usually cut_off == p->length. > ++ // Case cut_off > p->length means that we misaligned the extent > ++ // or alloc size changed in the meantime. > ++ // In both cases just leave extent untouched. > + fnode.allocated = (offset - x_off) + p->length; > +- ++p; // leave extent untouched > ++ ++p; > + } > + while (p != fnode.extents.end()) { > + dirty.pending_release[p->bdev].insert(p->offset, p->length); > +-- > +2.47.3 > + _______________________________________________ pve-devel mailing list pve-devel@lists.proxmox.com https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel