disk problem: suggestion on how to handle...

Polytropon freebsd at edvax.de
Tue Apr 26 08:00:40 UTC 2011


On Tue, 26 Apr 2011 07:08:21 +0200, Denis Fortin <fortin at acm.org> wrote:
> Good morning,
> 
> I have a small server with an SSD drive in it that is having some problems.
> 
> Notably, dmesg has been repeatedly reporting the following error message:
> 
> 	g_vfs_done():ad0s1a[READ(offset=-574217714356717568, length=16384)]error = 5
> 
> I realize that the best course of action is to replace the
> disk and restore from a backup, but this isn't really an
> option immediately.

You should replace it on the long run. :-)



> So, is there a way to "mark the inode bad" and then launch an
> fsck ?  How can I turn "offset=-574217714356717568" into a
> usable piece of information?

You can use the tool "badsect" (from the base system) to
mark a sector as bad, as inodes are "dynamically allocated"
and do not "hard-wiredly" correspond to actual disk locations
per se. A tool for clearing inode information is "clri" which
should be used on unmounted partitions whenever possible.

Files like /usr/src/sys/bio.h and /usr/src/sys/geom/geom_vfs.c
give some hints about what the numbers are refering to. Sadly
I'm not a system programmer, so I can't be more specific.


-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...


More information about the freebsd-questions mailing list