Saturday, May 31, 2008

Rain, Rain, Rain


I like raining.

In normal days there are running kids, crazy dogs, inconsiderate smokers, fume-blowing buses, and endless noises, recklessly invading my personal space and torturing all my senses.

Raining is a god-send. It washes away all those irritants; suddenly kids are gone, dogs scramble for cover, smokers stop their acts, and all toxic gases from vehicles are replaced with the refreshing smell of fresh rain water.

Most importantly, rain provides a natural barricade between myself and the rest of the world. I and my umbrella are in our own little happy world. No one shall join and annoy, no one shall leave and despair.

Rain soothes my soul. I love raining. :)

Sunday, May 25, 2008

The Paradox of Tomorrow's

If you will be dead tomorrow, will you still go to office?

I won't.

How about if you will be dead in one-month time? 3-month time?

Nope, I still won't want to go to work. Not at all.

Repeat the above question with increasing amount of days up until one year. I still hear myself saying 'no way!'.

So far the above sounds like a typical Sunday whine. What intrigue me are the following pair of statements:

a) I will be dead in n-th day from now, where n > 0 and obviously countable
b) Tomorrow I will still go back to office to work

Something is NOT right.

My short term and long term views don't tally and contradict with each other.

If I were given a 'due date', so to speak, I can instantly identify the current job is not my cuppa.

The problem is: death is so far away to most people, including myself, to the extent we just pretend it doesn't exist, and live yet another day on something that doesn't touch our hearts. Maybe the current job isn't too bad, or it is just good, but not great. The inertia of laziness just drags us down to the point we think we are happy.

However the 'what-if' questions above really force me to re-examine what I have done, and what I plan to do.


Houston Cuppa, we have a problem...

The Upgrade Hu-Ha of Windoze XP SP 3

My gut feeling was right: XP Service Pack 3 sucks

Cuppa already delayed the installation by almost one month and thought it would be safer to install the SP later rather than earlier.

Compared to other horror stories on SP3 floating in the net, I was lucky, because my laptop still booted up properly after applied SP3. However the speed for everything was much slower from then on (e.g. roughly 50% more time for login. Under XP SP2 it took me less than 10 second, but with SP3 it could take about 15 seconds). Boot up was slower, login was slower, and even time to launch application was also slower. Personally I suspect M$ did that deliberately, just to close the speed gap between XP and Vista. Obviously Intel would love this SP, because now users will need a more powerful CPU to go along.

Slowness was not the only thing in SP3 that bothered me. After installation, my wireless connection only worked sporadically, and if I left it idle for more than, say, 10 minutes. It would crash and a hard reboot of the system was needed.

The only good about SP3 was it did a system restore point before installation, and the users can uninstall it via 'Add or Remove Programs'. I restore my laptop back to pre-SP3 era, feeling so much better now.

Will I still apply SP3? I will say wait until next year, at least.

Saturday, May 24, 2008

Reviews: Bad Dining Experience with Patisserie Concerto London

As a frequent traveler who has been to the north America, a lot of Asian countries, and a few European countries, I have visited a lot of food outlets. Not wanting to go any place more than once, this trip alone I have gone to around 40 different eating places with wide range of price points and quality. Thus, I have my fair share of unpleasant dining experiences which involved either bad food,  bad services, or, both.

When I encounter a lousy food outlet, what I will do is to make a mental note to myself, and move on. In London I have a very unpleasant experience with Patisserie Concerto (sister company of Caffe Concerto) of Knightsbridge, to the extent I have to say something. The curious-combination of high price, so-so quality of food, and indifferent waiters really made it a winner for a bad-service award and set as a good example for fellow caterer providers what NOT to do, and potential customers where to avoid.

The incident is as follows:

I and my parents went to Harrods in Knightsbridge for some last minute shopping, and once we were done, we just strolled around to look for food. Patisserie Concerto came into sight with its eye catching Salmon Steak sign board. There we went in and got the first ill-treatment: The waiter kind of forced us to sit right at the door, while there were a lot of vacant tables inside the premise. Tired and hungry, we didn't think much and sat down, and the waiter took our order.



