Opened 10 years ago

Closed 10 years ago

#11026 closed bug (fixed)

invalid b+tree with checkfs

Reported by: taos Owned by: axeld
Priority: high Milestone: R1
Component: File Systems/BFS Version: R1/Development
Keywords: Cc: degea@…
Blocked By: Blocking:
Platform: All

Description

Using hrev47488 gcc2 hybrid (upgraded via pkgman).

Running checkfs for a number of different partitions I get many "invalid b+tree" messages that I don't see if I run checkfs on the same partitions with an older haiku revision (hrev47477). Compare the attached terminal outputs from hrev47488 (hrev47488_checkfs.txt) and hrev47477 (hrev47477_checkfs.txt).

Syslog of hrev47488 is also cluttered with lines such as:

KERN: inode 1179719: node 9216 key 22 larger than it should!
KERN: inode 1179719: node 10240 key 23 larger than it should!
KERN: inode 1179719: node 11264 key 20 larger than it should!
KERN: inode 1179719: node 12288 key 20 larger than it should!
KERN: inode 655363: node 3072 key 26 larger than it should!
KERN: inode 655363: node 4096 key 25 larger than it should!
KERN: inode 655363: node 5120 key 25 larger than it should!

Attachments (3)

hrev47488_checkfs.txt (11.9 KB ) - added by taos 10 years ago.
Terminal output of checkfs on hrev47488.
hrev47477_checkfs.txt (519 bytes ) - added by taos 10 years ago.
Terminal output of checkfs on hrev47477.
syslog_hrev47488.txt (460.6 KB ) - added by taos 10 years ago.
Syslog of hrev47488.

Download all attachments as: .zip

Change History (12)

by taos, 10 years ago

Attachment: hrev47488_checkfs.txt added

Terminal output of checkfs on hrev47488.

by taos, 10 years ago

Attachment: hrev47477_checkfs.txt added

Terminal output of checkfs on hrev47477.

by taos, 10 years ago

Attachment: syslog_hrev47488.txt added

Syslog of hrev47488.

comment:1 by taos, 10 years ago

I'm not sure if this is related but when I tried to build hrev47489 on hrev47477 (and on hrev47488 respectively) I got the following error:

.
.
.
InitScript1 /GIT/haiku/generated.x86gcc2/haiku.image-init-vars 
AddTargetVariableToScript1 <unique!target>_target_761 
MkDir1 /GIT/haiku/generated.x86gcc2/objects/haiku_host/x86_gcc2/release/tools/bfs_shell 
C++ /GIT/haiku/generated.x86gcc2/objects/haiku_host/x86_gcc2/release/tools/bfs_shell/additional_commands.o 
C++ /GIT/haiku/generated.x86gcc2/objects/haiku_host/x86_gcc2/release/tools/bfs_shell/command_checkfs.o 
C++ /GIT/haiku/generated.x86gcc2/objects/haiku_host/x86_gcc2/release/tools/bfs_shell/bfs_disk_system.o 
C++ /GIT/haiku/generated.x86gcc2/objects/haiku_host/x86_gcc2/release/tools/bfs_shell/BlockAllocator.o 
C++ /GIT/haiku/generated.x86gcc2/objects/haiku_host/x86_gcc2/release/tools/bfs_shell/BPlusTree.o 
In file included from /GIT/haiku/src/add-ons/kernel/file_systems/bfs/BPlusTree.cpp:15:
/GIT/haiku/headers/private/file_systems/QueryParserUtils.h:46: syntax error before `void'
/GIT/haiku/headers/private/file_systems/QueryParserUtils.h:59: syntax error before `static'

