Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 30 Apr 2005 08:28:07 +0200
From:      Uwe Doering <gemini@geminix.org>
To:        freebsd-stable@FreeBSD.ORG, tssajo@hotmail.com
Subject:   Re: kernel: swap_pager: indefinite wait buffer - on 5.3-RELEASE-p5
Message-ID:  <42732577.9020100@geminix.org>
In-Reply-To: <200504291213.j3TCDPnk066793@lurza.secnetix.de>
References:  <200504291213.j3TCDPnk066793@lurza.secnetix.de>

next in thread | previous in thread | raw e-mail | index | archive | help
Oliver Fromme wrote:
> Zoltan Frombach <tssajo@hotmail.com> wrote:
>  > Apr 29 02:10:14 www kernel: swap_pager: indefinite wait buffer: device: 
>  > ad0s1a, blkno: 328636, size: 8192
>  > Apr 29 02:10:24 www kernel: swap_pager: indefinite wait buffer: device: 
>  > ad0s1e, blkno: 329842, size: 4096
>  > [...]
> 
> The error message indicates that there was an I/O error
> accessing the swap area on your disk.  Usually that's an
> indication for a hardware failure, e.g. a dying disk.
> 
>  > I happen to have an identical hard drive around here, unused. If I hook it 
>  > up as a slave (IDE) drive, is there a way I can mirror the dying drive to 
>  > the spare one (with all partitions, etc, intact)?
> 
> If they're really identical (i.e. the same size and same
> geometry), then you can use dd(1) for duplication, like
> this:
> 
> # dd if=/dev/ad0 of=/dev/ad1 bs=64k conv=noerror,sync
> 
> The "noerror,sync" part is important so the dd command will
> not stop when it hits any bad spots on the source drive and
> instead will fill the blocks with zeroes on the destination
> drive.  Since it's only the swap partition, you shouldn't
> lose any data.

I would like to point out that the conclusion you're drawing in the last 
sentence is invalid IMHO.  "indefinite wait buffer" messages at 
apparently random block numbers just indicate that the pager was unable 
to access the swap area (in its entirety!) when it wanted to.  It means 
that the disk drive was either dead at that point in time or busy trying 
to deal with a bad sector.

This sector could have been anywhere on the disk.  It just kept the disk 
drive busy for long enough that the pager started to complain.  Since 
the swap area is usually just a minor portion of the disk it is 
therefore much more likely that the bad sector is located in a 
filesystem.  So if you copy the disk and ignore i/o errors in this 
situation you _do_ run a very real risk of losing data!  Unfortunately 
you can't do much about it but you should at least be aware of it.

    Uwe
-- 
Uwe Doering         |  EscapeBox - Managed On-Demand UNIX Servers
gemini@geminix.org  |  http://www.escapebox.net



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