mirror of
https://github.com/freebsd/freebsd-src
synced 2024-11-05 18:22:52 +00:00
e50342e665
DIR I=64512 CONNECTED. PARENT WAS I=4032 fsck: cannot find inode 995904 fsdb found the inodes with no problem: fsdb (inum: 64512)> inode 995904 current inode: directory I=995904 MODE=40777 SIZE=512 MTIME=Feb 14 15:27:07 2000 [0 nsec] CTIME=Feb 14 15:27:07 2000 [0 nsec] ATIME=Feb 24 10:31:58 2000 [0 nsec] OWNER=nobody GRP=nobody LINKCNT=4 FLAGS=0 BLKCNT=2 GEN=38a41386 Direct blocks: 8094568 0 0 0 0 0 0 0 0 0 0 0 Indirect blocks: 0 0 0 The problem turns out to be a program logic error in fsck. It stores directory inodes internally in hash lists, using the number of directories to form the hash key: inpp = &inphead[inumber % numdirs]; Elsewhere, however, it increments numdirs when it finds unattached directories. I've made the following fix, which solved the problem in the case in hand. Submitted by: Greg Lehey <grog@lemis.com> Reviewed by: Matthew Dillon <dillon@apollo.backplane.com> Approved by: Kirk McKusick <mckusick@mckusick.com> |
||
---|---|---|
.. | ||
SMM.doc | ||
dir.c | ||
fsck.8 | ||
fsck.h | ||
inode.c | ||
main.c | ||
Makefile | ||
pass1.c | ||
pass1b.c | ||
pass2.c | ||
pass3.c | ||
pass4.c | ||
pass5.c | ||
preen.c | ||
setup.c | ||
utilities.c |