Create-rootfs

From VNUML-WIKI
Revision as of 21:29, 18 March 2007 by Fgalan (talk | contribs)
Jump to: navigation, search

How to create a VNUML-compatible root filesystem from scratch using debootstrap

Introduction

Virtual machines created by VNUML need a root filesystem (root_fs) to work. The VNUML root_fs are basicly UML filesystem, slightly tunned to work with the tool (for example, special mount point has to be created). That modifications/requirements are described in one section in the User Manual.

Until know the VNUML Project has provided a root_fs_tutorial filesystem for download (current version at time of writting this is 0.4.1). However, mantaining the root_fs_tutorial is costly because there are a lot of details to check when a new version is released. In addition, the bunch of packages included in root_fs_tutorial hardly satisfy all the user needs (some won't find the particular packages they want and many others will have a lot of unnecessary stuff they don't need).

Therefore, a more practical approach is to provide simple and easy-to-implement procedure that allow user to produce it's own VNUML-compatible filesystems, with the size and software package they want. This goal is addressed by the present document.

The procedure described in this document has been developed by Michael Monreal, with minor additions and fix by Fermín Galán.

Procedure

The procedure will create a Debian-based VNUML-compatible root_fs. We asume you are using Debian (or maybe other Debian-based distribution) to generate the root_fs. Before starting ask yourself:

  • The size of the desired root_fs (we'll consider 800Mb here)
  • Which Debian packages you want to include (we'll use here a list based on the contents of root_fs_tutorial)

Let's go (I'll asume you are logged as root; otherwise execute privileged commands using sudo):

  1. Create an ext3 filesystem (800MB). Change the destination directory (/usr/share/vnuml/filessystems) if it is not suitable for you.
  2. dd if=/dev/zero of=/usr/share/vnuml/filesystems/debian.ext3 bs=1024k seek=800 count=0