gcc -c "/GIT/haiku/src/add-ons/kernel/file_systems/bfs/BPlusTree.cpp" -O1 -Wall -Wno-trigraphs -Wno-ctor-dtor-privacy -Woverloaded-virtual -Wpointer-arith -Wcast-align -Wsign-compare -Wno-multichar -include /GIT/haiku/headers/build/HaikuBuildCompatibility.h -DFS_SHELL -Wno-multichar -fno-rtti -DHAIKU_BUILD_COMPATIBILITY_H -DARCH_x86 -D_NO_INLINE_ASM -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -DHAIKU_HOST_PLATFORM_HAIKU -DHAIKU_PACKAGING_ARCH=\"x86_gcc2\" -I/GIT/haiku/build/user_config_headers -I/GIT/haiku/build/config_headers -I/GIT/haiku/src/tools/bfs_shell -I/GIT/haiku/generated.x86gcc2/objects/common/tools/bfs_shell -I/GIT/haiku/generated.x86gcc2/objects/haiku_host/x86_gcc2/common/tools/bfs_shell -I/GIT/haiku/generated.x86gcc2/objects/haiku/x86_gcc2/common/tools/bfs_shell -I/GIT/haiku/src/add-ons/kernel/file_systems/bfs -I/GIT/haiku/src/tools/fs_shell -I- -I/GIT/haiku/headers/build -I/GIT/haiku/headers/private/shared -I/GIT/haiku/headers/private/storage -I/GIT/haiku/headers/private/fs_shell -I/GIT/haiku/headers/private -I/GIT/haiku/headers/build/host/haiku_host -o "/GIT/haiku/generated.x86gcc2/objects/haiku_host/x86_gcc2/release/tools/bfs_shell/BPlusTree.o" ;

...failed C++ /GIT/haiku/generated.x86gcc2/objects/haiku_host/x86_gcc2/release/tools/bfs_shell/BPlusTree.o ...

BUILD FAILURE:
...failed updating 1 target(s)...
...skipped 5 target(s)...
...updated 7 target(s)

comment:2 by taos, 10 years ago

Component: - GeneralFile Systems/BFS
Owner: changed from nobody to axeld

It seems that bfs changes in hrev47479 are to blame for my problem as I can still build hrev47478 but not hrev47479. Since there are packages for newer revisions in the repositories, I suppose that cross-compiling is not affected.

comment:3 by taos, 10 years ago

Summary: invalid b+tree in checkfsinvalid b+tree in checkfs and build failure on haiku in BPlusTree.cpp

comment:4 by taos, 10 years ago

