From: Martin Birgmeier on
In article <1164142323.487479.305330(a)m7g2000cwm.googlegroups.com>,
<ohh-ohh_ohhh.ohh(a)hotmail.com> wrote:
>
>Martin Birgmeier skrev:
>> In article <1163948112.437395.322330(a)h48g2000cwc.googlegroups.com>,
>> <ohh-ohh_ohhh.ohh(a)hotmail.com> wrote:
>> >Dear Sirs,
>> >
>> >On boot after a system crash fsck told:
>> >
>> >"Cannot alloc 2177471968 bytes for inoinfo
>> >Automatic filesystem check faild; help!"
>> >
>> >It fails too when run from singleuser mode with "Cannot alloc
>> >2177471968 bytes for inoinfo"
>> >
>> >The FreeBSD partition is 15 GB, and the swap partition is 1 GB, and the
>> >RAM is 512 MB. Should�t that be enough for fsck(even though it claims
>> >it needs 2077 MB)?
>> >
>> >I've tried setting kern.maxdsiz="1580000000"(ca), but it didn't help
>
>> Most likely your super block is corrupt. You can specify an alternate
>> superblock location via the -b flag to fsck_ffs - look at the man page.
>
>There was correctly a superblock backup at 160, as the manpage
>suggested, but sadly it did not help. Error message still the same :
>
>Cannot alloc 2177471968 bytes for inoinfo
>

Hm... There is still a chance that the first backup is also corrupt, being
so close to the beginning of the partition. Try to find another backup:
(example involving my root partition, UFS2)

dd if=/dev/ad0s3a bs=32k | hd | grep '00 00 00 00 19 01 54 19 |'

This yields

0000e550 00 00 00 00 00 00 00 00 00 00 00 00 19 01 54 19 |..............T.|
00010550 00 00 00 00 00 00 00 00 00 00 00 00 19 01 54 19 |..............T.|
00012550 00 00 00 00 00 00 00 00 00 00 00 00 19 01 54 19 |..............T.|
02812550 00 00 00 00 00 00 00 00 00 00 00 00 19 01 54 19 |..............T.|
07812550 00 00 00 00 00 00 00 00 00 00 00 00 19 01 54 19 |..............T.|

Using the Z shell or another suitable hex-capable calculator, we get

% echo $(( ( 0x02812550 - 0x550 ) / 512 ))
82064
% echo $(( ( 0x05012550 - 0x550 ) / 512 ))
163984
% echo $(( ( 0x07812550 - 0x550 ) / 512 ))
245904

for the last three lines, which may be used as the parameter to
the -b option to fsck_ffs.

Regards,

Martin

--
Martin Birgmeier

Vienna
Austria
First  |  Prev  | 
Pages: 1 2
Prev: St9bad_alloc crashes
Next: FreeBSD vmware Winxp