Thursday 6 November 2008

Lessons to be learnt

So finally it happened. What many Americans thought impossible to occur within their lifespan. The first black president at the helm of American power machinery. What's more important is to reflect what took him there with having a big barrier that so many thought would crush him, the color of skin.

Apart from political reasons (economic downturn, tax policy etc. etc.) I think there were other factors at play which decided it for Obama.

The best place to start lies within the end itself. That acceptance speech he did. The indisputable fact of his oratorship was portrayed time and time again in that speech. For me it's not been about his policy (being neutral), but the style and variations in his speech that struck to me as remarkable, which I thought were far better than Mr. MaCain. The final touches were as impressive as ever. The grandma who lived to see the how the generations has changed, boy he is a conjurer of creating imagery and penetrative words. Did I see some lady in tears when he spoke that? No doubt he was effective.

One of the remarkable things that even in the acceptance speech I saw was amount of youth excitement and participation. The secret was partly in the way that he reached out the masses. He was talking to the modern America using modern ways. How about at his funding campaign? The decison of not being restricted to federal funding and reaching masses with an effective online funding mechanism was highly successful and proved to be a winning decision at the end of the day in both monetary wise and political wise. Today I was brought to notice about his Twitter account. Guess how many were following his posts. More than 100,000. I was surprised. How many limitless possiblities these new avenues in technology has brought us allowing us to communicate better and effectively. No doubt Obama had clearly understood the changing times has strategically adapted to them in his campaign. His effective online presence no doubt would have reached scores of young floating votes. At the end MaCain had to admit that he was addressing the 'old' America using old ways which was one of the reasons for the downfall of him.

One thing is clear. Change or no change Obama has pulled off a great campaign all together and he derserves what he's got.

Wednesday 29 October 2008

Tomcat Installation - TROUBLES!!!

Why are somethings seem to be so trivial but sometimes become so hard to pull off specially when in a hurry. That is what exactly happened when I tried to install tomcat in to my new Ubuntu (hardy) box. Here's what happened.

After extracting tomcat to the installation folder and making sure necessary JAVA_HOME & JDK_HOME variables are there in .bashrc I tried to start the server with ./startup.sh.

Output- Permission denied.
Reaction - Hmm. Should try a sudo sh startup.sh

Output- Cannot find startup.sh
Reaction - What! 'ls' shows file is there. What about ls -al

Discovery !!!- No execute permissions for startup.sh file
Reaction- chmod +x startup.sh. Again tried ./starup.sh.

Output- Cannot find catalina.sh
Reaction - ok. should try chmod +x *.sh. Again ./startup.sh

Output- The BASEDIR environment variable is not defined correctly
This environment variable is needed to run this program.
Reaction-What the heck!@#@#. Only help now is google.

Little bit of googling brought my attention to the CATALINA_HOME variable. So
I set it to tomcat_installtion_folder/bin in .bashrc. When tried ./starup.sh it gave this.

Output- Cannot find /home/chamith/Installations/apache-tomcat-6.0.18/bin/bin/setclasspath.sh
This file is needed to run this program
Reaction- What now????

Again little bit of googling brought my attention to the following part in the source of catalina.sh.


if [ -r "$CATALINA_HOME"/bin/setclasspath.sh ]; then

BASEDIR="$CATALINA_HOME"
. "$CATALINA_HOME"/bin/setclasspath.sh

else

echo "Cannot find $CATALINA_HOME/bin/setclasspath.sh"

echo "This file is needed to run this program"

exit 1

fi

Got the culprit. CATALINA_HOME set wrong. Should not include bin in the path of CATALINA_HOME. Should have noticed in the previous shell output.
Hope this would work.

Yep. It worked. At last............
What a relief.

P.S.: I was on the notion that CATALINA_HOME was not essential to include since the script sets it in the runtime. Anyway now the tomcat works even when I remove the CATALINA_HOME entry from the .bashrc.