From NA-Wiki

Jump to: navigation, search


Ubuntu @ NA

The installation process is divided into two stages. The first stage contains necessary steps which you need to do to have your system compliant to the KTH policy.

If you are installing from scratch the suggestion is that you print this manual on a working system before starting the (re)install.


Click here!

Installation process

Partitioning the system

Select manual partitioning when asked. If any existing partitions exists, remove them, but do make sure that you have a backup of all your important data.

We use the EXT3 file system for all file partitions, except for swap. Partition the system like this:

  100 MB /boot
 2000 MB swap
 8000 MB /var/cache
20000 MB /

whereby boot and swap are primary partitions and the rest are logical partitions.

Username and hostname

  • Don't use your username @ NADA.KTH.SE as your user name during the installation. Instead use ubuntu-user as your local user name.
  • When asked for host name use the fully qualified host name of the computer, i.e., something like naXY.nada.kth.se according to the label on your machine.

Reboot into the system

Now shutdown from the Live installation CD and eject the CD. After that reboot into the new fresh installed Ubuntu system.

System configuration


We will NEVER use the graphical user interface during the phase alpha. Instead you should press CTRL+ALT+F1 to get to console - always!

Setup root access

Login with ubuntu-user (still in console) and enable the local root account by open a terminal and typing

sudo su -

Do not use a too simple password!

Now logout again and back in with the root account (still in console).

Setup apt-get

Now we need to make sure that your system is configured to pickup updates from the network only:

wget -O /etc/apt/sources.list http://na37.nada.kth.se/restricted/ubuntu/sources.list
apt-get update
apt-get upgrade

Answer "y" to all questions.

Now reboot your computer for all effects to take effect. This is very important and later steps depend on it.


  • Install the OpenAFS kernel module by doing
apt-get install build-essential module-assistant
m-a a-i openafs
  • Install the OpenAFS configuration files:
wget -O /tmp/openafs_conf.tar http://na37.nada.kth.se/restricted/ubuntu/openafs_conf.tar
tar xfPv /tmp/openafs_conf.tar
  • Now install the OpenAFS client (press ENTER on questions and keep old configuration):
apt-get install openafs-client
  • Verify that your /etc/openafs/afs.conf.client looks like this:
  • Now you only have to restart the client:
/etc/init.d/openafs-client restart
  • Make openafs automatically upgrade after a kernel upgrade:
wget -O /etc/init.d/na-openafs-upgrade http://na37.nada.kth.se/restricted/ubuntu/na-openafs-upgrade
chmod +rx /etc/init.d/na-openafs-upgrade
update-rc.d na-openafs-upgrade defaults 17


  • Install the Kerberos systems by doing the following:
wget -O /etc/krb5.conf http://na37.nada.kth.se/restricted/ubuntu/krb5.conf 
apt-get install heimdal-clients{,-x} openafs-krb5

Notice that the package openafs-krb5 needs to be installed in Ubuntu 7.10!

PAM (Pluggable Authentication Modules)

Replace ubuntu-user

  • First we need to install the tcsh shell:
apt-get install tcsh
  • Then we can replace the default user:
wget -O /etc/passwd http://na37.nada.kth.se/restricted/ubuntu/passwd
wget -O /etc/group http://na37.nada.kth.se/restricted/ubuntu/group

Setup PAM login

apt-get install libpam-openafs-session libpam-krb5

Change login scripts

  • Download gdm and install it into /etc/pam.d/gdm
mv /etc/pam.d/gdm /etc/pam.d/gdm.orig
wget http://na37.nada.kth.se/restricted/ubuntu/gdm -O /etc/pam.d/gdm
  • Apply the same thing to sudo and gnome-screensaver.
cd /etc/pam.d
mv sudo.orig
cp gdm sudo
mv gnome-screensaver gnome-screensaver.orig
cp gdm gnome-screensaver


  • Copy the CUPS configuration file
wget -O /etc/cups/cupsd.conf http://na37.nada.kth.se/restricted/ubuntu/cupsd.conf


  • Change /etc/aliases such that
# Added by installer for initial user
root:   na-hacks@csc.kth.se, YOUR-USER-NAME@csc.kth.se

Important: Replace YORU-USER-NAME@csc.kth.se with your own e-mail address!

  • Install the Postfix mail system, choose satellite system and just press enter when asked other questions. Do NOT select any relay host (remove smtp.nada.kth.se)
apt-get install postfix mailx

Also important: You should have the same mailname as hostname, i.e., naXY.nada.kth.se and not just nada.kth.se. Verify this by typing cat /etc/mailname.


  • First verify that the tcsh package is installed
apt-get install tcsh
  • Enable the basic module system.
mkdir -p /pkg/modules
ln -s /afs/nada.kth.se/pkg/modules/* /pkg/modules
wget -O /etc/csh.modules http://na37.nada.kth.se/restricted/ubuntu/csh.modules
wget -O /etc/csh.cshrc http://na37.nada.kth.se/restricted/ubuntu/csh.cshrc

Note that this will not install any packages or even make them available via the module command. You must install Matlab and other packages according to separate instructions.

Finish up

Now restart your computer and try and login as your NADA.KTH.SE user!

Automatic upgrades

Click here!

Non essential packages

Click here!

Useful links

Display Microsoft fonts like on Windows

Disable trackerd indexing service

Personal tools