Re: ramdisk size clarification

From: Mike Castle (dalgoda@ix.netcom.com)
Date: Mon Dec 17 2001 - 16:14:29 EST


On Mon, Dec 17, 2001 at 08:41:32PM +0000, Padraig Brady wrote:
> and also there is no upper limit on the amount of RAM used,
> so the following will kill your system (well it did for me):
> dd if=/dev/zero of=/dev/ram0

Bug in recent 2.4.*. It *should* stop. One line patch has been
posted to the linux-kernel list a couple of times. Check the archive.
It's probably in the recent pre-release kernels as well.

As a work around, try the following:

count=`blockdev --getsize /dev/ram0`
bsize=`blockdev --getss /dev/ram0`
dd if=/dev/zero of=/dev/ram0 count=${count} bs=${bsize}

-- 
     Mike Castle      dalgoda@ix.netcom.com      www.netcom.com/~dalgoda/
    We are all of us living in the shadow of Manhattan.  -- Watchmen
fatal ("You are in a maze of twisty compiler features, all different"); -- gcc
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sun Dec 23 2001 - 21:00:14 EST