Subject: Re: My experience with the _RCs so far
To: None <port-i386@NetBSD.org>
From: Alan Barrett <apb@cequrux.com>
List: port-i386
Date: 10/07/2004 09:18:41
On Wed, 06 Oct 2004, Julio M. Merino Vidal wrote:
> You can write a small program that malloc(2)s a big amount of RAM (dunno
> how many, but 256MB work for me) and touches all the bits in it.  After
> running it, your umass device should work.

Here's my "memdefrag" script.  I imagine that it would still work if I
made some of the numbers smaller, but I have made no attempt to tune it.

--apb (Alan Barrett)

#!/bin/sh
# memdefrag: attempt to de-fragment memory before attaching a umass device
for i in 1 2 3 4 5 6 7 8 9 10 ; do
  dd if=/dev/zero of=/dev/null bs=16m count=100 &
done
wait