Again: fsck_ffs memory requirements
Polytropon
freebsd at edvax.de
Thu Aug 21 15:15:12 UTC 2008
Hi again!
I had problems running fsck_ffs of FreeBSD 5. In my particular
problem, version 5 seemed to help me more than version 7, which
stopped with this:
fsck_ffs: bad inode number 306176 to nextinode
Version 5 didn't seem to have this problem, but it did complain:
fsck_ffs: cannot alloc 1073796864 bytes for inoinfo
So I asked for help and was adviced to enable swap space before
running fsck_ffs in SUM. My main problem seemed to be that I hadn't
enough RAM (512 + 256 MB SRD-SDRAM), exactly 1 GB seemed to be
required.
In the recovery setting, ad0 is a FreeBSD 5 installation and ad2
is a FreeBSD 7 installation with a /home partition holding a dd
image of the defective partition (which's original is on a harddisk
on the shelf for security reasons).
I did the following after successful system startup in SUM:
# swapon /dev/ad2s1b
# swapctl -l
Device: 1024-blocks Used:
/dev/ad2s1b 2097152 0
# mount /dev/ad2s1g /mnt
# mdconfig -a -u 0 -t vnode -f /mnt/poly/rescue/ad1s1f.dd
# fsck_ffs -yf /dev/md0
** /dev/md0
** Last Mounted on
** Phase 1 - Check Blocks and Sizes
1035979 BAD I=259127
UNEXPECTED SOFT UPDATE INCONSISTENCY
[...]
9187201950452580480 BAD I=262821
UNEXPECTED SOFT UPDATE INCONSISTENCY
9114861777597661055 BAD I=262821
UNEXPECTED SOFT UPDATE INCONSISTENCY
EXCESSIVE BAD BLKS I=262821
CONTINUE? yes
1779904 DUP I=262822
UNEXPECTED SOFT UPDATE INCONSISTENCY
1779905 DUP I=262822
UNEXPECTED SOFT UPDATE INCONSISTENCY
[...]
4007775 DUP I=262845
UNEXPECTED SOFT UPDATE INCONSISTENCY
fsck_ffs: cannot alloc 1073796864 bytes for inoinfo
#
So I examined /usr/src/sbin/fsck_ffs/pass1.c and found out
that a calloc() call caused the error; 1 GB was needed, but
2 GB were present in swap. Not enough?
Any suggestions what I could do to help fsck_ffs calloc()ing
the needed memory?
--
Polytropon
>From Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...
More information about the freebsd-questions
mailing list