Sunday, December 21, 2008

Setting Up Gnizr

Following the instructions at http://code.google.com/p/gnizr/wiki/HelloWorldDemo

Mysql
setup commands:

mysql -u root -p
create database gnizr_test;
create user gnizr;
update mysql.user set password=PASSWORD('gnizr') WHERE Host = '%' AND User = 'gnizr';
GRANT ALL PRIVILEGES ON *.* TO 'gnizr'@'localhost' IDENTIFIED BY 'gnizr' WITH GRANT OPTION;

Next moved on to set up eclipse and tomcat.

There were lots of problems as things wont work the first time or the second time or even a third time. Tomcat tips: http://www.onjava.com/pub/a/onjava/2003/06/25/tomcat_tips.html too didn't help. I was getting an error: "SEVERE: Error listenerStart". Now the logs do not show the details about the exact problem. Being new to Tomcat, I didn't know how to enable more detailed logs.

After several attempts I uninstalled tomcat 5.5 and installed tomcat 6. This helped. Tomcat 6 comes with a good interface to deploy applications. Also, the logs found at /var/lib/tomcat6/logs also contained the details of the problem with listenerStart. I fixed a few issues then.

I tried to then run tomcat from eclipse. The problem was as a unprivileged user, I could not access tomcat-users.conf. I changed the permissions of tomcat-users.conf and of /var/cache/tomcat6 to enable this (Not to mention, this should not be done on production machines).

No comments: