A RAM disk is just another block device, except that the buffers are never written to a real device, so the data exists only in RAM. The standard kernel comes with 16 RAM disk devices. Initially no memory is allocated to a RAM disk, but buffers will be added dynamically as data is written to it. The maximum size of a RAM disk is 4MB by default and can be modified at boot time with the ramdisk_size command line option. In LILO you could add the following command to the configuration file to double the size:
append ramdisk_size=8192Note that this specifies a maximum size, smaller RAM disks take less space.
See the kernel source file drivers/block/rd.c how the RAM disk is initialized. There are three possibilities:
mke2fs /dev/ram2 2880 mount /dev/ram2 /mnt