3. Getting the tools working outside of the University of Edinburgh network

Ideally, users of our software will not come exclusively from the University of Edinburgh. In addition, even if you are at the University of Edinburgh you might not have access to our servers.

These instructions are intended to get you set up on your home computer. You will need administrator privileges to get this working.

3.1. Operating systems

The development of our software is done in a Linux environment. There is a prosaic reason for this: our servers at Edinburgh GeoSciences and our supercomputers run linux so it is the fastest option, and our code uses a large amount of memory and is computationally expensive.

I (SMM) have managed to get components of the code to run on the Windows operating system using something called cygwin. This is perhaps not ideal, however, since I’ve never managed to get the FFTW package working on my Windows computers via cygwin, and a number of our routines rely on this package.

My group does not use Apple products, so we have no expertise in getting the software to run on Apple computers. Apple uses a linux operating system “under the hood” of its proprietary operating systems, so theoretically one should be able to get our code to run on a Mac natively. We haven’t tried this so can’t provide documentation.

A perhaps simpler way to do things, if you don’t have an existing Linux operating system, is to use a virtual machine. Basically this is to get a Linux operating system running within your Windows or Apple computer. This page walks you through that process.

3.1.1. Creating a Linux virtual machine on your Windows or Apple computer

So to get Linux running (relatively) painlessly on your windows or Apple computer, you will need some software that allows you to run a virtual machine.

There are a number of options, popular ones include:

  • Parallels This software is proprietary.
  • VMWare There are several flavours of this. The free version is VMware Player.
  • VirtualBox This is open source.

Here I’ll walk you through setting up Linux using VMware. I have no better reason for choosing this software other than a former PhD student has used it and it works. One disadvantage is it doesn’t seem to have an Apple version. If you use Apple you’ll need to try to go through a similar process using VirtualBox, which does have a version for Mac operating systems.

But, here is how you set up the VMware player. You will need a reasonable amount of storage and RAM. So a very old computer won’t work. If you’ve got a computer purchased in the last few years things will probably be fine. You will also need a reasonable amount of storage on your hard disk. The virtual machine permanently takes up some component of your hard disk.

  1. First, download VMware player. The download is currently here.

  2. Run the installation package. Brew a cup of tea while you wait for it to install. Maybe surf the internet a bit.

  3. BEFORE you set up a virtual machine, you will need to download a linux operating system!

    1. We are going to use Ubuntu, just because it is stable, popular and has good documentation.

    2. I first attempted an installation with 64-bit Ubuntu, but it turns out my computer doesn’t allow guest 64 bit operating systems. To fix this I just downloaded the 32 bit version of Ubuntu:

      _images/Ubuntu32.jpg
    3. Find the downloads link and download the latest version. It will be an iso disk image. This will take a while. Put that time to good use.

  4. Once that finishes downloading, you can set up your virtual box. First, open VMware Player.

  5. Now click on the “Create a New Virtual Machine” option.

    _images/Create_VM.jpg
  6. It will ask you how you want to install the operating system. Tell it you want to use the Ubuntu disk image you just downloaded:

    _images/Pick_OS_install.jpg
  7. You will need to add some username information, and then you will have to pick a location for the Virtual Machine. I made a folder called c:Ubuntu for it:

    _images/Ubuntu.jpg
  8. Now allocate disk space to the virtual machine. This disk space cannot be used by your windows operating system!!. I decided to use a single file to store the disk since it should be faster:

    _images/Disk.jpg
  9. The next page will say it is ready to create the virtual machine, but it has a default Memory (in my case 1GM) allocated. I wanted more memory so I clicked on the customize hardware button:

    _images/CutomizeHardware.jpg

    This allowed me to increase the memory to 2GB. Note that this will be used when the virtual machine is on, but when not in use the memory will revert to your original operating system.

  1. You might be asked to install some VMware Linux tools. You should do this, as some things won’t work if it isn’t installed.

  2. Installing the operating system within the virtual machine will take ages. You might schedule this task for your lunch hour, which is what I did.

  3. When Ubuntu has installed, it will look for software updates. You should install these. This will also take ages. Maybe you have a book to read?

  4. Finally, you should be aware that the default keyboard layout is US. Getting a different keyboard is a bit of a pain.

    1. First go to system settings.
    2. Then click on language support.
    3. It will need to install some stuff.
    4. Go to text entry.
    5. In the lower left corner click on the + button.
    6. Add your country’s input source.

3.1.2. Setting up your Linux virtual machine: essentials

You will need to spend some time setting up common tools for your new Ubuntu virtual machine.

Before you do anything, you need to know how to open a terminal. Click on the search tool (on mine it is in the upper left corner, and looks like a little red whirlpool) and then find terminal. Once you start a terminal, you can right click on its symbol on the ‘launcher’ (the stuff on the right hand side of you Ubuntu desktop) and lock it there with the ‘lock to launcher` command

Now you will need to install the essential tools. This all needs to be done in a terminal window.

  1. To install git:

    sudo apt-get install git
  2. To install subversion:

    sudo apt-get install subversion
  3. To install a c++ compiler:

    sudo apt-get install g++

    This seems to install g++, gdb and make, so that is nice.

  4. Get the python package installer, pip:

    sudo apt-get install python-pip
  5. Install all the really useful python packages (this will take a while):

    sudo apt-get install python-numpy python-scipy python-matplotlib ipython ipython-notebook python-pandas python-sympy python-nose

3.1.3. If you are setting up from within the University of Edinburgh LSD group

Ignore all this if you aren’t an active developer of LSDTopoTools.

You need to get our repositories from the subversion server. It is important to note that you can’t use the kerberos authentication from the virtual machine. If you don’t know what kerberos is, don’t worry. The practical consequensce is that you direct your subversion code to a different website and you need to enter your password each time.

  1. First make a folder for the repositories.

  2. Get LSDTopoTools:

    svn co https://svn.ecdf.ed.ac.uk/repo/geos/LSD_devel/LSDTopoTools LSDTopoTools
  3. Get LSDTT_Docs:

    svn co https://svn.ecdf.ed.ac.uk/repo/geos/LSD_devel/LSDTT_Docs LSDTT_Docs
  4. Get LSDTT_tutorials:

    svn co https://svn.ecdf.ed.ac.uk/repo/geos/LSD_devel/LSDTT_tutorials LSDTT_tutorials
  5. Get LSDVisualisation:

    svn co https://svn.ecdf.ed.ac.uk/repo/geos/LSD_devel/LSDVisualisation LSDVisualisation

You also have to install some libraries.

  1. Install FFTW. First make a directory for it. Then go into the directory and get it using wget:

    wget http://www.fftw.org/fftw-3.3.4.tar.gz

    Now unzip and untar it:

    tar -zxvf fftw-3.3.4.tar.gz

    Now configure and make:

    ./configure
    make
    sudo -s
    make install
    exit

    Warning The make step will take some time and dump huge amounts of text to screen. Warning 2 unless you do the sudo -s before make install you will get permission denied errors. The exit takes you out of sudo