From owner-freebsd-questions@FreeBSD.ORG Tue Aug 19 22:26:50 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D90701065674 for ; Tue, 19 Aug 2008 22:26:50 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mx01.qsc.de (mx01.qsc.de [213.148.129.14]) by mx1.freebsd.org (Postfix) with ESMTP id 694CF8FC19 for ; Tue, 19 Aug 2008 22:26:50 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r55.edvax.de (port-92-195-135-36.dynamic.qsc.de [92.195.135.36]) by mx01.qsc.de (Postfix) with ESMTP id 45167509F8; Wed, 20 Aug 2008 00:26:48 +0200 (CEST) Received: from r55.edvax.de (localhost [127.0.0.1]) by r55.edvax.de (8.14.2/8.14.2) with SMTP id m7JMQmwC004413; Wed, 20 Aug 2008 00:26:48 +0200 (CEST) (envelope-from freebsd@edvax.de) Date: Wed, 20 Aug 2008 00:26:47 +0200 From: Polytropon To: "freebsd-questions@freebsd.org" Message-Id: <20080820002647.71fec5e4.freebsd@edvax.de> In-Reply-To: <44hc9g269t.fsf@be-well.ilk.org> References: <20080819182731.f7ffe437.freebsd@edvax.de> <44hc9g269t.fsf@be-well.ilk.org> Organization: EDVAX X-Mailer: Sylpheed 2.4.7 (GTK+ 2.12.1; i386-portbld-freebsd7.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: Lowell Gilbert Subject: Re: Memory requirement for fsck_ffs in recovery session X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Polytropon List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Aug 2008 22:26:50 -0000 On Tue, 19 Aug 2008 14:45:18 -0400, Lowell Gilbert wrote: > Polytropon writes: > > I always thought I needed to modify the > > file system so fsck_ffs could do its job, now I think I rather would > > modify fsck_ffs so it would skip these errors I can't see any reason > > for. > > I'm not following your logic, but I suspect you're jumping into > dangerous waters here... I think so, too, but that's the only way I think I can recover at least a part of my files without buying an expensive and "Windows" based recovery program or even sending the harddisk to a recovery service for 50 times the price of a new harddisk. I found out that fsck_ffs version 7 seems to stumble at incorrectly read or processed variables maxino and lastvalidinum. After "removing" these obstacles from the source code fsck seemed to process further, but did not reach the point where collected inode data would be restored into the lost+found/ directory. This is what I do expect. > > Out of curiosity, I booted my system with a done version 5 installation > > harddisk I had extracted from a system some years ago, and guess what? > > fsck_ffs version 5 seemed to do more than version 7 did! This is what I > > get: > > > > fsck_ffs: cannot alloc 1073796864 bytes for inoinfo > > > > My question: My machine has 768 MB RAM (512 + 256 MB SDR-SDRAM) and > > fsck_ffs seems to request 1 GB RAM (1073796864/1024/1024/1024). Is > > it possible to provide this amount of RAM via a harddisk backed RAM > > disk or a swap partition? > > Swap should be fine; the allocation is just a regular calloc(3) call. So I should assert a swap partition big enough; /dev/ad2s1b should be fine for this. > > I think I'll try ffsck_ffs version 6 from a PC-BSD installation that > > must be somewhere around here... > > Not likely to help, but since you aren't working with the original > disk, you don't have much to lose by trying... That's why I'm glad (haha) that dd replicates the error 1:1. Maybe fsck_ffs version 6 behaves differently than 5 or 7. If I gathered more information and did try some more things, I may bring up my most sad problem here again. And: No, I didn't have a backup. :-( -- Polytropon >From Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...