kernel: swap_pager: indefinite wait buffer - on 5.3-RELEASE-p5

Uwe Doering gemini at
Fri Apr 29 23:28:16 PDT 2005

Oliver Fromme wrote:
> Zoltan Frombach <tssajo at> 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 Doering         |  EscapeBox - Managed On-Demand UNIX Servers
gemini at  |

More information about the freebsd-stable mailing list