This is the Blog for Thomas Lai

Saturday, November 26, 2005

Ruby

Recently read a lot of good reviews about Ruby programming language. Its web application framework Rails is also getting very popular (RoR, Ruby on Rails in short). I found 2 good links to learn Ruby.


http://www.ruby-doc.org/docs/ProgrammingRuby/

http://poignantguide.net

Wednesday, November 23, 2005

Kernel Upgrade - the easy way

This morning I saw the Upgrade Manager icon blinking again. I click on it and it seems like a minor kernel upgrade is available.

Upgrade Kernel

After installing the new kernel, it prompt me to reboot. Seems like a much convenient way to upgrade kernel.

Upgrade Kernel-1

Sunday, November 20, 2005

Gnome System Monitor

In Windows XP, I can always invoke the Task Manager to check the processes, and the CPU, Memory Utilization by typing "Ctrl-Alt-Del'. I could do the same in Ubuntu using Gnome System Monitor. To use the same keys in Ubuntu, just use the following commands:

gconftool-2 -t str --set /apps/metacity/global_keybindings/run_command_9 "Delete"
gconftool-2 -t str --set /apps/metacity/keybinding_commands/command_9 "gnome-system-monitor"

apt-get and Update Manager

I was installing FreeMind, a free mind-mapping software which runs on Java. I downloaded the debian package and use 'sudo dpkg -i' to install it. It prompted me for some additional libraries as follows:

thomaslai@ubuntu:~/Desktop$ sudo dpkg -i freemind_0.8.0-1_all.deb
(Reading database ... 85042 files and directories currently installed.)
Preparing to replace freemind 0.8.0-1 (using freemind_0.8.0-1_all.deb) ...
Unpacking replacement freemind ...
dpkg: dependency problems prevent configuration of freemind:
freemind depends on librelaxng-datatype-java; however:
Package librelaxng-datatype-java is not installed.
freemind depends on libcommons-lang-java; however:
Package libcommons-lang-java is not installed.
dpkg: error processing freemind (--install):
dependency problems - leaving unconfigured
Errors were encountered while processing:
freemind


While I was wondering how I could find the dependent libraries, suddenly the Update Manager icon springs to life in system tray in Ubuntu. I click on it, and oh my dear, the 2 missing libraries are prompted in Ubuntu Update Manager for me to download and install!

apt-get is truly amazing!

Sunday, November 13, 2005

OSX Expose in Linux

OSX Expose is a nice feature, which arrange all the different windows in a single window and you can get to choose which one u want. In this era of multi-tasking, it is a useful feature.

In Ubuntu, u can get the same function by using 2 little applications:
1. Skippy
2. Kompose

Skippy has lesser in functions. Kompose, in contrast, can allow me to group and upgroup the different windows in different ways. Here is a screenshot of Kompose in action.

Kompose

Beagle Search

Beagle Search is a desktop searching tool just like Google Desktop (in Windows) and Spotlight (in OS X Tiger). I have played around with it. You need to start a Beagle Deamon first for the Beagle client to work. I documented the steps where I added in a file with the searched term "DVD" and the Beagle desktop search result will automatically refresh with this new file. Not bad for an Open Source software.

Beagle step 1

Beagle step 2

Beagle step 3

Saturday, November 12, 2005

GTK Themes

OS X Splash Sreen



There is a feature in Gnome which allow me to change the theme. I downloaded an Apple OS X theme, install the icons and the Splash Screen from GNOME-Look.Org. I modified some of the default icons from the theme. The result is a clean and nice desktop interface and login splash screen.

In case you wonder how I capture the login screen, here is the trick, install Xnest (Nested Xserver). Here are the steps:

sudo apt-get install xnest
gdmflexiserver --xnest

Then do the screen capture.


Wednesday, November 09, 2005

NTFS drives and Unicodes

I have 3 NTFS drives which are auto-mounted by Ubuntu. However, I encountered 2 problems. One issue is that I do not have the priledges to use Nautilus to view the contents of the NTFS drives. I found this script which can launch Nautilus as 'root'.

The second issue is that I have some files which has Chinese Unicode filenames. The files are 'missing' from the Nautilus or Terminal if I view the directory listing. The way to resolve it is to mount the NTFS drive by specifying the mount options as 'nls=utf8,umask=0222' in /etc/fstab. The umask means that it is set as read-only. But make sure backup a copy of fstab before modifying it.

Btw, reboot the system to make the fstab take effect. Although in many websites it says I can issue the command 'sudo mount -a' to remount all the disks in fstab, mine only take effect after reboot.

Friday, November 04, 2005

Sun Java with Azureus

Finally resolved the puzzle on why Sun Java 1.5 does not seem to work well with Azureus. Azureus started ok, but download is always at 0 kbps. However, if I switched to Blackdown Java 1.4, Azureus download will be ok. It has puzzled me for a while.

Thanks to my friend Coyote, he encountered the same issue in FC4. After some experimentation, he found that it was due to the existence of default installed JRE in FC4. He removed the default JRE and Azureus works well with Sun Java JRE 1.5.

In Ubuntu, it came pre-installed with GNU GIJ JRE. But I could use the following command to choose which JRE as default

sudo update-alternatives --config java

I actually have 3 JREs in my system:

1. GIJ JRE
2. Blackdown Java 1.4
3. Sun Java 1.5

However, even though I have choosen Sun Java 1.5 as default, GIJ JRE still gets in the way in Azureus. Co-existence of different JREs in a Linux distro seems to introduce some complications. As such, I removed both GIJ and Blackdown Java JRE from Ubuntu. After which I realized that Azureus works properly.

Due to the issue with Azureus, I also tried out another Bittorrent client Bittornado. It does not support Unicode as well as Azureus, but it is lightweight and fast. Recommended.

Thursday, November 03, 2005

A Show Case for Smart School Project

My friend Fuyichin is a proponent for Smart School Project. He mentioned that there is a school in a remote area in Malaysia, Dinding Secondary School, which has been computerized. In fact he visited the school himself, and he is impressed by what he saw.Read his blog here.

Today Taiwan up the ante by having a primary school which is a Smart School. 苗栗縣大湖鄉大南國民小學 - 全球資訊網站.. It runs on FreeBSD. Ta ke a look at the list of sofwares . Truly Solid!

Avidemux




Avidemux is a software which splits the multimedia files in Linux. It supports AVI, OGM, Mpeg etc. I tried it on Ubuntu, and it works like a charm. Just click on te fram to start, the frame to End, and the Save. That's all.

Also found a guide to convert AVI to DVD.

Tuesday, November 01, 2005

Slack World

The Website Slack World is pretty good. Although it is targeted for Slackware users, the Linux concepts are quite useful to other distro too.

For example, the fragmentation in Linux disks actually does not affect the performance, as much as MS-DOS systems. Here is the article in Slack World explaining why.

Anyway, there is only 3 online issue of Slack World so far, April,June and July 2005. Hope more to come!