You are not logged in.

#1 2008-07-12 03:30:21

cbmeeks
Member
Registered: 2008-07-12
Posts: 4

tomcat: For the love of GOD please someone help!!

OK, I've been around the Linux block a few times but I am learning Arch Linux.  So far I really enjoy it.

Here is my problem.  I am also learning Java and JSP (using Tomcat).  I am a C#/PHP developer by trade.

Anyway, I've done the following:

pacman -S j2sdk
pacman -S tomcat

Both seem to be installed. 

But when I try to start tomcat with:   /etc/rc.d/tomcat start  I get:
11/07/2008 23:22:14 1986 jsvc error: Cannot locate Java Home

OMG I've done everything I can possible imagine.  The JAVA_HOME environment var is set to:
/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0

TOMCAT_HOME is set to:  /opt/tomcat   

Both of those directories appear to be correct....as in, java and tomcat appear on those two respectively.

I am pulling my hair out over this.

It's very frustrating to come from a PHP world where I can install PHP/Apache/Code Igniter in literally 4 minutes and it works every time.

This very well could be a tomcat issue and maybe I should find some tomcat forums but I thought I would start here first.

Thanks for any help.

cbmeeks

Offline

#2 2008-07-12 03:45:07

peart
Member
From: Kanuckistan
Registered: 2003-07-28
Posts: 510

Re: tomcat: For the love of GOD please someone help!!

Please try just logging out and back in.  That way, the file /etc/profile.d/jdk.sh will get sourced, and your JAVA_HOME should point to /opt/jdk instead of gcc-gcj in /usr/lib/jvm/...

I don't know if gcc-gcj (the /usr/lib/jvm stuff) will still interfere afterward.  I'm hoping it won't.

Offline

#3 2008-07-12 03:47:32

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,384
Website

Re: tomcat: For the love of GOD please someone help!!

When you jdk, a file was put in /etc/profile.d/ which will set the JAVA_HOME variable but you haven't sourced it yet.  The solution is to source /etc/profile or logout and log back in and this will be fixed.

Offline

#4 2008-07-12 03:50:03

cbmeeks
Member
Registered: 2008-07-12
Posts: 4

Re: tomcat: For the love of GOD please someone help!!

Thanks for the reply guys.

I've logged in and out a dozen times and even rebooted the machine.

The only stuff in /opt is tomcat.

I installed the jdk with:   pacman -S j2sdk

I'm wondering if I have all of the JDK stuff installed?

Offline

#5 2008-07-12 03:56:32

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,384
Website

Re: tomcat: For the love of GOD please someone help!!

I'm quite sure that jdk is installed to /opt/java.  Do you not have that?

Offline

#6 2008-07-12 04:04:50

cbmeeks
Member
Registered: 2008-07-12
Posts: 4

Re: tomcat: For the love of GOD please someone help!!

Now I'm getting somewhere!

I reinstalled the jdk with pacman -S j2sdk  (again).

This time I have a /opt/java folder

Now when I try to start tomcat it fails but I get no error message.

Offline

#7 2008-07-12 04:09:34

cbmeeks
Member
Registered: 2008-07-12
Posts: 4

Re: tomcat: For the love of GOD please someone help!!

NEVERMIND!!

When I rebooted I forgot that I set tomcat to autostart.

IT WORKS!

Installing the j2sdk before tomcat must have screwed something up because I got some "conflicts" after I tried to install the j2sdk again.

THANKS GUYS!  You all have been a great help!!!

Offline

Board footer

Powered by FluxBB