Everything was as usual: drinks and food served and we started to eat, until there were two men came and sat just right outside the door and started smoking. They were gone when the above picture was taken. They sat at the gray shirt guy's table, whose face I put an 'A' for easy identification. We sat at the table right behind the white shirt guy I marked with a 'B'.

Since there was no partition wall to separate the smoking and non-smoking zones within the premise, the smoke flew in and choked us. When I complaint this to the waiter, he just shrugged and said he could do nothing. He mentioned he couldn't stop customers smoking outside of the premise.

I do understand customers are allowed to smoke outside, but it is the premise's responsibility to ensure the smoke will not flow indoor! Or else what is the point of forbidding smoking when there are plenty supply of second hand smoke for indoor customers? The waiter didn't try to help by offering to change our place even though at that time the premise was only around 40% occupied and there were a lot of vacant tables inside. He just walked away with no help, and no apology. We were appalled by this kind of bad service and worse still, they charged us 12.5% or £4 in our case, of 'service charge'. But what service we had been getting? Smoked meal with attitude-problem waiter?

On top of all these, the food was not tasty at all compared to all the meals we had had thus far: salmon was not fresh, spaghetti was too sour, and coffee was lukewarm.

My lesson learned in UK is to go for food in crowded bars, and usually there will be cheap and good food available.

Of course, for those who are masochistic, Patisserie Concerto will be a good place to waste money, eat tasteless food, get shitty services, and kill yourselves in second-hand smoke.

Monday, May 19, 2008

The Earth Quake that Unites China

Most of the readers of my blog may think Cuppa is a nerd who lives only in the techie world.

Not quite. I have been keeping myself abreast with the world news, and what gets most of my attention is the earth quake that shook Sichuan Province in China on May 12.

I have seen a lot of pictures online, and here I post some of those that struck me.
Worrying the next earth quake may bury her and no one knows her name. This girl wrote her name, Song Yao (宋瑶), on her left hand. "The rescue worker will have no difficulty identifying me even if I were buried deep down there." I wonder how long it will take to heal the psychological shock to these survivors.


This man lost his nine-year-old son, holding the body, he could only cry... I kind of experienced that before when my cat was run over by a truck. While holding its body which cooled little by little, my brain was blank and just hoped everything was a dream. Holding it I walked around my house like this sad father, until my parents took it away from my hands. The only regret was they made a wrong decision to dispose it in a dumpster instead of burying it at the backyard. For the next cat, we took care of it from cradle to grave, all in the same house. It even has its own custom-made coffin and buried under a tree where it liked to sit under. I have planted some purple flowers on the grave as well, heh. :)


This teacher tried to protect her pupils while the whole concrete slab crushing on them. Although none of them survived in this case, there were reports where teachers managed to save the children but sacrificing themselves. I salute these people.


A demised student found still holding to her pen until the last moment...

This earth quake is a tragedy, however it does have some positive effects. First of all, it has a unification effect where the whole China and Chinese from all over the world put aside the political and ideological differences and chip in to help. Attention on Tibet is alleviated, Taiwan not talking much on independence or joining WHO, and the leaders of China are shown with more positive lights.

Life is fragile, just one minute of earth quake changed lives of million of people. A blogger in China secrets admires his classmate for a long long time. However after years he still doesn't have the courage to tell her. She died in the 512 quake, and he regrets big time. In his blog, he keeps asking himself why he didn't have the guts to tell her earlier.

Similar stories abound: wife plans to go travel with husband but was too busy, keep postponing the plan; children plan to bring old parents for a trip, again too busy and keep postponing. All now grieve with life-long regrets.

Realizing the uncertainty of life long long time ago, Cuppa has contingency plan long long time ago.

First, long long time ago he already told the girl he loves her in an ultra repetitive and boring way, to the extent she wanted to sue him. Anyway, that message is believed already been driven home. It is her turn to regret should anything happens to Cuppa. Heh. :P

Next Cuppa will travel with his parents to Europe in early June, hoping to fulfill one of the his ToDo list items.

Among the list of items..., to settle my parents in my place of birth, to have a family, and later, to work as a volunteer in Africa...?

We shall see. Treasure those around you. You never know what will happen in the next day, or even next hour....

Something more cheerful to end this post with:

