How To Install a Minimal Ubuntu Server OS on a VirtualBox Instance
written on Saturday, March 27, 2010
Most people are not aware that you can install a baseline Ubuntu system in under 1GB of space. This makes it great for a headless system, such as an embedded mini-ITX board. Even for a desktop, you might want to start with a bare-minimum Ubuntu package set and then customize the rest. All this can be accomplished very quickly, and easily using a few tips. For this post, I'll explain how to use Ubuntu Karmic 9.10 and VirtualBox to create a small virtual Linux server.
To start off this tutorial, make sure you have a Ubuntu (or similar) desktop system with VirtualBox configured and installed correctly.
- Download one of the Ubuntu mini.iso Installer Image.
- [Optional] Configure apt-cacher-ng on your local system. This will speed up the installation process, if you want to start over at any point.
- Create a new VirtualBox machine with the following configuration:
- Hard Disk: 1GB or larger
- Base memory: 256MB to 512MB
- Network Mode: Bridged Adapter
- After creating the system, assign the mini.iso image you downloaded as the media for the emulated CD drive.
- Now start the virtual machine. It should boot the Ubuntu install boot prompt. Select the Command Line option to continue to the installer.
- From the installer, continue following the default options:
- Set the system host name.
- Choose your local Ubuntu mirror.
- [Optional] Set HTTP Proxy (when running apt-cacher-ng): http://installer-host:3142/
- When you reach the disk partition step, use the following options:
- Choose the Manual method.
- Verify there is a single root partition filling the entire virtual disk.
- Optionally, choose to enable noatime on the partitions.
- Ignore any warnings about missing swap space, and confirm you wish to erase the entire device. After this the base system will continue to install.
- The software package will finish and the grub boot loader should install. Before restarting the system, make sure to unmount the ISO file in the virtual drive.
From this point forward, the virtual machine can now boot and allow you to log in as the user you configured during the install process.