Thursday, 30 September 2010

Solving installation problems with Comsol 4.0a in Ubuntu Linux

Today I decided to install Comsol Multiphysics 4.0a, which is a physics simulation program based on the Finite Element Method (FEM). I'm running Ubuntu Linux 9.10 (Karmic Koala), and the installation procedure should be as simple as this (quoting from the installation manual):

"To start the installation, type the command

sh {drive path}/setup

where {drive path} refers to the mount point of the DVD-ROM
drive on your system, for example, /media/cdrom."

When I insterted the Comsol DVD, it was mounted as "COMSOL40a ". Note that there are some trailing white spaces which don't make any sense. When I tried to run the installation program, I got an error message saying that "/media/COMSOL40a" did not exist. Turns out that the installation program was looking for a mount point directory without any white spaces.

My solution to this was to mount the CD to another folder, to a folder name without trailing white spaces. I didn't know how do this, but I found a simple description at this web site. In the terminal, I typed

sudo mount -t auto /dev/cdrom /media/tmpcd/

to mount the CD to /media/tmpcd. After that, I could run the installation program as instructed, by typing

sh /media/tmpcd/setup

I'm not sure who is to blame for this "bug", Ubuntu or Comsol, but at least I figured out how to work around it. :-)

Tuesday, 28 September 2010

Solving Ubuntu full disk problem related to SBackup

OK, so today I came to my office finding that somehow my Wubi Ubuntu installation had somehow filled up completely. There was absolutely no disk space left, and because of this, the whole system was so slow that it was unusable. Not really realizing how this could have happened, I tried to reboot. The log-in screen now looked different, and there was a warning about power management not being set correctly. When I tried to log in, the screen only blinked, before the log-in screen appeared again.

Getting pretty frustrated at this point, I started looking through forum threads for posts on similar problems. I found several tips on cleaning up a full partition, all of which involved getting into "terminal mode" by pressing Ctrl-Alt-F1 at the login screen. This made me able to browse through different folders, and check the disk usage using the command du, but I still couldn't figure out why the disk had filled up.

Eventually, I found this forum thread which suggested that the backup program that I use, Simple Backup (or SBackup) may have been saving backup files on my laptop's internal hard drive rather than the intended external drive. A blog post by rvdavid confirmed that several people have had this issue.

My external drive is called "Martins Backup", and when it is connected, it is usually mounted to /media/Martins Backup. It turns out that the backup program kept saving files to /media/Martins Backup EVEN WHEN IT WAS NOT CONNECTED (sorry about that), effectively storing them to the internal drive. Investigating this further, I found 20 GB worth of backup files clogging up the system. Luckily, they are all gone now, my Ubuntu system works as usual, and I'm changing my backup program as soon as I find a suitable alternative. Puh! :-)