This lucky girl smiles at the camera when the rescue workers found her underneath a pile of concrete walls. Smile of the year, yeah! :D

Saturday, May 17, 2008

OpenSolaris Review: Setting Up

NOTE: Updated Aug 3, 2008. New stuff in blue

My previous post was a quick summary on what I had done the past few days on OpenSolaris. I think OpenSolaris deserves more than that and hence I will try to run a series of reviews and my experience with tinkering OpenSolaris.

The executive summary of this post: OpenSolaris though has the same look and feel as other gnome-powered Linux, there are little inconveniences that really get into the way. This post will point out mainly what I find weird/inconvenient.

Disclaimer: I am a regular user of Windoze (XP only, if you care to know) and Linux for over 10 years. My experience with Solaris only amounted to logging into the UltraSparc boxes in my university to change the login password because all other stations running Windoze or Linux were occupied. Therefore I consciously or unconsciously will treat anything that deviates from the Linux-way as 'weird'. Be warned.

Good Stuff of OpenSolaris:
  • ZFS is sexy with tonnes of cool features. However you will only see limited strength when you have only one hdd.
  • The Solaris kernel is well-thought of, and I feel the organization of the configuration files is comparable, if not more sane, than most Linux distributions
  • Utilities like crossbow and dtrace are famous. Personally I have no experience with any of those and definitely will put my hands on them asap.
Things that suck in OpenSolaris
  • [Updated 3 Aug 2008] The following issue only applies to my old P4 machine. I installed OpenSolaris on a newer machine, and the following problem didn't show up.
    I used a USB keyboard, but OpenSolaris cannot detect it. Therefore I cannot choose the Grub boot option and have to wait for 30 seconds for the menu to time-out and execute the default option. Ironically during bootup even the BIOS can read from that keyboard and I have no problem in maneuvering the CMOS BIOS menus. Needless to say, Ubuntu doesn' t have this problem.
  • OpenSolaris doesn't fully support Pentium 4. 'dmesg' report SpeedStep is disabled
  • While trying to format my Linux-formatted Seagate 80GB HDD with zfs, it reports the drive can only be formatted with 'utility provided by the drive manufacturer'. However without formating, zfs can read and write from it fine. This confuses me a whole lot. Until now I am not sure if the drive is ok because I can't think of a way to verify its surfaces. In most OSes, you can just format the drive and get to know the status of the drive. Not for zfs.
  • While nfs is working right out of the box, samba is a bitch to set up. This is due to although the packages are installed, they are not set up properly. First I have to create the smb.conf by copying it from the example file, next I need to configure svcadm by importing the samba.xml file somewhere in the filesystem using 'svccfg import'. Also the default samba.xml needs some modification to invoke nmbd. All in all, smb (samba) is a pain to use compared to nfs. I guess smb in such condition may due to security reason, but come on, at least there should be proper documents somewhere. What I could find was blog posts here and there and it is very frustrating to crawl around the web like crazy just to get samba working.
Note: Samba finally works for me.

  • Networking is harder than necessary(covered by my previous post here). If network auto-magic cannot configure the networking settings properly, user needs to disable it manually and enable the default networking interface, which is trouble-some.
Summary:
In terms of usability, OpenSolaris still lags behind and for now I think it is more suitable for more experienced and tech-savvy computer users

Wednesday, May 14, 2008

First Dive into OpenSolaris

These few days I have been playing and experimenting with OpenSolaris 2008.05 and Ubuntu 8.04.

At the surface, OpenSolaris looks very similar to Ubuntu or any distro of Linux that runs gnome:
  • It also provides most of the open source tools that shipped with Linux
  • The look and feel are 'almost' the same
  • It has the authentic Unix directory file structures and design philosophy which Linux borrows from
The first difference I noticed is the incomplete functionality of the OpenSolaris UI (or 'frontend' in software engineering jargon) . Some of the tasks can only be done at the command line.

For example, the UI only provides button for the user to shutdown the system, but there is no 'restart' button. If you want to restart the system, you need to open a text terminal, and type 'reboot'.

