Installing IRAF on Ubuntu/debain


= IRAF Setup on Ubuntu/Debian =

This is for beginners who stuck with IRAF installation on their ubuntu. It should work well with all debian packages.

This page describes how to setup IRAF on a 32-bit Ubuntu/Debian machine. (In my case, it was done on an IBM machine with intel MB and pentium 4 processor. For 64-bit platform, you only need to make a minor modification in the commands which is given along with.

Installation of X11IRAF, DS9, Tables, and STSDAS are also included.
It will be easiest if you just copy-paste the instructions one by one.
Please be sure to read and implement the instructions in [[brackets]] as well.

Important:It works well with ubuntu 6.06 dapper and above. For people using ubuntu 5.10 breezy or less, may upgrade it first to 6.06 or above, since 5.10 if apt-get update does not work (or could not do sudo apt-get install tcsh). You can find, ‘How to upgrade from Ubuntu 5 to 6’ here…. The following method was taken from made some minor changes which came in my experience.

You must have super user previlege in order to do the following operations.


sudo apt-get install tcsh


sudo dpkg -i ldso_1.9.11-15_i386.deb


sudo dpkg -i libc5_5.4.46-15_i386.deb


sudo dpkg -i termcap-compat_1.2.3_i386.deb

[[For 64-bit platforms, change the ‘sudo dpkg -i ‘ command wherever it appears with ‘sudo dpkg –force-architecture -i ‘. Everything else is the same.]]

[[Use System>Users and Groups to create an account with username “iraf”,
real name “IRAF Maintenance”, home directory “/iraf/iraf/local”, shell “/bin/tcsh”, and a secure password. For sudo commands here on, use this password. Also in the ‘porperties’ tab, take the ‘User privileges’ tab and tick the box – ‘Executing System Administration Tasks’. This is only for installation purpose. You should remove the tick after successful installation.]]

sudo chown -R iraf:iraf /iraf


su iraf

mkdir /iraf/irafbin

mkdir /iraf/irafbin/bin.linux

mkdir /iraf/irafbin/noao.bin.linux

mkdir /iraf/x11iraf

mkdir /iraf/extern

cd /iraf/iraf


tar -zxf as.pcix.gen.gz

rm as.pcix.gen.gz

cd /iraf/iraf/unix/bin.redhat/

mv * ../bin.linux/

cd /iraf/irafbin/bin.linux


tar -zxpf ib.rhux.x86.gz

rm ib.rhux.x86.gz

cd /iraf/irafbin/noao.bin.linux


tar -zxpf nb.rhux.x86.gz

rm nb.rhux.x86.gz

setenv iraf /iraf/iraf/

cd $iraf/unix/hlib

source irafuser.csh

[[Choose default paths as will be shown in on-screen prompt parentheses. Give ‘n’ when it asks ‘configure IRAF Networking on this machine? (yes): ‘ if you don’t need it. Me too is not an expert on it.]]

sudo ./install

sudo apt-get install libncurses4

cd /iraf/x11iraf/


tar -zxf x11iraf-v1.3.1-bin.redhat.tar.gz

mv lib.redhat lib.linux

mv bin.redhat bin.linux

sudo ./install

rm x11iraf-v1.3.1-bin.redhat.tar.gz


tar -zxf ds9.linux.5.0.tar.gz

rm ds9.linux.5.0.tar.gz

sudo mv ds9 /usr/local/bin/

cd /iraf/extern/

mkdir tables stsdas

cd /iraf/extern/tables/


tar -zxf tables37.tar.gz

rm tables37.tar.gz

cd bin.linux/


tar -zxf tables37.bin.redhat.tar.gz

rm tables37.bin.redhat.tar.gz

cd /iraf/extern/stsdas


tar -zxf stsdas37.tar.gz

rm stsdas37.tar.gz

cd bin.linux


tar -zxf stsdas37.bin.redhat.tar.gz

rm stsdas37.bin.redhat.tar.gz

cd /iraf/extern/stsdas

python python/ ./python

python python/ ./python/*




sudo chmod u=rwx iraf

mkdir ~/IRAF

cd ~/IRAF


[[Select “xgterm” as your IRAF shell when prompted.]]


The command ./iraf will now launch a complete IRAF session containing DS9,
xgterm and ecl, based in ~/IRAF. Alternately, type “ecl” for enhanced IRAF, “cl”
for regular IRAF, and “ds9” for standalone DS9 launch. Please note that “tables”
and “stsdas” can only be used within IRAF.

Repeat the last 5 steps for each user as needed.

= END =