Setup Debian

From IrisFrame

Jump to: navigation, search

I'm considering Debian as the base distribution for several reason:

  • somewhat small footprint
  • somewhat low hardware requirement
  • has a huge library of packages available
  • very stable
  • the reference for the majority of the linux distributions in the wild (Ubuntu being the most famous)

The official documentation claims that 48MB is the bare minimum to install Debian, but I've managed to install it on a virtual machine with 32MB of RAM and got my software to run in 1024x768x16 with 10MB to spare. DSL seem to be able to do better but if the laptop can get Debian to run, it's better to use it as you will end up with a more maintainable system.

On the other hand, the system you will end up with will take much more space. So unless you have at less than 32MB of RAM or a hard drive smaller than 1GB, you should stay with DSL.

Business Card installer with 32MB of RAM

I did this install on a virtual machine with 32MB of RAM, 1GB of disk and 4MB of Video RAM. Although the rest of the hardware (CPU speed, Video, ACPI support, PCMCIA ...) should be easier to handle it does a good job of constraining the main factors (RAM and disk) for most of our needs.

The Business card CD is small (40MB) and will let you fetch the packages from the network. The installer detected my low memory and switched to a 'low memory mode'. It hen asked me to select the modules I needed for the installer. I selected the packages for EXT3, and the network. We don't need IPv6, raid support or any of the fancier filesystems.


After this my tiny HD is using 343M out of 857M (43%).

With the busines card version of the CD, start the installer with no option. The installer will notify you of 'Entering low memory mode', select 'continue'.

  • Choose you country settings
  • 'Load installer components from CD':
 * here you only want some of the component to save memory during the install
 * ext3-modules
 * network-console (much nicer install)
 * nic-modules
 * partman-ext3
 * you might have to install more than that
  • if all goes well dhcp should work automatically, select a host name and a domain
  • continue remotely. You can pick a weak password, it's only for the time of installation.
  • ssh from you regular machine to the ip (most likely 10.211.55.5 is not *your* ip)
  • Start menu
  • Partition
 * set the first partition to twice your RAM (here 64MB)
 * use the remaining space for your root /
  • setup users and passwords
  • Installing the base system, it takes a few minutes to install.
  • popularity contest
  • Software selection: you do *not* want the 'Standard system', we will pick what we need by hand.
  • install is done. The system seem to use less than 10MB, and 291MB out of the 881MB available (about twice as DSL ... and we don't have all we need yet).

The first thing I do is to install aptitude to manage the packages:

apt-get install aptitude

X11 (95MB):

apt-get install xserver-xorg

I recommend that you 'remove' all the video drivers except the one you need once you have your X11 working:

apt-get remove xserver-xorg-video-all
apt-get install xserver-xorg-video-vesa xserver-xorg-video-fbdev

Framebuffer, make sure you add this to the kernel boot options:

vga=791

791 is the 1024x768x16 video mode, you should set it to the best video mode available to your laptop.

Mouse support: If we are not using X11, we need direct access to the mouse (mostly so pygame can run).

chgrp plugdev /dev/input/*

Inittab to save some memory:

nano /etc/inittab
# comment these lines out:
# 3:23:respawn:/sbin/getty 38400 tty3
# 4:23:respawn:/sbin/getty 38400 tty4
# 5:23:respawn:/sbin/getty 38400 tty5
# 6:23:respawn:/sbin/getty 38400 tty6

Alsa (3.6MB):

apt-get install alsa-base
alsaconf

You can save memory with the following 'tricks'

  • replace bash with dash (replace /bin/bash with /bin/dash in /etc/passwd)
apt-get install dash
nano /etc/passwd
  • remove the man pages (3MB):
apt-get remove info man-db manpage


BootSplash (need to investigate):

apt-get install bootsplash

You can remove the following packages (saving 24.5MB on disk):

 # doc (remove everything)
 doc-debian
 doc-linux-text
 info
 man-db
 manpages
 # editors
 vim-common
 vim-tiny
 # interpreters
 m4
 # mail
 exim4
 exim4-base
 exim4-config
 mutt
 procmail
 # net
 ftp
 # oldlibs
 ##libpci2
 libsasl2
 # shells
 tcsh
 # text
 iamerican
 ibritish
 ispell
 dictionaries-common
 wamerican
Personal tools