tech-embed archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Tests of mdsetimage -s



On Fri, 1 Apr 2005 13:01:50 +0200
Jukka Salmi <jukka%salmi.ch@localhost> wrote:

> 
> BTW, I don't understand what the -s options to mdsetimage means. Where
> does it exactly write the size to? And what is this good for? Maybe it's
> needed in the case the image is larger than the md root?
> 

OK, I made some testing. 
Compiling kernel with MEMORY_DISK_ROOT_SIZE=100000 gives me kernel 51M of size.
Kernel with MEMORY_DISK_ROOT_SIZE=10000 is 6.9M of size.

Seems like the kernel reserves space for the ramdisk.

Now:
# makefs -s 11m custom.img image
# mdsetimage -v -s netbsd custom.img
got symbols from netbsd
mapped netbsd
mdsetimage: fs image (11534336 bytes) too big for buffer (5120000 bytes)

Looks like -s cannot dynamically change the value of MEMORY_DISK_ROOT_SIZE.
If the image is bigger than reserved space, it will get rejected.
I suppose it tells kernel the size of your image if it's smaller than the 
reserved kernel space.

man mdsetimage 
     If the -s flags is given, mdsetimage will write back the actual disk
     image size back into kernel.


Please correct me if I am wrong.


-- 

Regards,
M. Jessa
http://www.yazzy.org




Home | Main Index | Thread Index | Old Index