I was able to build hrev47493 on haiku, so it seems that hrev47491 enabled building without cross-compiling again. Thanks! However, on hrev47492, I still see "invalid b+tree" messages when running checkfs, at least on the nightly upgraded via pkgman (self-built hrev47493 doesn't show these).

Version 0, edited 10 years ago by taos (next)

comment:5 by diver, 10 years ago

Priority: normalhigh

It looks like I also have this problem now:

checkfs /data/
BEOS:APP_SIG (inode = 4389), invalid b+tree
META:url (inode = 483604), invalid b+tree
last_modified (inode = 4422), invalid b+tree
name (inode = 4356), invalid b+tree
size (inode = 4455), invalid b+tree
objects.x86-gcc2-release (inode = 2374537), invalid b+tree
source (inode = 3047546), invalid b+tree
BeIDE_Release_Notes (inode = 3047436), invalid b+tree
haikuports (inode = 1048582), invalid b+tree
utils (inode = 594830), invalid b+tree
js (inode = 1130970), invalid b+tree
riscos (inode = 594677), invalid b+tree
gtk (inode = 594326), invalid b+tree
res (inode = 1128102), invalid b+tree
desktop (inode = 594156), invalid b+tree
cocoa (inode = 592303), invalid b+tree
build-beos-beos (inode = 63644), invalid b+tree
deps (inode = 595065), invalid b+tree
atari (inode = 587531), invalid b+tree
amiga (inode = 525835), invalid b+tree
objects (inode = 594992), invalid b+tree
src (inode = 46018), invalid b+tree
test (inode = 546585), invalid b+tree
elfobjs (inode = 579478), invalid b+tree
objects (inode = 579447), invalid b+tree
readline-6.3 (inode = 3671644), invalid b+tree
objects (inode = 539229), invalid b+tree
test (inode = 56830), invalid b+tree
obj_lo (inode = 56431), invalid b+tree
.libs (inode = 876158), invalid b+tree
tinfo (inode = 876042), invalid b+tree
base (inode = 875947), invalid b+tree
man (inode = 56162), invalid b+tree
.libs (inode = 875881), invalid b+tree
form (inode = 56063), invalid b+tree
man (inode = 1537624), invalid b+tree
ada (inode = 1537541), invalid b+tree
man3 (inode = 3608212), invalid b+tree
src (inode = 875798), invalid b+tree
samples (inode = 875708), invalid b+tree
objects (inode = 875661), invalid b+tree
ncurses-5.9 (inode = 3670893), invalid b+tree
test (inode = 55625), invalid b+tree
obj_lo (inode = 55209), invalid b+tree
.libs (inode = 875298), invalid b+tree
tinfo (inode = 875182), invalid b+tree
base (inode = 875087), invalid b+tree
man (inode = 54972), invalid b+tree
.libs (inode = 875021), invalid b+tree
form (inode = 54841), invalid b+tree
man (inode = 1535458), invalid b+tree
ada (inode = 1535375), invalid b+tree
man3 (inode = 3146757), invalid b+tree
x (inode = 3147925), invalid b+tree
w (inode = 3147975), invalid b+tree
v (inode = 3147749), invalid b+tree
t (inode = 3147842), invalid b+tree
s (inode = 3147849), invalid b+tree
p (inode = 3147739), invalid b+tree
n (inode = 3147835), invalid b+tree
m (inode = 3147894), invalid b+tree
i (inode = 3147803), invalid b+tree
h (inode = 3147900), invalid b+tree
d (inode = 3147724), invalid b+tree
c (inode = 3147986), invalid b+tree
a (inode = 3147758), invalid b+tree
src (inode = 874938), invalid b+tree
samples (inode = 530988), invalid b+tree
objects (inode = 874612), invalid b+tree
tests (inode = 54368), invalid b+tree
libltdl (inode = 54296), invalid b+tree
objects (inode = 874342), invalid b+tree
tests (inode = 54122), invalid b+tree
objects (inode = 874105), invalid b+tree
tests (inode = 2555940), invalid b+tree
packages (inode = 53967), invalid b+tree
testsuite (inode = 1325404), invalid b+tree
po (inode = 1324940), invalid b+tree
intl (inode = 1280889), invalid b+tree
config (inode = 1254101), invalid b+tree
kmk (inode = 598928), invalid b+tree
kash (inode = 598776), invalid b+tree
ash (inode = 596520), invalid b+tree
    22700 nodes processed

At this point I interrupted checkfs, fearing that it might corrupt my partition.

comment:6 by taos, 10 years ago

Small update (hrev47611): I formatted one of my sd cards. The newly formatted partition doesn't show "invalid b+tree" with checkfs - as long as there is no data. As soon as I copy any files and directories I see the same errors as before.

comment:7 by taos, 10 years ago

Summary: invalid b+tree in checkfs and build failure on haiku in BPlusTree.cppinvalid b+tree with checkfs

comment:8 by ttcoder, 10 years ago

Cc: degea@… added

Happens to me too (syslog and checkfs results) after upgrading from 47395 to 47896, on an Intel core2 laptop.

On my desktop running 47972 I get the checkfs part, <strike>but not the syslog clutter, for some reason.</strike>

Update: there it goes.. Seems the syslog stays "clean" for a few minutes after boot-up, then as I start browsing the web ..etc it starts being spammed indeed:

KERN: inode 4680: node 4096 key 5 larger than it should!
KERN: inode 6894: node 12288 key 8 larger than it should!
KERN: inode 6894: node 13312 key 5 larger than it should!
KERN: inode 6894: node 14336 key 6 larger than it should!
KERN: inode 6894: node 15360 key 6 larger than it should!
KERN: inode 6894: node 31744 key 8 larger than it should!
KERN: inode 6894: node 4096 key 8 larger than it should!
KERN: inode 6894: node 28672 key 10 larger than it should!

Last edited 10 years ago by ttcoder (previous) (diff)

comment:9 by mmlr, 10 years ago

Resolution: fixed
Status: newclosed

Fixed in hrev48059. Although it looked scary, it was really just a harmless false positive.

Note: See TracTickets for help on using tickets.