Subject: MEMORY_DISK_DYNAMIC, mdsetimage -s?
To: None <netbsd-help@netbsd.org>
From: Nino Dehne <ndehne@gmail.com>
List: netbsd-help
Date: 06/28/2005 17:14:59
Hi,

what does the MEMORY_DISK_DYNAMIC option do exactly? options(9) says

     options MEMORY_DISK_DYNAMIC
     This options makes the md(4) RAM disk size dynamically sized.

which tells me nothing. I had hoped that I could get rid of explicitly
specifying MEMORY_DISK_ROOT_SIZE, but this doesn't seem to be the case.

Then I thought it works in conjunction with MEMORY_DISK_ROOT_SIZE, so
that I could reserve 64M, embed a 50M image and the resulting kernel
would free the excessive 14M upon booting.

In both cases, the kernel seems to reserve only a very small amount of
space for the ramdisk:

mdsetimage: fs image (45260800 bytes) too big for buffer (91904 bytes)

OK, I thought, maybe _that_ is what mdsetimage -s is for. But it isn't.

Could anyone please tell me what MEMORY_DISK_DYNAMIC and mdsetimage -s
are for exactly? A booted kernel always seems to use the amount given
by MEMORY_DISK_ROOT_SIZE, no matter how big the embedded image actually
was and no matter whether mdsetimage -s was used or not.

Thanks,

ND