1.\" ---------------------------------------------------------------------------- 2.\" "THE BEER-WARE LICENSE" (Revision 42): 3.\" <phk@FreeBSD.ORG> wrote this file. As long as you retain this notice you 4.\" can do whatever you want with this stuff. If we meet some day, and you think 5.\" this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp 6.\" ---------------------------------------------------------------------------- 7.\" 8.\" $FreeBSD$ 9.\" 10.Dd March 9, 2001 11.Dt MD 4 12.Os 13.Sh NAME 14.Nm md 15.Nd memory disk 16.Sh SYNOPSIS 17.Cd device md 18.Sh DESCRIPTION 19The 20.Nm 21driver provides support for four kinds of memory backed virtual disks: 22.Bl -tag -width preload 23.It Cm malloc 24Backing store is allocated using 25.Xr malloc 9 . 26Only one malloc-bucket is used, which means that all 27.Nm 28devices with 29.Cm malloc 30backing must share the malloc-per-bucket-quota. 31The exact size of this quota varies, in particular with amount of RAM in the 32system. 33The exact value can be determined with 34.Xr vmstat 8 . 35.It Cm preload 36A file loaded by 37.Xr loader 8 38with type 39.Sq md_image 40is used for backing store. 41For backwards compatibility the type 42.Sq mfs_root 43is also recognized. 44If the kernel is created with option 45.Dv MD_ROOT 46the first preloaded image found will become the root filesystem. 47.It Cm vnode 48A regular file is used as backing store. 49This allows for mounting ISO images without the tedious 50detour over actual physical media. 51.It Cm swap 52Backing store is allocated from swap space. 53.El 54.Pp 55For more information, please see 56.Xr mdconfig 8 . 57.Sh SEE ALSO 58.Xr disklabel 5 , 59.Xr disklabel 8 , 60.Xr fdisk 8 , 61.Xr loader 8 , 62.Xr mdconfig 8 , 63.Xr newfs 8 , 64.Xr vmstat 8 65.Sh HISTORY 66The 67.Nm 68driver first appeared in 69.Fx 4.0 70as a cleaner replacement 71for the MFS functionality previously used in 72.Tn PicoBSD 73and in the 74.Fx 75installation process. 76.Pp 77The 78.Nm 79driver did a hostile takeover of the 80.Xr vn 4 81driver in 82.Fx 5.0 . 83.Sh AUTHORS 84The 85.Nm 86driver was written by 87.An Poul-Henning Kamp 88.Aq phk@FreeBSD.org . 89