You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by kccc <ke...@gmail.com> on 2011/12/06 20:35:06 UTC

Null component

Hi,


I'm a new tomcat user and I'm trying to solve this error:
"SEVERE: Null component
Catalina:type=DataSource,path=/myAPP,host=localhost,class=javax.sql.DataSource,name="PGDS/ActivityLogDS"

My tomcat and java version:
apache-tomcat-6.0.16
jdk1.6.0_23

In server.xml, I added:
<Context docBase="myAPP.war" path="/opt/apache-tomcat-6.0.16/webapps/" />
…and restarted tomcat, and received the above error. Tomcat is running
however, but myAPP doesn't work.
I created myApp.war using jar -cvf myAPP.war in
/opt/apache-tomcat-6.0.16/webapps/ and created also WEB-INF/lib.

I've also copied /opt/apache-tomcat-6.0.16/lib contents into
/opt/apache-tomcat-6.0.16/webapps/WEB-INF/lib/ 

Please advice what am I missing. Thank you in advance.

KC


-- 
View this message in context: http://old.nabble.com/Null-component-tp32924620p32924620.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Null component

Posted by Pid <pi...@pidster.com>.
On 06/12/2011 19:35, kccc wrote:
> 
> Hi,
> 
> 
> I'm a new tomcat user and I'm trying to solve this error:
> "SEVERE: Null component
> Catalina:type=DataSource,path=/myAPP,host=localhost,class=javax.sql.DataSource,name="PGDS/ActivityLogDS"
> 
> My tomcat and java version:
> apache-tomcat-6.0.16

Use a newer one, that's so old it's got archaeologists looking for it.

> jdk1.6.0_23
> 
> In server.xml, I added:
> <Context docBase="myAPP.war" path="/opt/apache-tomcat-6.0.16/webapps/" />
> …and restarted tomcat, and received the above error. Tomcat is running
> however, but myAPP doesn't work.

Don't do that.

1. Don't put Context definitions in server.xml

2. If you have the .war in the Host appBase, you don't need to set the
docBase.

3. You won't need to use the path attribute, and it's not intended to
contain the file system path, but the published path.


> I created myApp.war using jar -cvf myAPP.war in
> /opt/apache-tomcat-6.0.16/webapps/ and created also WEB-INF/lib.
> 
> I've also copied /opt/apache-tomcat-6.0.16/lib contents into
> /opt/apache-tomcat-6.0.16/webapps/WEB-INF/lib/ 

Why on earth would you do that?


> Please advice what am I missing. Thank you in advance.

You're clearly missing some idea of what you should be doing.
If you're following a tutorial online, stop doing so - it's complete
nonsense.

Download the latest Tomcat 6.0.35 from the official site:

 http://tomcat.apache.org/download-60.cgi

Look at the enclosed examples, then read this instead:

 http://tomcat.apache.org/tomcat-6.0-doc/appdev/index.html


p


-- 

[key:62590808]