Another example will be the network setting. When OpenSolaris boots up, it has the Network Auto-magic daemon (nwand) running. If your network settings are unusual or you want to manually do some settings, you have to disable the nwan and enable the 'default' settings manually. When you click on the 'networking' icon, it will just ask you the network cannot be set while nwan is running and you have to disable nwan first. It then points you to read nwan(1m) and let you figure out the rest.

Guess where you can set all these? Command line of course.

svcadm disable svc:/network/physical:nwam
svcadm enable svc:/network/physical:default


Since the shell will accept shortest unique string, lazy smart user will do:

svcadm disable nwam
svcadm enable physical:default


For those of us who are used to text terminals and commands, OpenSolaris is something that we know and love. In fact, often command line is desirable since it is often more responsive, and tasks are easier to automate.

The 2008.05 release represents a good progress for OpenSolaris and I feel the underlying backend is reasonably stable. The remaining work for Sun and the OpenSolaris community will be:

  • Port more packages to the OpenSolaris platform
  • Enhance the functionalities of the frontend without sacrificing the versatility provided by the underlying infrastructure (i.e. tool chain and command sets)
One of the main attractions of OpenSolaris is the renown ZettaByte File System (zfs) which is really really sexy. According to Sun, zfs has self-healing and redundancy built right in the file system and this could easily make hardware backup solutions like RAID or tapes obsolete. If the claim is true, we are seeing yet another example where software slowly replaces hardware functionalities.

I have a zfs set up (one 80GB hdd) and now managed to export it as nfs. My plan will be get Samba to run on it and thus creating a central repository for both Windoze and Linux boxes.

Stay tuned.

Monday, May 12, 2008

OpenSolaris on VM

I came across VirtualBox, the virtual machine (VM) from Sun. Curious, I downloaded it under Ubuntu and installed OpenSolaris on it.



VirtualBox runs fine so far, except the P4 machine on which it runs on really shows its limit. The machine is crawling ever since the VM is active and I keep wondering if additional cores will help in this case.

Sunday, May 11, 2008

Blogging on OpenSolaris

I mentioned a few days ago I downloaded the openSolaris live CD and will take it for a spin someday.

Indeed today is a very fine day where the usual badminton session was canceled, and girl friend is yet to be found.

I threw the openSolaris CD into the drive and booted it up.

Maybe I am really obsolete, but again I am amazed when it can detect most of the chipsets of my cheapo Dell laptop. It even automatically detected the wireless networks for me and boom here I am, blogging on openSolaris through the Live CD.

Here is a screen shot using the screen capture utility.




I plan to ditch the Fedora 8 in my another office machine and replace it with openSolaris, just for the sack of experimenting.

For now the weakness I have found is there are far fewer software packages available for download, and the package manager seems weaker than Ubuntu's.

Personally I feel that openSolaris has a lot of potential. If Sun plays the cards right, it could even match and compete with Apple's OS X one day (remember the underlying kernel of OS X is BSD-based, which has a very close lineage to Solaris).

Note so far the software development has mainly fallen into two extremes: open-source projects like the Linux kernel (i.e. the Bazaar), and closed-source projects like Windows (i.e. the Cathedral).

My take is both ends have their benefits and disadvantages, and a reasonable alternative will be to have a hybrid model that inherits the advantages from both models.

Advantages of
Open Source: Freedom, transparency, project decisions will be more on technical merits than business choices (e.g. barring competitors from entering by creating a obfuscated standard)

Closed Source: Centralized management of features, coherent development plan

In this respect, openSolaris seems promising, if, and only if it doesn't shift too much to either the open-source (not likely) or closed-source model.

Though open source purists are often skeptical when commercial entities involve in software projects, there are a number of high profile open source projects that fall under this category.

The QT toolkit is a very successful example where the software is maintained by a for-profit company. Users can choose to use the software for free provided they don't use it for commercial purpose, and agree to contribute back to the open source community. QT is owned by Trolltech, which in turn is recently bought over by Nokia.

Another example will be Mercurial, a distributed version control software, which is backed by Selenic.

In the long run, the introduction of openSolaris though further complicates the OS landscape, it nevertheless forces all the major OS vendors to reckon the reality, and in the end, it is us the consumers who will benefit in this war of desktops.

Saturday, May 10, 2008

The Friday Night Chill-Out

