Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 22 Aug 2008 10:29:05 +0200 (CEST)
From:      Oliver Fromme <olli@lurza.secnetix.de>
To:        freebsd-questions@FreeBSD.ORG, Polytropon <freebsd@edvax.de>
Subject:   Re: Again: fsck_ffs memory requirements
Message-ID:  <200808220829.m7M8T5Is048761@lurza.secnetix.de>
In-Reply-To: <20080822021926.d2d9ee0f.freebsd@edvax.de>

next in thread | previous in thread | raw e-mail | index | archive | help
Polytropon <freebsd@edvax.de> wrote:
 > Allthough fsck_ffs 5 does seem to be able to calloc() the needed
 > memory, it fails with the same message as fsck_ffs 7:
 > 
 >         fsck_ffs: bad inode number 306176 to nextinode
 > 
 > Don't know what to do next. I may gather all information I
 > have, write al little "story" and bring this topic up here
 > next week. Maybe someone has better ideas than me.

Unfortunately fsck isn't able to cope with any arbitrary
level of damage.  If certain kinds of unexpected problems
occur, it throws in the towel.  In theory it might be
possible to deal with your particular problem, but nobody
has implemented it in fsck yet.

Someone with intimate knowledge of UFS2 might be able to
help you, possibly using fsdb(8), but this requires direct
access to the file system image and is beyond what can be
done through a mailing list.  Usually such services cost
money.  (The price to pay for not having backups.)

You might also have success using one of the various
recovery or forensic toolkits out there, e.g. sleuthkit
(it's in ports).

 > > PS:  Better make good backups next time.
 > 
 > More precise: Better make _at least any_ backups. :-) More than
 > 5 years without any (!) problem with FreeBSD and now this stupid
 > problem... :-(

Well, there's nothing an OS can do against hardware failure
(such as a crash because of power loss).  Such failures can
cause arbitrary damage to mass storage, especially if the
power failure happens in the middle of writing a track, and
especially when using "consumer grade" disks.

Disks are cheap these days.  Cheaper than your valuable
data.  So, a simple way to make backups is to buy an
external disk (USB2, Firewire/IEEE1394, eSATA, or even
a hot-swappable PATA drive tray), sync your system to it
once per week, and store it in a safe place.

If you're paranoid, then use two such disks alternating,
so you have one good (safe, i.e. disconnected) copy at
every point in time.  If you're even more paranoid, store
multiple backup disks in different places (e.g. one at
home at one at your office, or at a friend's place, or
even in a safe deposit box at your bank company), so you
still have a good backup if your house burns down or an
alien space ship crashes on it.

Best regards
   Oliver

-- 
Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing b. M.
Handelsregister: Registergericht Muenchen, HRA 74606,  Geschäftsfuehrung:
secnetix Verwaltungsgesellsch. mbH, Handelsregister: Registergericht Mün-
chen, HRB 125758,  Geschäftsführer: Maik Bachmann, Olaf Erb, Ralf Gebhart

FreeBSD-Dienstleistungen, -Produkte und mehr:  http://www.secnetix.de/bsd

Python is executable pseudocode.  Perl is executable line noise.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200808220829.m7M8T5Is048761>