From 696ebaa675e6a120e441aae91289be2aa43900e1 Mon Sep 17 00:00:00 2001 From: Kotresh HR Date: Fri, 24 May 2024 17:03:10 +0530 Subject: [PATCH] tools/first-damage: Make CEPH_NOSNAP int64 Make CEPH_NOSNAP int64 and pack 8 bytes when updating the omap value. Signed-off-by: Kotresh HR Signed-off-by: Venky Shankar --- src/tools/cephfs/first-damage.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tools/cephfs/first-damage.py b/src/tools/cephfs/first-damage.py index 6a341924119d..6207b5c17936 100644 --- a/src/tools/cephfs/first-damage.py +++ b/src/tools/cephfs/first-damage.py @@ -59,7 +59,7 @@ NEXT_SNAP = None CONF = os.environ.get('CEPH_CONF') REPAIR_NOSNAP = None -CEPH_NOSNAP = 0xfffffffe # int32 -2 +CEPH_NOSNAP = 0xfffffffffffffffe # int64 -2 ROOT_INODE = "1.00000000" LOST_FOUND_INODE = "4.00000000" @@ -96,7 +96,7 @@ def traverse(MEMO, ioctx): log.warning(f"repairing first==CEPH_NOSNAP damage, setting to NEXT_SNAP (0x{NEXT_SNAP:x})") first = NEXT_SNAP nval = bytearray(val) - struct.pack_into("