I have been in Singapore for close to one year, and last night was the first time I went to St. James Power Station, a renown disco complex with different outlets playing a variety of music.

Truth be told this was also the first time Cuppa set foot at a disco because of the loud music and smoky environment. Yesterday I made an exception, mainly due to curiosity of this renown outlet, and also gave myself a lame excuse to drink myself silly. Moreover, Singapore has banned smoking in public places and this contributed positively to my decision.

I and my friends arrived there around 7p.m, which was way too early for the party-goers to show up. Obviously, first thing most essential to Cuppa was beer, and a regular beer drinker I am, I was still a little bit shocked when I saw the waiters bring the 'mini barrel' my friends ordered. The first thought was when the hell would four of us finish this giant barrel of booz? (it was shown actually not hard at all, because we downed one more barrel later that evening)


"This is just the starter", one of my friends who goes clubbing regularly commented. Guess what is the capacity of this mini barrel? It is 3 jugs, or ~12 glasses, or 6 pints. At this point I must admit the super-cooled beer was damn fantastic.

Minutes later, a basket of mini champagnes was brought on table. Not sure its brand, the taste was a bit sour, but I still drank the whole bottle.


More and more people showed up as the night matured.

The lighting was dimmer and dimmer, music grew louder, alcohol was catalyzing its effects, bodies bonded closer, and the crowd started to get wild.

After a good few glasses of beer, the grip of my usually-rational left brain started to loosen, and the logical structures and rational thoughts were slowly replaced by blankness, thoughts were blended and meshed with the loud music and moving silhouettes around me (yes, it was that crowded) and slowly the mind was muddled.

I thought I would relax and enjoy the moment (whatever it was). With my left brain's guard down, my ultra emotional right brain took advantage of the situation and struck me with the total replay of everything about MAK. I found myself 'reasoned' that it was April Fool's Day and therefore she might not mean what she said.

I shook my head and sipped the glass of beer just filled by my friend. Music was getting even louder and my heart seemed to vibrate in rhythm with the earth-shaking high power music bass. All these years we were in the non-talking mode, it went nowhere and won't go anywhere at this status quo. I shook my head again. No clue.

This outlet has a stage and there were live bands performing periodically. To satisfy different tastes, the performers were dressed in different styles like Punk, Jazz, Japanese, Chinese Classical (80s era clothes). What amazed me was two of them even dressed in traditional Chinese attires (should be popular around thousand year ago, now only exist in movies) but sang not so traditional songs (aka modern songs). This is really a pragmatic and fast-learning country. As long as the trick will attract patrons and get revenues, whatever will go. Creative!

Singers dressed in old-style Chinese clothes

Tuesday, May 06, 2008

Burning CD with Ubuntu

Recently I have been using my Ubuntu machine frequently.

This afternoon I downloaded the openSolaris 2008.05 iso image. Once I got the file, burning it to a disc is as straight-forward as a few clicks. This post may seem trite to those who use Ubuntu regularly. But for me, the last time I ever seriously used Linux was almost 2 years ago and really Linux has been progressing in leap and bounds, though I have to admit due to the corporate infrastructural issue (read: old systems die hard), even 2 years ago I primarily dealt with RedHat Linux, which IMHO, sucks big time.


OpenSolaris seems promising and I will spend some time to play with it.

Monday, May 05, 2008

Flip-Side of Embedded Linux

Since the inception of Linux way way back (in Internet time, that is), it has generated a lot of fan-hood and excitement. Finally after ages of Windoze-ism and when-do-you-crash-today-ism, Linux offers a viable alternative to the highly geeky mass.

Embedded devices are always a group by themselves because of three main constraints: power, memory, and 'closeness to hardware'.

The last item demands some explanation: Most embedded device will feature some non-standard peripherals. It could be a special memory-mapped region for retrieving of network packets, an external I2C bus on which the CPU talks to an FPGA, or even just a FIFO where the north CPU talks to the south CPU (yes, 2 separate CPUs, not dual core, no, not north bridge and south bridge). Therefore in embedded system there are a lot of work that involve interfacing and talking to the bare metal. You just can't avoid those like what you deal on regular PCs. Ok, I lied, this kind of work exists for all known computing devices, just that they are taken care of by poor firmware engineers like Cuppa.

