Mounting Additional Ramdisks mini-HowTo

Adam Dosch

March 6, 2003

A quick and easy way to add additional file system space for storage on Fd Linux v3.x-x

1.  Overview

2.  Usage and Examples












Here is a brief overview of how to use other parts of your reserved memory on your computer and covert it over to additional file system space for the Fd Linux operating system.

Keep in mind that several tools, such as mke2fs and mount, will be needed to add additional space.  These tools are already documented in other HowTo's presented on this site.  I would recommend looking those over first before attempting this particular action.

To view the mke2fs mini-HowTo, please see the mke2fs mini-HowTo.

To view the syntax and command structure for `mount`, view the Floppy Disk Mounting mini-HowTo.


To be able to mount additional pieces of allocated RAM for expansion on the existing file system, you have to be aware of what ramdisk are already mounted.  To check existing mounts, simply type:

(root->fdlinux)% mount
rootfs on / type rootfs (rw)
/dev/ram0 on / type ext2 (rw)
/proc on /proc type proc (rw)

As you can see, just by typing `mount` you can see which mounts currently exist.  Note the mounted device, /dev/ram0.  This tells us that out of our allocated ramdisk devices, that the first one, ram0, is currently mounted as the root of our file system.  This means the next available ramdisk to use, or mount, would be /dev/ram1.

Now that we know what our next available ramdisk is, we can now convert it over to a second extended file system by typing:

(root->fdlinux)% mke2fs -m 0 /dev/ram1

Once our file system is created, we need to set up a place to "mount", or open up, the ramdisk for use by the operating system.  To do this, we need to simply make a directory somewhere in the current file system.  Typically, all block mounts are mounted within the /mnt directory, but in our purpose to make these additional ramdisks "appear" to extend, or make the current file system larger, we could create a directory anywhere we wanted that would correlate with what we wanted to put there.  For this example, lets say we want to mount an additional ramdisk to store some log files that are piling up.  We would simply type:

(root->fdlinux)% mkdir /var/log/backup

Now that our mount point is set, we can now go on to mount the ramdisk that we formatted with the second extended filesystem (ext2).  To accomplish this, we type:

(root->fdlinux)% mount -t ext2 /dev/ram1 /var/log/backup

And you're done!  Now you've got an extra 4096kb worth of storage space to store anything you want; in this case, we were storing backed up log files, but you can do anything you want with the space you create.



If you feel that anything should be added to this mini-HowTo, please feel free to send me an Inquiry Ticket about it!