"But my company's embedded device runs [your favorite OS] and engineers still don't need to care about the underlying hardware!", you may retort. Well, there are two possibilities to this. First, your company most probably has outsourced the firmware development (buying so called the board support packages which take care the low-level stuff). Second, the design your company has is based on a reference platform where again most of the dirty work has been done for you. It could be a linear combination of 1, 2, or both. However I will argue that no matter case 1 or case 2, any serious embedded software work will open the can of worms and someone eventually needs to take care the low-level details. The question is just who and when.

Linux becomes favorable because all source codes are open and free (both as in beer and speech). With source code in hand, the engineers can prune and trim according to need. This seems like a dream come true: We got something cool, and it is free!

Like everything in life, there are always down-sides for Linux. In fact, there are quite significant weakness in Linux-based embedded solutions.

First of all, beside the Linux core kernel, you need a fair number of software modules to get the system up and running. Note that these software modules are usually maintained by different people and the quality variation is significant. No worry, there are companies that sell this kind of solution, say solution from manufacturer X, they say they have an 'integrated, pre-test' solution on one 'open source development platform'. So far so good, you bought solution X version N (XvN), implemented your product on top of it, and it is good to go. Perfect, but this is actually the easiest part of the whole development cycle.

The horror starts when you get past the software release and enter maintenance phase. Note that XvN you bought earlier represents a snap-shot of the open source landscape some time ago, and worse still, due to stability and testing purpose, company X usually will not source the latest source code from the said software modules. In other words, don't expect your XvN to contain the latest features, bug fixes, and security fixes.

On top of the problem XvN is obsolete right after it is delivered, there is a problem where feature changes in new release break some other software in the system. Recall that the underlying modules are maintained by different people/organizations, even though the maintainers of key modules will exercise certain cautions when doing modifications, there is no official coordinator to draft out a system plan to ensure backward compatibility and coherency for _your_ system. Therefore there is no guarantee the newer release of a key module will continue to work for your system or even XvN. It is far not uncommon to have a system completely fall flat on its face when doing a minor upgrade because a subtle change in package functionality. Did I mention some package maintainers just disappear or give up the software and you are left with a year 2000 version of package XYZ?

This post is inspired by this post. Read it, if you are very into Linux.



Thursday, May 01, 2008

Why Windows?

After months of begging and complaining, finally I get a more or less decent desktop to install Linux on. Before that I was only given a Dell laptop with Vista loaded (but I upgraded it to XP on the first day I got it, so much happier).

Just for the record. This is the first time I had to ask so many times for a computer, despite the plummeting prices of IT products.

No wonder my company is losing engineers like hell. They have no clue what engineers need.

My 'new' desktop was a decommissioned demo unit with a P4 and a modest 512MB of memory. After salvaging around the trash yard at the back of the company, I managed to get some more memory and made it 1GB.

First I installed Kubuntu (Ubuntu with KDE, instead of the standard Gnome environment) on it. The result wasn't too encouraging because the full package upgrade failed miserably and there were rough edges here and there which made my experience quite unpleasant.

Disappointed. I recalled Knuth also uses Ubuntu to write his stuff and the term 'used by Knuth' alone is more than enough reason for me to try this distro out. I downloaded Ubuntu 8.04 LTS (Long Term Support) Desktop Edition (1 CD ~700 MB).

The installation went very smoothly. Ubuntu detected everything automatically and get things up and running automagically.

Then I fired up the package upgrade and removed some packages like audio and movie players (my desktop doesn't have sound card) and added a couple of programming packages. Again, the experience was smooth and pleasant. Most importantly, no reboot was needed!

Ubuntu really is a breakthrough in terms of usability and robustness, and as a Linux user for 10+ years, finally this is a version of Linux that I don't need to recompile the kernel (I could if I want) or need to download source packages for compilations. Way to go Ubuntu! :D

Firefox 3 Beta. At da cutting-edge of techie...


Programs under the 'Office' menu. The background is the default wall paper

P/S: Today is labour day but I am blogging in office. Anyway, nowhere to go also. Mr. Snail invited me to go to Johor Bahru, but I am not too keen to see the mess over the causeway. For now it seems Ubuntu looks better. :)