mySQL again

2001-03-01 Thread Herchel Wojciech

Hi!
My connectionURL in server.xml now looks like this:
"jdbc:mysql://localhost/auth?user=rootpassword=somepassword"

and tomcat doesn't start up (although there is no error msg or anything) and
when i execute tomcat stop i get the following exception:
org.xml.sax.SAXParseException: Next character must be ";" terminating
reference to entity "password" and a stack trace follows...

why is that?


vVolf

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: log4j usage in tomcat?

2001-03-01 Thread GOMEZ Henri

Within my classes i'm utilizing Log4j logging which requires 
Log4j to be
configured.  I normally configure Log4j within my unit test 
cases, but in the
case of Tomcat, to my pleasant surprise, i found that 
(seemingly) without
configuration, it was handling all my log statements and 
outputing them to the
jvm.stdout file in the logs directory.

Log4j logging is configurable, but i was unable to find the 
location within
Tomcat where they set the Layout pattern.  For that matter, i 
couldn't find
*any* references to Log4j.

Questions:
1. Does Tomcat really use Log4j?
2. Where can i set the layout pattern?

+1

Must be easy to plug log4j in TC 3.3

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




re: mySQL again

2001-03-01 Thread leak

Hi!
My connectionURL in server.xml now looks like this:
"jdbc:mysql://localhost/auth?user=rootpassword=somepassword"

and tomcat doesn't start up (although there is no error msg or anything) and
when i execute tomcat stop i get the following exception:
org.xml.sax.SAXParseException: Next character must be ";" terminating
reference to entity "password" and a stack trace follows...

why is that?

I guess you should escape the "" character in your connectionURL by replacing it with 
"amp;", as the XML parser will parse entities like "lt;" or "quote;" or things like 
that...

Try

jdbc:mysql://localhost/auth?user=rootamp;password=somepassword

instead, that should work...

np: Flanger - Nightbeat 1 (Midnight Sound)

-
Sent through MailGateway - http://www.ssw.uni-linz.ac.at:2000/
Send or read your emails anywhere.
-

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: mySQL again

2001-03-01 Thread Andrew Robson

Hi,
  You might want to try something like the following. It works for me.

 RequestInterceptor
className="org.apache.tomcat.request.JDBCRealm"
debug="99"
  driverName="org.gjt.mm.mysql.Driver"
  connectionURL="jdbc:mysql://localhost/somedb"
  userTable="user_tbl" userNameCol="user_id" userCredCol="psswd"
  userRoleTable="user_role_tbl" roleNameCol="user_role"
  connectionName="someuser"
  connectionPassword="somepassword"
 /

Andrew  

On Thu, 01 Mar 2001, you wrote:
 Hi!
 My connectionURL in server.xml now looks like this:
 "jdbc:mysql://localhost/auth?user=rootpassword=somepassword"
 
 and tomcat doesn't start up (although there is no error msg or anything) and
 when i execute tomcat stop i get the following exception:
 org.xml.sax.SAXParseException: Next character must be ";" terminating
 reference to entity "password" and a stack trace follows...
 
 why is that?
 
 
 vVolf
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
-- 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Life of a class?

2001-03-01 Thread Neil Edney

Hi,

We have implemented a database connection pool class (extract below) and use
the 'getInstance' method to ensuire that there is only one instance created
at any one time.

What we need to know is when will this class be destroyed? Is it went the
server is stopped (or crashed!) or will it timeout after a period of
non-use?

Regards,
Neil


public class DbPool extends Object implements java.io.Serializable {

private static DbPool instance;

public static DbPool getInstance(){
if (instance == null)
instance = new DbPool();
return instance;
}

/** Creates new dbPool */
private DbPool(){

/** dbPool code */

}
}


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Crashing tomcat

2001-03-01 Thread Christopher Miller

I have written a simple servlet to access a database and place the 
results in an html page. However this is regularly crashing the tomcat 
server.

I have tomcat and apache running together with the basic config files, 
but I am not sure where the fault lies (servlet or config file).

the error on tomcat crashing is in the form of

"instruction at xxx referenced memory at xxx. the memory could not be 
written"

Any help would be well received.

Chris


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Life of a class?

2001-03-01 Thread uthay

The class which loads the DbPool class should release it. ie. if there is no
reference to this class and the static instance is also no longer
referencing any object, I beleive the class will be ready for gc.


- Original Message -
From: "Neil Edney" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 10:00 AM
Subject: Life of a class?


 Hi,

 We have implemented a database connection pool class (extract below) and
use
 the 'getInstance' method to ensuire that there is only one instance
created
 at any one time.

 What we need to know is when will this class be destroyed? Is it went the
 server is stopped (or crashed!) or will it timeout after a period of
 non-use?

 Regards,
 Neil


 public class DbPool extends Object implements java.io.Serializable {

 private static DbPool instance;

 public static DbPool getInstance(){
 if (instance == null)
 instance = new DbPool();
 return instance;
 }

 /** Creates new dbPool */
 private DbPool(){

 /** dbPool code */

 }
 }


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Jserv to Tomcat documentations?

2001-03-01 Thread Paolo Fantoli

*This message was transferred with a trial version of CommuniGate(tm) Pro*
Hi,
we are trying to install an application that should work with Apache Web
Server and Apache Jserv using IIS and Tomcat.

We had followed the TOMCAT IIS HOWTO and now IIS and Tomcat cooperates.

Our new problems is that we do not know which are the corrispondensces
between Jserv and Tomcat as for the configurations matter.

What we think is that:
jserv.properties corresponds to tomcat.properties
jserv.conf corresponds to tomcat.conf

while for
 ApacheJserv.jar we do not know the corrispondences.

The directory Apache Jserv1 1.1\servlets we don't know what is the
corrispondences.

Now,
Is there an HowTo or some documentations like that explaining easly
how to migrate from Jserv to Tomcat?

Regards,

Paolo






-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




AW: Crashing tomcat

2001-03-01 Thread Ralph Einfeldt

Give a bit more info of your environment.
(OS, Apache version, Tomcat version, which connector mod_jserv or mod_jk)
In which file is the error reported ? Is there more information available 
in the log ? (With the informations you provided it's just guesswork,
to decide if that's an error of apache, the connector, tomcat or some thing
outside.


It may be an error in your JVM or a native library.

- Look if there is a newer version for your jdk
- If not (or if it doesn't change anything)
  try the JDK of a different vendor.

 -Ursprngliche Nachricht-
 Von: Christopher Miller [mailto:[EMAIL PROTECTED]]
 Gesendet: Donnerstag, 1. Mrz 2001 11:16
 An: [EMAIL PROTECTED]
 Betreff: Crashing tomcat
 
 
 I have written a simple servlet to access a database and place the 
 results in an html page. However this is regularly crashing 
 the tomcat 
 server.
 
 I have tomcat and apache running together with the basic 
 config files, 
 but I am not sure where the fault lies (servlet or config file).
 
 the error on tomcat crashing is in the form of
 
 "instruction at xxx referenced memory at xxx. the memory could not be 
 written"
 
 Any help would be well received.
 
 Chris
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
 
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Crashing tomcat

2001-03-01 Thread dick

Hi Christopher,

I also use some taglib to query a database (mysql) and then show the result
in html back.
It occasionally crash, I don't know the reason too. So, let's figure the
reason out !


Regards

Dick Poon
- Original Message -
From: "Christopher Miller" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 6:16 PM
Subject: Crashing tomcat


 I have written a simple servlet to access a database and place the
 results in an html page. However this is regularly crashing the tomcat
 server.

 I have tomcat and apache running together with the basic config files,
 but I am not sure where the fault lies (servlet or config file).

 the error on tomcat crashing is in the form of

 "instruction at xxx referenced memory at xxx. the memory could not be
 written"

 Any help would be well received.

 Chris


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Tomcat Crashes

2001-03-01 Thread Kishor K

hi,
 I have Tomcat 3.1 and jdk 1.2.2 on  TWO Windows NT machines.
Both the machines are loaded with the same code,same database.
 But on one machine it is causing Dr.Watson error 2-3 times a day whereas
the other one is working properly.

 Could you help in anyway on this?

 thanks in advance
 kishor




_
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Crashing tomcat

2001-03-01 Thread Stefán F. Stefánsson

Hello..

Are you guys running windows?  If so, are you getting the popup window
with the red cross and an ok button saying that some memory address
can't be read?

If that is the case I would bet that you have found a bug in the JVM.
The reason for that being that Java doesn't have any pointers so there
is no way that any of your code could generate this message.  Java would
not allow you to write into an illegal memory address, this window would
only appear if the JVM was doing something like that (or perhaps the
JDBD driver, depending on what type of driver you are using).

Are you guys using any native code (dll's or system calls)?  What type
of JDBC driver are you using (Type 4 is pure java and should therefore
not be able to cause this behavior but Type 1 (and maybe Type 2 too) may
rely on native code and could therefore cause the error message to
occur.

Hope this gives you guys a hint,
Regards, Stefan.

-Original Message-
From: dick [mailto:[EMAIL PROTECTED]]
Sent: 1. mars 2001 10:50
To: [EMAIL PROTECTED]
Subject: Re: Crashing tomcat


Hi Christopher,

I also use some taglib to query a database (mysql) and then show the
result
in html back.
It occasionally crash, I don't know the reason too. So, let's figure the
reason out !


Regards

Dick Poon
- Original Message -
From: "Christopher Miller" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 6:16 PM
Subject: Crashing tomcat


 I have written a simple servlet to access a database and place the
 results in an html page. However this is regularly crashing the tomcat
 server.

 I have tomcat and apache running together with the basic config files,
 but I am not sure where the fault lies (servlet or config file).

 the error on tomcat crashing is in the form of

 "instruction at xxx referenced memory at xxx. the memory could not be
 written"

 Any help would be well received.

 Chris


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




memory and/or ms problem

2001-03-01 Thread Gerd Trautner

Hi tomcat-users,

I am having some memory related troubles with my servlets running on
tomcat 3.2.1 on an win nt 4 workstation machine.
I read all previous messages in the list with the term "memory" in it,
but everything i try does not help.

problem: the memory consumption of the java.exe increases slightly, the
over all memory consumption of the system increases fast and memory is
not released. after a week (and about 400 hits or so) the server runs
out of memory (tomcat gives a OutOfMemoryError and quits).

what i did:
- set java max heap size (nothing changed)
- set max_threads (30), max_spare_threads(20) and min_spare_threads(5)
  for both http and https ConnectionHandler
- set session-timeout to 1 Minute
- added System.gc() to end of every servlet

my application uses servlets and mysql, i close every mysql connection
and i am not able to find anything i could change to get the memory
freed.

I also use ms-stresstool and i can simulate this memory-problem.

could anyone give me some assistance please?

thanks,
Gerd



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Tomcat class loader

2001-03-01 Thread Chris Haynes

Uthay,

I still think you've got a basic JAVA coding error - a class mismatch
in a .jsp called something like CampView.jsp


Look carefully at line 103 in the file below in the 'work'
subdirectory,
paying special attention to any assignments or method calls in *your*
code that show up in that line.

_0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_jsp_5.java

The run-time system is finding an instance of PRDashBoard.PRContext
at that point when it is expecting something else.

Only you can tell:
(a) what class your code is actually expecting at that point,
(b) Why a PRDashBoard.PRContext is getting there and where it came
from,
c) Why the class that should there isn't!

Chris




- Original Message -
From: "uthay" [EMAIL PROTECTED]
To: "Chris Haynes" [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Wednesday, February 28, 2001 11:36 AM
Subject: Re: Tomcat class loader


 Chris
 Jasper seems to work fine. It detects the changes and recompiles the
java
 file.
 I have also tried removing all files inside the work directory.

 But my problem seems to persist.
 It is to do with a session bean class I have.
 It is not reloading at all, even after you change your class file.
 We tried it in another linux machine
 When restarted (tomcat) some time it seems to throw the following
exception


 Internal Servlet Error:

 javax.servlet.ServletException: PRDashBoard.PRContext
  at

org.apache.jasper.runtime.PageContextImpl.handlePageException(PageCont
extImp
 l.java:459)
  at

jsp.PRJsp._0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_js
p_5._j

spService(_0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_js
p_5.ja
 va:436)
  at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
  at

org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServ
let.ja
 va:177)
  at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:31
8)
  at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
  at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:40
4)
  at org.apache.tomcat.core.Handler.service(Handler.java:286)
  at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
  at

org.apache.tomcat.core.ContextManager.internalService(ContextManager.j
ava:79
 7)
  at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
  at

org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConn
ection
 (Ajp12ConnectionHandler.java:166)
  at

org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:4
16)
  at

org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:
498)
  at java.lang.Thread.run(Thread.java:484)

 Root cause:
 java.lang.ClassCastException: PRDashBoard.PRContext
  at

jsp.PRJsp._0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_js
p_5._j

spService(_0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_js
p_5.ja
 va:103)
  at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
  at

org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServ
let.ja
 va:177)
  at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:31
8)
  at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
  at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:40
4)
  at org.apache.tomcat.core.Handler.service(Handler.java:286)
  at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
  at

org.apache.tomcat.core.ContextManager.internalService(ContextManager.j
ava:79
 7)
  at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
  at

org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConn
ection
 (Ajp12ConnectionHandler.java:166)
  at

org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:4
16)
  at

org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:
498)
  at java.lang.Thread.run(Thread.java:484)


 Uthay


 - Original Message -
 From: "Chris Haynes" [EMAIL PROTECTED]
 To: "uthay" [EMAIL PROTECTED]
 Sent: Tuesday, February 27, 2001 6:48 PM
 Subject: Re: Tomcat class loader


  Uthay,
 
  I had a slightly different problem in mind - having to remember
which
  classes will and won't be re-loaded automatically and hence
whether or
  not I have to restart tomcat to see the effect of a change in
source
  code.
 
  I'm not quite sure what your "stuck" class is all about. If the
tomcat
  JSP compiler mechanism (jikes, is it?) has compiled it, I believe
  there will be a .class file in a subdirectory of TOMCAT_HOME/work
with
  a name made up of your class name embedded in many, many other
  characters.
 
  Not sure if this is addressing your problem, but this is 

Re: memory and/or ms problem

2001-03-01 Thread Oleg L. Sverdlov

I have the same problem too. I use Windows 2000 Server, Tomcat 3.2.1 and 
isapi_connect.dll

I've already asked this question on the list, and nobody seems to know.

Oleg L. Sverdlov
Web Development Dept.

Netmount Networks 
Raanana, Israel. 

http://www.netmount.com
Phone: +972-9-745-5220
Fax: +972-9-745-2521

- Original Message - 
From: "Gerd Trautner" [EMAIL PROTECTED]
To: "tomcat-user" [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 1:16 PM
Subject: memory and/or ms problem


 Hi tomcat-users,
 
 I am having some memory related troubles with my servlets running on
 tomcat 3.2.1 on an win nt 4 workstation machine.
 I read all previous messages in the list with the term "memory" in it,
 but everything i try does not help.
 
 problem: the memory consumption of the java.exe increases slightly, the
 over all memory consumption of the system increases fast and memory is
 not released. after a week (and about 400 hits or so) the server runs
 out of memory (tomcat gives a OutOfMemoryError and quits).
 
 what i did:
 - set java max heap size (nothing changed)
 - set max_threads (30), max_spare_threads(20) and min_spare_threads(5)
   for both http and https ConnectionHandler
 - set session-timeout to 1 Minute
 - added System.gc() to end of every servlet
 
 my application uses servlets and mysql, i close every mysql connection
 and i am not able to find anything i could change to get the memory
 freed.
 
 I also use ms-stresstool and i can simulate this memory-problem.
 
 could anyone give me some assistance please?
 
 thanks,
 Gerd




Q: logging requests to servlet?

2001-03-01 Thread Oleg L. Sverdlov



Hello.

When using ISAPI redirector for Tomcat, all 
requests to servlets are written in IIS log file as
"... GET /jakarta/isapi_connect.dll ..." 
.

How to configure tomcat to see servlet name and 
parameters passed?


Thanks.

Oleg L. SverdlovWeb Development 
Dept.

Netmount Networks Raanana, Israel. 


http://www.netmount.comPhone: 
+972-9-745-5220Fax: +972-9-745-2521


Log traffic to webapp

2001-03-01 Thread Stefán F. Stefánsson

Hello.  I'm wondering if I can log all traffic coming to a webapp?  I'm
using EmbeddedTomcat so no use in server.xml.  Anyone know a convenient
way?

Kind regards, Stefan.


Stefan Freyr Stefansson
Software Developer
deCODE Genetics, Inc.
http://www.decode.com

Phone: (+354) 570 2854
GSM:   (+354) 861 1718
Fax:   (+354) 491 3782
 Stefan Stefansson.vcf 


BEGIN:VCARD
VERSION:2.1
N;ENCODING=QUOTED-PRINTABLE:;=01
REV:20001030T115142Z
END:VCARD


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]


Re: Tomcat class loader

2001-03-01 Thread uthay


 Chris,
Thanks for your help

I use few beans within a page.
And if there is any class cast exceptions during the compilaion of  that jsp
I will get a that specific class cast exception not necessarily the jsp file
class. More over it doesn't happen specific to a jsp page.
As I said, I am only getting this error occasionally.
Every time I change my PRContext bean class the tomcat throws this
exception. And we have to restart it. Some time for nor reason (probably a
configuration error) tomcat holds onto the older version of the bean class.
As you suggested I suspected an application fault at the beginning and
traced the java file. It looks fine.
the line number indicates a problem about page forwarding.

if (true) {
String __url = (String) "lobCountryView.jsp";
// Forward to the above url
out.clear();
pageContext.forward( __url);
return;
   }

I can't spot anything.
If there is an error why work in the first place.

At the moment application seems to work fine. (Since I am not modifying the
bean class)
I intend to get into this more detaily soon.
If you have any thought on this please share it.

Thanks again
Uthay










- Original Message -
From: "Chris Haynes" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 11:37 AM
Subject: Re: Tomcat class loader


 Uthay,

 I still think you've got a basic JAVA coding error - a class mismatch
 in a .jsp called something like CampView.jsp


 Look carefully at line 103 in the file below in the 'work'
 subdirectory,
 paying special attention to any assignments or method calls in *your*
 code that show up in that line.

 _0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_jsp_5.java

 The run-time system is finding an instance of PRDashBoard.PRContext
 at that point when it is expecting something else.

 Only you can tell:
 (a) what class your code is actually expecting at that point,
 (b) Why a PRDashBoard.PRContext is getting there and where it came
 from,
 c) Why the class that should there isn't!

 Chris




 - Original Message -
 From: "uthay" [EMAIL PROTECTED]
 To: "Chris Haynes" [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Sent: Wednesday, February 28, 2001 11:36 AM
 Subject: Re: Tomcat class loader


  Chris
  Jasper seems to work fine. It detects the changes and recompiles the
 java
  file.
  I have also tried removing all files inside the work directory.
 
  But my problem seems to persist.
  It is to do with a session bean class I have.
  It is not reloading at all, even after you change your class file.
  We tried it in another linux machine
  When restarted (tomcat) some time it seems to throw the following
 exception
 
 
  Internal Servlet Error:
 
  javax.servlet.ServletException: PRDashBoard.PRContext
   at
 
 org.apache.jasper.runtime.PageContextImpl.handlePageException(PageCont
 extImp
  l.java:459)
   at
 
 jsp.PRJsp._0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_js
 p_5._j
 
 spService(_0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_js
 p_5.ja
  va:436)
   at
 org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
   at
 
 org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServ
 let.ja
  va:177)
   at
 org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:31
 8)
   at
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
   at
 org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:40
 4)
   at org.apache.tomcat.core.Handler.service(Handler.java:286)
   at
 org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
   at
 
 org.apache.tomcat.core.ContextManager.internalService(ContextManager.j
 ava:79
  7)
   at
 org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
   at
 
 org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConn
 ection
  (Ajp12ConnectionHandler.java:166)
   at
 
 org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:4
 16)
   at
 
 org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:
 498)
   at java.lang.Thread.run(Thread.java:484)
 
  Root cause:
  java.lang.ClassCastException: PRDashBoard.PRContext
   at
 
 jsp.PRJsp._0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_js
 p_5._j
 
 spService(_0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_js
 p_5.ja
  va:103)
   at
 org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
   at
 
 org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServ
 let.ja
  va:177)
   at
 org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:31
 8)
   at
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
   at
 

referer

2001-03-01 Thread Carlos

can any body say me how can i in a JSP page detect which is the referer
page? from which page comes the visit?
thanks
Carlos


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Tomcat Crashes

2001-03-01 Thread Randy Layman


Two common causes of crashes, in my experience, are using the
JDBC-ODBC bridge (its not thread safe and when concurrent access occurs it
crashes the JVM).  The other is in the JIT complilation.  I've had a lot
less trouble with the newer JDKs (1.2.2_007) than the older ones (1.2.2_002
and 004).

The solution to the second problem is pretty obvious - upgrade your
JVM or turn off JIT.  The first solution you can either serialize requests
or find new database drivers.

If your problem isn't one of these two things, I would suggest
looking where you are using native code as well as the differences between
the two machines (including usage, it the one with the higher load crashes
more frequently then the problem is probably something you are using isn't
thread safe)

Randy

-Original Message-
From: Kishor K [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 5:57 AM
To: Tomcat User Mailing List
Subject: Tomcat Crashes


hi,
 I have Tomcat 3.1 and jdk 1.2.2 on  TWO Windows NT machines.
Both the machines are loaded with the same code,same database.
 But on one machine it is causing Dr.Watson error 2-3 times a day whereas
the other one is working properly.

 Could you help in anyway on this?

 thanks in advance
 kishor




_
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Problem with cache

2001-03-01 Thread William Brogden



 matteo belloni wrote:
 
 I've a servlet that write on a file.
 If the Tomcat is running the first time the application rewrite the
 file, the other time this file is appended but, If I first shutdown
 the webserver, the information in a file isn't appended and the
 application function correctly.
 This appen because this file is keeping in the web server's cache.
 How can I solve this problem and writing every time on a file instead
 of append the information? I must modify web.xml? And how?
 Please help me.
 Thanks in advance

Sounds to me like you are not flushing and/or closing the file.

-- 
WBB - [EMAIL PROTECTED]
Java Cert mock exams http://www.lanw.com/java/javacert/
Author of Java Developer's Guide to Servlets and JSP 
ISBN 0-7821-2809-2

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Servlet output into Jsp

2001-03-01 Thread Manuel Alzola



Hello.

I would like to insert the output of a servlet into my jsp 
page.I've seen a custom tag in Jrun to do that(servlet)
Is there any equivalent in tomcat? Is it part of the 
spec?

Thanks in advance
Manuel Alzola



Need Help on Tomcat with NES

2001-03-01 Thread Satheesh . Krishnamurthy

Hi,

This is Satheesh working for IT Solutions as Manger Infrastructure.

I am trying to install Tomcat server and integrate with Netscape Enterprise
Server. The Tomcat webserver working fine and the SnoopServlet also comes
up, and NES webserver is working fine. But when call the servlet it says
Not Found.

Here is my obj.conf file pl check this and let me know is something wrong
in this config.

(See attached file: obj.conf)


Thanks in Advance

Satheesh

 obj.conf

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]


Crashing tomcat

2001-03-01 Thread Christopher Miller

thanks for all the replies. 

It turns out as suggested that it was the version of jdk / jre. I now 
have jdk1.3 as opposed to jdk1.2.2 and jre 1.3. and more importantly no 
crashing of tomcat


thanks

chris


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Tomcat Session Problem!

2001-03-01 Thread Moin Anjum H.

Hi All,

Thanks a lot in advance. I have a grave problem with tomcat. I am not
able to kill session created with HttpSession Mysession =
request.getSession( true );

At the end even if i execute Mysession.invalidate(); still in my
next session i get the values of when i call
MySession.getAttribute("mystring");

How do i kill the session?

FYI I am using JDK1.3 and Tomcat 3.1/3.2

Best Regards
Moin.


_
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Problem with cache

2001-03-01 Thread matteo belloni

No  I close it and after rewriting  I deleted it and this file appear really
deleted but Tomcat mantain it in cache so my deletion is inutil.
Thanks
Theo
- Original Message -
From: "William Brogden" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 1:52 PM
Subject: Re: Problem with cache




  matteo belloni wrote:
 
  I've a servlet that write on a file.
  If the Tomcat is running the first time the application rewrite the
  file, the other time this file is appended but, If I first shutdown
  the webserver, the information in a file isn't appended and the
  application function correctly.
  This appen because this file is keeping in the web server's cache.
  How can I solve this problem and writing every time on a file instead
  of append the information? I must modify web.xml? And how?
  Please help me.
  Thanks in advance

 Sounds to me like you are not flushing and/or closing the file.

 --
 WBB - [EMAIL PROTECTED]
 Java Cert mock exams http://www.lanw.com/java/javacert/
 Author of Java Developer's Guide to Servlets and JSP
 ISBN 0-7821-2809-2

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Generating a random alphanumeric string

2001-03-01 Thread Cato, Christopher

Hello, can anyone show me an example or give me a clue about how
to generate a random alphanumeric string of lets say 16-32 chars?
TomCat is obviously doing it for the session ids, but how would I
do the same in a servlet?

Regards,

Christopher Cato

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Tomcat class loader

2001-03-01 Thread uthay


I think you are right.

 You don't have persistent beans in there which are storing old copies
 of the class you are changing, do you?

I have a session bean which is serialised as bean should be.

 It's possible that a class cast exception is being thrown if a new
 version arrives where an old one is expected, or vice versa - but I'm
 guessing now

On changing its version tomcat throws cast exception

Any body else got a similar problem?

Will it be changed in the future version?




 Uthay,

 I can't see anything either, unless pageContext is changing
 dynamically.

 You don't have persistent beans in there which are storing old copies
 of the class you are changing, do you?

 The reason I don't use RMI or anything based on it is because coping
 with newer versions of a class - even if logicaly the same - seems
 really tricky.

 It's possible that a class cast exception is being thrown if a new
 version arrives where an old one is expected, or vice versa - but I'm
 guessing now.

 Don't think I can be of any further help to you.

 Best of luck!

 Chris



- Original Message -
From: "uthay" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]; "Chris Haynes"
[EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 12:06 PM
Subject: Re: Tomcat class loader



  Chris,
 Thanks for your help

 I use few beans within a page.
 And if there is any class cast exceptions during the compilaion of  that
jsp
 I will get a that specific class cast exception not necessarily the jsp
file
 class. More over it doesn't happen specific to a jsp page.
 As I said, I am only getting this error occasionally.
 Every time I change my PRContext bean class the tomcat throws this
 exception. And we have to restart it. Some time for nor reason (probably a
 configuration error) tomcat holds onto the older version of the bean
class.
 As you suggested I suspected an application fault at the beginning and
 traced the java file. It looks fine.
 the line number indicates a problem about page forwarding.

 if (true) {
 String __url = (String) "lobCountryView.jsp";
 // Forward to the above url
 out.clear();
 pageContext.forward( __url);
 return;
}

 I can't spot anything.
 If there is an error why work in the first place.

 At the moment application seems to work fine. (Since I am not modifying
the
 bean class)
 I intend to get into this more detaily soon.
 If you have any thought on this please share it.

 Thanks again
 Uthay










 - Original Message -
 From: "Chris Haynes" [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Thursday, March 01, 2001 11:37 AM
 Subject: Re: Tomcat class loader


  Uthay,
 
  I still think you've got a basic JAVA coding error - a class mismatch
  in a .jsp called something like CampView.jsp
 
 
  Look carefully at line 103 in the file below in the 'work'
  subdirectory,
  paying special attention to any assignments or method calls in *your*
  code that show up in that line.
 
  _0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_jsp_5.java
 
  The run-time system is finding an instance of PRDashBoard.PRContext
  at that point when it is expecting something else.
 
  Only you can tell:
  (a) what class your code is actually expecting at that point,
  (b) Why a PRDashBoard.PRContext is getting there and where it came
  from,
  c) Why the class that should there isn't!
 
  Chris
 
 
 
 
  - Original Message -
  From: "uthay" [EMAIL PROTECTED]
  To: "Chris Haynes" [EMAIL PROTECTED]
  Cc: [EMAIL PROTECTED]
  Sent: Wednesday, February 28, 2001 11:36 AM
  Subject: Re: Tomcat class loader
 
 
   Chris
   Jasper seems to work fine. It detects the changes and recompiles the
  java
   file.
   I have also tried removing all files inside the work directory.
  
   But my problem seems to persist.
   It is to do with a session bean class I have.
   It is not reloading at all, even after you change your class file.
   We tried it in another linux machine
   When restarted (tomcat) some time it seems to throw the following
  exception
  
  
   Internal Servlet Error:
  
   javax.servlet.ServletException: PRDashBoard.PRContext
at
  
  org.apache.jasper.runtime.PageContextImpl.handlePageException(PageCont
  extImp
   l.java:459)
at
  
  jsp.PRJsp._0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_js
  p_5._j
  
  spService(_0002fjsp_0002fPRJsp_0002flobCampView_0002ejsplobCampView_js
  p_5.ja
   va:436)
at
  org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
  
  org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServ
  let.ja
   va:177)
at
  org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:31
  8)
at
  org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
  org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:40
  4)
at 

ODP: Generating a random alphanumeric string

2001-03-01 Thread Herchel Wojciech

see tomcat sources, org.apache.tomcat.util.SessionIdGenerator namely

vVolf


 -Oryginalna wiadomooe-
 Od: Cato, Christopher [mailto:[EMAIL PROTECTED]]
 Wysano: 1 marca 2001 15:05
 Do: '[EMAIL PROTECTED]'
 Temat: Generating a random alphanumeric string
 
 
 Hello, can anyone show me an example or give me a clue about how
 to generate a random alphanumeric string of lets say 16-32 chars?
 TomCat is obviously doing it for the session ids, but how would I
 do the same in a servlet?
 
 Regards,
 
 Christopher Cato
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




[TC4] Bug? Authentication problem with HTTP 1.1 client (MSIE)

2001-03-01 Thread Jason Harrop

Hi

I'm using TC4 built from CVS on 17 Feb, and I'm scratching my head about 
a strange problem when i try and access 2 webapps which have the same 
realm name in their web.xml file, as in:

   login-config
 auth-methodBASIC/auth-method
 realm-namemyRealm/realm-name

If I visit these webapps using a HTTP 1.0 client (eg NS 4.7, or IE 5 or 
5.5 with "Use HTTP 1.1" deselected), i get the expected sequence of a 
401 error, at which point the browser presents the authentication 
dialog; then on subsequent protected pages, the browser responds to the 
401 error with authentication information without involving the users.

If I visit these webapps using either IE 5 or 5.5 in their default HTTP 
1.1 enabled mode, then what happens is this:

For IE 5.5, when i visit the first page, i am asked to authenticate. 
Then, when i visit the second page (on my setup, this is in a second 
webapp, but with the same realm-name), i am presented with a blank 
screen.  The tomcat logs show the 401 response, but they DO NOT show a 
subsequent request in which the authentication information is provided 
by the browser.

HOWEVER, according to my packet sniffer, that request _is_ being sent, 
however Tomcat never responds to it:

  G E  T / T  e s t D  r i  v e  / p  r o  t e  c t  e d / s  h o  w 
H  o m  e D  i r  e c  t o r yH  T T  P /  1 .  1

  H T  T P  / 1  . 1   4  0 1U  n a  u t  h o  r i  z e  d
  W W  W -  A u  t h e n  t i  c a  t e  :B a  s i  cr e  a l  m 
=  " m  y R  e a  l m  "

  G E  T/ T  e s t D  r i  v e  / p  r o  t e  c t  e d / s  h o  w 
H  o m  e D  i r  e c  t o r yH  T T  P /  1 .  1
  A u  t h  o r i z  a t  i o  n :B  a s  i cZ n J  l Z  D p  u 
Z  X J  r

  [Tomcat sends the page]

  G E  T/ S  m a r t  P r  e c  e d  e n  t S  e r  v e
  r /  a s  k I  n t  e r  v i  e w  P r
  e f  e r  e n  c e  s ?  I D  = %  2 F
  f i  l e  s %  2 F  d e  m o  n s  t r
  a t  i o  n %  2 F  T e  s t  2 S  A f
  o r  R e  p o  s i  t o  r y  . x  m l
   r  e p  o s  i t  o r  y n  a m  e =
  T e  s t  D r  i v  eH T  T P  / 1
  . 1

H T  T P  / 1  . 1  4  0 1U  n a  u t  h o  r i  z e d
W W  W -  A u  t h e n  t i  c a  t e  :B a  s i  c   r e  a l  m = 
  " m  y R  e a  l m  "

  G E  T/ S  m a r t  P r  e c  e d  e n  t S  e r  v e
  r /  a s  k I  n t  e r  v i  e w  P r
  e f  e r  e n  c e  s ?  I D  = %  2 F
  f i  l e  s %  2 F  d e  m o  n s  t r
  a t  i o  n %  2 F  T e  s t  2 S  A f
  o r  R e  p o  s i  t o  r y  . x  m l
   r  e p  o s  i t  o r  y n  a m  e =
  T e  s t  D r  i v  eH T  T P  / 1
  . 1

  A u  t h  o r  i z  a t  i o  n :B a s  i cZ  n J  l Z  D p  u 
Z  X J r

Clicking refresh successfully grabs the page for me, without me having 
to type any authentication info again. So i think this might a bug in 
Tomcat 4's HTTP 1.1 connector (since things are okay with a 1.0 client)?

With IE 5, the second time Tomcat sends a 401, IE asks me to 
authenticate, even though the WWW-Authenticate header is the same one it 
has seen before.  This looks to me like a bug in IE 5.

Any thoughts?  BTW, i'm not using the single sign on support valve.

thanks

Jason





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Create a Context aother than webapps

2001-03-01 Thread Chris Andreou

I have a problem executing my servlets in a diffrent context other than
webapps - using a absolute path instead of relative. I have the followoing
definition in server.xml :
server.xml
---
Context path="/devexamples" 
 docBase="e:/Apachegroup/Apache/htdocs/webdir/examples" 
 crossContext="false"
 debug="0" 
 reloadable="true"  
/Context
--- 

I am using Tomcat 3.2.1 and Apache 1.3.14 with mod_jk . The configuration in
httpd.conf is the following: 

Alias /devexamples "e:/Apachegroup/Apache/htdocs/webdir/examples"
Directory  "e:/ApacheGroup/Apache/www/htdocs/webdir/examples"
Options Indexes FollowSymLinks
DirectoryIndex index.htm
/Directory

JkMount /devexamples/*.jsp apj12://trw02:8007/devexamples
JkMount /devexamples/servlet/* apj12://trw02:8007/devexamples
-- 
I get the following error in my log file: 
[jk_uri_worker_map.c (434)]: jk_uri_worker_map_t::map_uri_to_worker, done
without a match
[jk_uri_worker_map.c (344)]: Into jk_uri_worker_map_t::map_uri_to_worker
[jk_uri_worker_map.c (434)]: jk_uri_worker_map_t::map_uri_to_worker, done
without a match
[jk_uri_worker_map.c (344)]: Into jk_uri_worker_map_t::map_uri_to_worker
[jk_uri_worker_map.c (406)]: jk_uri_worker_map_t::map_uri_to_worker, Found a
match apj12://trw02:8007/devexamples
[jk_worker.c (123)]: Into wc_get_worker_for_name
apj12://trw02:8007/devexamples
[jk_worker.c (127)]: wc_get_worker_for_name, done did not found a worker


The properties of the worker.properties are : 

wrapper.tomcat_home=put your Tomcat home
wrapper.java_home=put your Java home
wrapper.stdout=$(wrapper.tomcat_home)\logs\jvm.stdout
wrapper.stderr=$(wrapper.tomcat_home)\logs\jvm.stderr
wrapper.ld_path=d:\
wrapper.ld_path=c:\
wrapper.class_path=$(wrapper.tomcat_home)\classes
wrapper.class_path=$(wrapper.tomcat_home)\lib\jaxp.jar
wrapper.class_path=$(wrapper.tomcat_home)\lib\parser.jar
wrapper.class_path=$(wrapper.tomcat_home)\lib\webserver.jar
wrapper.class_path=$(wrapper.tomcat_home)\lib\servlet.jar
wrapper.class_path=$(wrapper.tomcat_home)\lib\jasper.jar

wrapper.class_path=$(wrapper.java_home)\lib\classes.zip

wrapper.javabin=$(wrapper.java_home)\bin\java.exe
wrapper.startup_class=org.apache.tomcat.startup.Tomcat
wrapper.server_xml=$(wrapper.tomcat_home)\conf\server.xml
wrapper.shutdown_port=8007
wrapper.shutdown_protocol=ajp12
wrapper.cmd_line=$(wrapper.javabin) -classpath $(wrapper.class_path)
$(wrapper.startup_class) -config $(wrapper.server_xml) -home
$(wrapper.tomcat_home)


Any help would be very appreciated. 

Thanks in advance

Chris

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Generating a random alphanumeric string

2001-03-01 Thread Anil

Cato,
Here is code that I tried out for generating a user id using the user name
I have to pass a string and it returns a 8 digit alpha numeric
Hope it helps,

Anil


  public static String getCode(String text){
 String code = "";


text = text.trim();
if(text.length()1){
return null;
}
text = text.toUpperCase();
if(random==null){
random = new java.util.Random();
}
String code_temp = "";
 int no_of_chars = 3 ; //not of chars from text

for(int i=0;ino_of_chars;i++){
  code_temp =
String.valueOf(text.charAt(random.nextInt(text.length(;
  if(code_temp.equals(" ")){
i--;
   }else{
code = code + code_temp;
   }
}

code = code + java.lang.String.valueOf(random.nextInt(1));
java.util.Date date = new java.util.Date();
code = code + java.lang.String.valueOf(date.getDate());
}catch(Exception e){
return null;
}
return code;

}





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




useing beans.

2001-03-01 Thread Pater Pandoson

Hello

My jsp pages work fine but when I try to use beans I get this

 2001-03-01 12:10:19 - Ctx(  ): Exception in: R(  + /test.jsp + null) -
javax.servlet.ServletException: try to access class NormalizeText from
class _0002ftest_0002ejsptest_jsp_4
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:399)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)

at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)

at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:210)

at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)

at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)

at java.lang.Thread.run(Thread.java:479)
Root cause:
java.lang.IllegalAccessError: try to access class NormalizeText from
class _0002ftest_0002ejsptest_jsp_4
at
_0002ftest_0002ejsptest_jsp_4._jspService(_0002ftest_0002ejsptest_jsp_4.java:62)

at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:177)

at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:318)

at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)

at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)

at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:210)

at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)

at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)

at java.lang.Thread.run(Thread.java:479)


The bean is in the classes dir and compled fine

import java.beans.*;


class NormalizeText{
private String text;

public void setText(String text){
 this.text = text;
}

public String getText(){
 return text;
}

}


and the jsp page looks like this

jsp:useBean id="TN" scope="session" class="NormalizeText" /
jsp:setProperty name="TN" property="text" value="what is the prob?" /


So can any one tell me what I am doing wrong.

Thanks.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Problem with cache

2001-03-01 Thread William Brogden

Tomcat does not cache files as such. Your problem must
come from a different source.

matteo belloni wrote:
 
 No  I close it and after rewriting  I deleted it and this file appear really
 deleted but Tomcat mantain it in cache so my deletion is inutil.
 Thanks
 Theo
 - Original Message -
 From: "William Brogden" [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Thursday, March 01, 2001 1:52 PM
 Subject: Re: Problem with cache
 
 
 
   matteo belloni wrote:
  
   I've a servlet that write on a file.
   If the Tomcat is running the first time the application rewrite the
   file, the other time this file is appended but, If I first shutdown
   the webserver, the information in a file isn't appended and the
   application function correctly.
   This appen because this file is keeping in the web server's cache.
   How can I solve this problem and writing every time on a file instead
   of append the information? I must modify web.xml? And how?
   Please help me.
   Thanks in advance
 
  Sounds to me like you are not flushing and/or closing the file.
 
  --
  WBB - [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Problem with cache

2001-03-01 Thread matteo belloni

Thanks
Theo
- Original Message -
From: "William Brogden" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 3:34 PM
Subject: Re: Problem with cache


 Tomcat does not cache files as such. Your problem must
 come from a different source.

 matteo belloni wrote:
 
  No  I close it and after rewriting  I deleted it and this file appear
really
  deleted but Tomcat mantain it in cache so my deletion is inutil.
  Thanks
  Theo
  - Original Message -
  From: "William Brogden" [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Sent: Thursday, March 01, 2001 1:52 PM
  Subject: Re: Problem with cache
 
  
  
matteo belloni wrote:
   
I've a servlet that write on a file.
If the Tomcat is running the first time the application rewrite the
file, the other time this file is appended but, If I first shutdown
the webserver, the information in a file isn't appended and the
application function correctly.
This appen because this file is keeping in the web server's cache.
How can I solve this problem and writing every time on a file
instead
of append the information? I must modify web.xml? And how?
Please help me.
Thanks in advance
  
   Sounds to me like you are not flushing and/or closing the file.
  
   --
   WBB - [EMAIL PROTECTED]

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: useing beans.

2001-03-01 Thread Hawkins, Keith (Keith)

Did you try changing the class to have public access?
This is just a hunch but the default constructor on a
non-public class may not be accessible given the IllegalAccess
exception that is being thrown.
-Keith


-Original Message-
From: Pater Pandoson [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 9:26 AM
To: [EMAIL PROTECTED]
Subject: useing beans.


Hello

My jsp pages work fine but when I try to use beans I get this

 2001-03-01 12:10:19 - Ctx(  ): Exception in: R(  + /test.jsp + null) -
javax.servlet.ServletException: try to access class NormalizeText from
class _0002ftest_0002ejsptest_jsp_4
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:399)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)

at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:79
7)

at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC
onnectionHandler.java:210)

at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)

at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)

at java.lang.Thread.run(Thread.java:479)
Root cause:
java.lang.IllegalAccessError: try to access class NormalizeText from
class _0002ftest_0002ejsptest_jsp_4
at
_0002ftest_0002ejsptest_jsp_4._jspService(_0002ftest_0002ejsptest_jsp_4.java
:62)

at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja
va:177)

at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:318)

at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)

at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:79
7)

at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC
onnectionHandler.java:210)

at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)

at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)

at java.lang.Thread.run(Thread.java:479)


The bean is in the classes dir and compled fine

import java.beans.*;


class NormalizeText{
private String text;

public void setText(String text){
 this.text = text;
}

public String getText(){
 return text;
}

}


and the jsp page looks like this

jsp:useBean id="TN" scope="session" class="NormalizeText" /
jsp:setProperty name="TN" property="text" value="what is the prob?" /


So can any one tell me what I am doing wrong.

Thanks.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: useing beans.

2001-03-01 Thread William Brogden



Pater Pandoson wrote:
 
 Hello
 
 My jsp pages work fine but when I try to use beans I get this
 
  2001-03-01 12:10:19 - Ctx(  ): Exception in: R(  + /test.jsp + null) -
 javax.servlet.ServletException: try to access class NormalizeText from
 class _0002ftest_0002ejsptest_jsp_4
 at
 org.apache.jasper.servlet.JspServlet.service(JspServlet.java:399)

... snip

 The bean is in the classes dir and compled fine

 
 and the jsp page looks like this
 
 jsp:useBean id="TN" scope="session" class="NormalizeText" /
 jsp:setProperty name="TN" property="text" value="what is the prob?" /
 
 So can any one tell me what I am doing wrong.
 
 Thanks.

You need to put your bean in a package and specify the package
completely in the useBean tag.  Apparently, when Tomcat sees
the kind of usage you show, it assumes that the class is in the
"current" directory.



WBB - [EMAIL PROTECTED]
Java Cert mock exams http://www.lanw.com/java/javacert/
Author of Java Developer's Guide to Servlets and JSP 
ISBN 0-7821-2809-2

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: useing beans.

2001-03-01 Thread Pater Pandoson

Good call that was it all right. Thanks
it says nothing about it in my book!
agh well live and learn.


"Hawkins, Keith (Keith)" wrote:

 Did you try changing the class to have public access?
 This is just a hunch but the default constructor on a
 non-public class may not be accessible given the IllegalAccess
 exception that is being thrown.
 -Keith



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Tomcat Src

2001-03-01 Thread Hickok, Troy



If you 
are on Solaris try gettingGNU tar and using it instead of the tar 
that comes with Solairs. That solved it for me.

  -Original Message-From: Tan Khim Siang 
  [mailto:[EMAIL PROTECTED]]Sent: Wednesday, February 28, 2001 10:58 
  PMTo: Tomcat User GroupSubject: Tomcat 
  Src
  Hi I am trying to untar the tomcat src tarball 
  and I always get this error msg where I do a tar xvf on the 
  tarball:
  
  
  
  
  
  
  
  
  jakarta-tomcat-3.2.1-src/src/webpages/docs/api/javax/servlet/http/class-use/HttpServletRequest.html, 
  13710 bytes, 27 tape blockstar: directory checksum error
  
  
  --Tan Khim 
  SiangAccount ManagerDV9 International Pte Ltd21A Sembawang 
  RoadSingapore 779076Tel: 4531435 Fax:4535106http://www.dv9.com


RE: Generating a random alphanumeric string

2001-03-01 Thread Samson, Lyndon [IT]

This seems ok for the job. There should be some speedups if you need them.

Cheers


// --- cut ---
public class GenID {

private static String validChars =
"ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890";

private int _IDlength;

public GenID(int IDlength) {
_IDlength = IDlength;
}

public String generate() {
String resultID = "";
int maxIndex = validChars.length();
java.util.Random rnd = new java.util.Random();

for ( int i = 0 ; i  _IDlength ; i++ ) {
int rndPos = Math.abs(rnd.nextInt() % maxIndex);   
resultID += validChars.charAt(rndPos);
}


return resultID;
}

}
// --- cut ---
-Original Message-
From: Cato, Christopher [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 2:05 PM
To: '[EMAIL PROTECTED]'
Subject: Generating a random alphanumeric string


Hello, can anyone show me an example or give me a clue about how
to generate a random alphanumeric string of lets say 16-32 chars?
TomCat is obviously doing it for the session ids, but how would I
do the same in a servlet?

Regards,

Christopher Cato

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




IIS/PWS fails to load isapi_redirect.dll filter

2001-03-01 Thread Hawkins, Keith (Keith)


I am trying to get the isapi_redirect.dll filter to run under IIS/PWS.

I have quadruple checked all the values that I need to set up according to
the instructions posted on the Tomcat site.  But every time I stop and start
the web service, I get the dreaded  red down arrow.  (The bane of my
existence these days ;-)

I got the filter set up fine on Windows 2000, but I can't get it going on a
machine running with NT4.0 Service Pack 5.

I have a few questions for those who may have gotten this working correctly
on NT.

1)  If a filter fails to load,  where does IIS/PWS log the problem that is
preventing it from loading??

2)  The instructions say to for PWS I need to add a Filter DLLs key to the
registry.  What is not clear
is whether Filter DLLs is a KEY name with a default value of the full path
to isapi_redirect.dll  or
Filter DLLs is a STRING VALUE entry at the W3SVC/Paramaters level with a
value of the full path to the isapi_redirect.dll. Or do I even need to do
this since I was able to set up a filter entry using the management
console??

Any help would be appreciated.

Thanks,
Keith




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Tomcat, Jaxp, Xalan

2001-03-01 Thread Scott Walter

Help!

I am trying to do xml transformation with tomcat.  I
want to use the xalan transformation engine.  However
the jaxp.jar that is included in the tomcat lib is
getting in the way.  I keep on getting a "Namespace
not supported by parser" exception.

If I remove jaxp.jar and parser.jar from the tomcat
lib directory and replace it with the xerces.jar
everything works great.  Is there anyway to keep the
installed jaxp.jar and parser.jar but still get my
transformations to work, because my app will be
running at a hosting provider and they probably won't
make the change I need.

thanks in advance,
scott.

Below is the code I use to do my transformation:
TransformerFactory tFactory =
TransformerFactory.newInstance();
Transformer transformer =
tFactory.newTransformer(xslSource);
transformer.transform(xmlSource, new
StreamResult(response.getOutputStream()));  

=
~~~
Scott
May the Force be with you!

__
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail. 
http://personal.mail.yahoo.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Tomcat Crashes

2001-03-01 Thread Dick Poon

wow! even a little higher version of JDK do make a difference!

- Original Message -
From: Randy Layman [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 8:12 PM
Subject: RE: Tomcat Crashes



 Two common causes of crashes, in my experience, are using the
 JDBC-ODBC bridge (its not thread safe and when concurrent access occurs it
 crashes the JVM).  The other is in the JIT complilation.  I've had a lot
 less trouble with the newer JDKs (1.2.2_007) than the older ones
(1.2.2_002
 and 004).

 The solution to the second problem is pretty obvious - upgrade your
 JVM or turn off JIT.  The first solution you can either serialize requests
 or find new database drivers.

 If your problem isn't one of these two things, I would suggest
 looking where you are using native code as well as the differences between
 the two machines (including usage, it the one with the higher load crashes
 more frequently then the problem is probably something you are using isn't
 thread safe)

 Randy

 -Original Message-
 From: Kishor K [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, March 01, 2001 5:57 AM
 To: Tomcat User Mailing List
 Subject: Tomcat Crashes


 hi,
  I have Tomcat 3.1 and jdk 1.2.2 on  TWO Windows NT machines.
 Both the machines are loaded with the same code,same database.
  But on one machine it is causing Dr.Watson error 2-3 times a day whereas
 the other one is working properly.

  Could you help in anyway on this?

  thanks in advance
  kishor




 _
 Do You Yahoo!?
 Get your free @yahoo.com address at http://mail.yahoo.com


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Too many open files with Tomcat-3.2.1 under Solaris

2001-03-01 Thread Zsolt Koppany

Hi,

I just want to port our tomcat application to Solaris-2.7 and after a
short time I get the error message "Too many open files" from
java.net.SocketException.

The same applications does not have the problem under Linux.

I'm pretty sure that not our application causes the problem.

I use j2sdk1_3_0_02 under Solaris.

Any ideas?


-- 
Zsolt Koppany
Intland GmbH www.intland.com
Schulze-Delitzsch-Strasse 16
D-70565 Stuttgart
Tel: +49-711-7871080 Fax: +49-711-7871017

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: I CANT COMPILE SERVLETS!!!HELP

2001-03-01 Thread DSailing


I'm not sure this is what you are asking.  You never said what kind of
error you were getting.  But I though a list of my command line parameters
might help.  here is what I use:

-deprecation -classpath "d:\Program Files\jakarta-tomcat\classes";"\Program
Files\jakarta-tomcat\lib\servlet.jar" -d "d:\Program
Files\jakarta-tomcat\classes" $(FilePath)

1. You can leave "-deprecaton" out.  I just use it for my own reasons.
2.  "d:\Program Files\jakarta-tomcat\classes" is where my servlets go and
it also contains any other personal classes I use.  It appears in both the
"-classpath" and the "-d" parameter.
3.  "\Program Files\jakarta-tomcat\lib\servlet.jar" is provided with
tomcat.  It appears only in the "-classpath" parameter.
4.  "$(FilePath)" is replaced by the file name, which matches the class
name, of my servlet.
5.  Several of the file names are in quotes because they have imbedded
spaces.

I'm not sure this is what you were asking, but in case it was, this is what
I do.


Don Sailing [EMAIL PROTECTED]





aras [EMAIL PROTECTED]@localhost.localdomain on 02/28/2001 05:08:42 PM

Please respond to [EMAIL PROTECTED]

Sent by:  [EMAIL PROTECTED]


To:   [EMAIL PROTECTED]
cc:

Subject:  Re: I CANT COMPILE SERVLETS!!!HELP

I'm having the same problem.  So I looked  into your suggestion or adding
$TOMCAT_HOME\bin jar file(s) to my CLASSPATH.  There are no jar files in
that dir.  All my jars are in TOMCAT_HOME/lib.  If the lib dir is what your
talking about, which or the jars to I need to add or do I just point to the
lib dir and it figures it out.


Chris Andreou wrote:

 check you jdk path
 and also set you classpath to all the jar files under the tomcat\bin

 -Original Message-
 From: Zakaria . [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, February 28, 2001 4:33 PM
 To: [EMAIL PROTECTED]
 Subject: I CANT COMPILE SERVLETS!!!HELP

 Hello,
 I have tomcat running fine but i couldnt compile any servlet. I put the
 servlet in different directories and tried (does it matter?) but same
 result:
 cannot resolve symbol:HttpServlet

 i use this command line from the same directory as the servlet:
 javac -classpath c:\tomcat\lib\servlet.jar Hello.java

 i also downloaded the servlet.jar from the sun site and include it in the
 classpath and in the command line with the same result...
 how can i compile using the servlet.jar???

 thanks.
 _
 Get your FREE download of MSN Explorer at http://explorer.msn.com

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]






-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




mod_jk.c

2001-03-01 Thread Chris Andreou

I am using NT, Apache 3.2.1 and Tomcat.  Does anybody know why I get an
error by loading the mod_jk.c ? 

Thanks

Chris

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Generating a random alphanumeric string

2001-03-01 Thread Adrian Papari

i did this a few weeks ago; the code is far from "clean'n'nice", but it does
what it's supposed to, here goes:


Random pwdGen = new Random( System.currentTimeMillis() );
Character temp = new Character( 'a' );
StringBuffer pwd = new StringBuffer();
Vector charPwd = new Vector();
int i = 0;

//0-9
for ( i = 48; 57 = i; i++ )
{
temp = new Character( ( char ) i );
charPwd.addElement( temp );
}

//a-z A-Z
for ( i = 65; 90 = i; i++ )
{
temp = new Character( ( char ) i );
charPwd.addElement( temp );
}
for ( i = 97; 122 = i; i++ )
{
temp = new Character( ( char ) i );
charPwd.addElement( temp );
}

//where i == length of alphanumeric string.
for ( i = 0; 10  i; i++ )
{
pwd.append(  ( Character ) charPwd.elementAt( ( int ) ( charPwd.size() *
pwdGen.nextFloat() ) ) );
}


 
//adrian.

-Original Message-
From: Cato, Christopher [mailto:[EMAIL PROTECTED]]
Sent: 01 March 2001 15:05
To: '[EMAIL PROTECTED]'
Subject: Generating a random alphanumeric string


Hello, can anyone show me an example or give me a clue about how
to generate a random alphanumeric string of lets say 16-32 chars?
TomCat is obviously doing it for the session ids, but how would I
do the same in a servlet?

Regards,

Christopher Cato

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Tomcat mod_jk: jsp pages don't display the first time invoked

2001-03-01 Thread Xu, Lifeng

Hi all,

I just lately replaced mod_jserv with mod_jk as Tomcat plug in in Apache. It
works ok except one thing: for some of my jsp pages, the first time invoking
them will not get the page displayed. Instead, I get a "page not exist"
error. However, if you go back and hit refresh, then the right page will
display.

This only happens after we switched from mod_jserv to mod_jk. I am sure this
is configuration issue, I just can't pin point the problem.

Can somebody help me on this?

Thank you in advance.

Lifeng

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: mod_jk.c

2001-03-01 Thread Xu, Lifeng

I am also new to mod_jk, but I think if you are running NT, you don't load
mod_jk.c. What you need is mod_jk.dll.

I could be wrong though. Like I said, I am new too. So take my advise in
your own risk...:)

Good luck.

Lifeng

-Original Message-
From: Chris Andreou [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 9:25 AM
To: '[EMAIL PROTECTED]'
Subject: mod_jk.c


I am using NT, Apache 3.2.1 and Tomcat.  Does anybody know why I get an
error by loading the mod_jk.c ? 

Thanks

Chris

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




MyRealm - cannot instantiate class exception

2001-03-01 Thread DUDGEON

Although I've been using tomacat for sometime, I'm now needeing to start on
some work to match up the authentication and authorisation within catalina
to our enviroment. To do this I'm putting together a LDAPRealm. I have a
rudimentary LDAPRealm that works fine on its own, but when I put it into
tomcat I'm getting a cannott instantiate class exception from within my
code. Could someone give me a guide into what I'm doing worong. It's
probably pretty basic, but I'm new to this.

What I did:

created a org.apache.catalina.realm.MyRealm class that contains an
authenticate() method that connects to the LDAP server as follows

public Principal  authenticate(String username, String credentials) {
   
MyRealmPrincipal principal = new MyRealmPrincipal(username);
Hashtable env = new Hashtable(11);
env.put(Context.PROVIDER_URL, 
"ldap://localhost:389/dc=britbio,dc=co,dc=uk");
env.put(Context.SECURITY_PRINCIPAL, principal.getDistinguishedName());
env.put(Context.SECURITY_CREDENTIALS, credentials);

try {
  // Create the initial directory context
  DirContext ctx = new InitialDirContext(env);
  // if we get here then we've bound OK

  System.out.println("Authenticated for " +
principal.getDistinguishedName());

  // get the groups from the JNDI context and define them as roles
  getRoles(ctx, principal);

  // unbind
  ctx.close();

  return(principal);


} catch (NamingException e) {
  // could not bind - wrong password?
  System.err.println("Failed to bind to directory for " + username);
  e.printStackTrace();
  return(null);
} 


this code works fine on its own (outside catalina). However when I try to
run it within catalina (jar'd up the clases, put them in
$CATLINA_ROOT/server), my code gets called, but the bind to the LDAP server
fails with the following exception 


Failed to bind to directory for tom
javax.naming.NoInitialContextException: Cannot instantiate class:
com.sun.jndi.ldap.LdapCtxFactory.  Root exception is
java.lang.ClassCastException: com.sun.jndi.ldap.LdapCtxFactory
at
javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:659)
at
javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:250)
at javax.naming.InitialContext.init(InitialContext.java:226)
at javax.naming.InitialContext.init(InitialContext.java:202)
at
javax.naming.directory.InitialDirContext.init(InitialDirContext.java:87)
at
org.apache.catalina.realm.TimsRealm.authenticate(TimsRealm.java:109)
at
org.apache.catalina.authenticator.BasicAuthenticator.findPrincipal(BasicAuth
enticator.java:214)
at
org.apache.catalina.authenticator.BasicAuthenticator.authenticate(BasicAuthe
nticator.java:160)
at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase
.java:481)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:975)
at
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2041)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:161
)
at
org.apache.catalina.valves.ValveBase.invokeNext(ValveBase.java:242)
at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:414)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:975)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:159)
at
org.apache.catalina.valves.ValveBase.invokeNext(ValveBase.java:242)
at
org.apache.catalina.valves.RequestDumperValve.invoke(RequestDumperValve.java
:215)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:975)
at
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:
818)
at
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:897)
at java.lang.Thread.run(Thread.java:484)


Any ideas as to why this runs outside catalina and not inside it. The JVM,
and everything else I can think of is the same. My setup:
  Tomcat-4.0-b1
  JDK1.3
  Linux

many thanks

Tim


-
Tim Dudgeon
[EMAIL PROTECTED]


--
DISCLAIMER: This message contains proprietary
information some or all of which may be
confidential and/or legally privileged. It is for
the intended recipient only who may use and apply
the information only for the intended purpose.
Internet communications are not secure and
therefore the British Biotech group does not
accept legal responsibility for the contents of
this message. Any views or opinions presented are
only those of the author and not those of the
British Biotech group. If you are not the intended
recipient please delete this e-mail and notify the
author immediately by calling ++44 (0)1865 748747;
do not use, disclose, distribute, copy, print or
rely on this e-mail.


SSL Tomcat

2001-03-01 Thread Brett W. McCoy

I have some questions regarding the use of mod_ssl with Apache and Tomcat.
The onlie docs don't go into great detail about configuration, so hopefuly
someone here has more clue than I.

In the online docs, the author recommends putting the mod_jk directives
under the SSL port 443 virtual host seciotn in httpd.conf.  In doing this,
though, does this put everything in my configured context under SSL?  If I
only want specific documents using SSL, but have the rest of the URLs on
the server accessible without requiring SSL, should I do my JkMount
directives outside the SSL virtual host section, and just use directory by
directory or file-based directives inside the SSL section?  Is it possible
to use .htaccess files with the SSL directives for JSP files?

Thanks in advance for any help...

-- Brett
 http://www.chapelperilous.net/~bmccoy/
---
God is real, unless declared integer.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




ask a don't exists page and show other

2001-03-01 Thread Carlos

i have my pages from asp to jsp
the problem is that there are users that asks asp pages.
there is any way for make this:
if my browser asks a *.asp page forward (show) the index.jsp page?
how?
thanks
Carlos


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




SSL Tomcat, continued

2001-03-01 Thread Brett W. McCoy

I forgot one more question, that is more of a programming question than a
configuration question.  I need to be able to use a custom error page that
gets served if SSL is not available.  Can this be accomplished with a JSP
file, by capturing the error and redirecting to the error page in a
manner analogous to redirecting to a custom 404 page?

-- Brett
 http://www.chapelperilous.net/~bmccoy/
---
One difference between a man and a machine is that a machine is quiet
when well oiled.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




receiving multilingual input for servlet

2001-03-01 Thread Amir Nuri

Does anyone can help me ??
I am getting text from a form, but when it's not english i can't convert the
characters
into UTF-8 format !!!



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: ask a don't exists page and show other

2001-03-01 Thread Brett W. McCoy

On Thu, 1 Mar 2001, Carlos wrote:

 i have my pages from asp to jsp
 the problem is that there are users that asks asp pages.
 there is any way for make this:
 if my browser asks a *.asp page forward (show) the index.jsp page?

You'd have to have a redirection in your ASP page to the new JSP file.

-- Brett
 http://www.chapelperilous.net/~bmccoy/
---
It is your concern when your neighbor's wall is on fire.
-- Quintus Horatius Flaccus (Horace)


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




tomcat3.2.1 -- tomcat 4b1

2001-03-01 Thread Carlos

i use the tomcat 3.2.1
in the TOMCAT_HOME i have put a classes directory for putting all my classes
for all my virtual domains.
is this posible in tomcat4b1?
i have put int the TOMCAT_HOME (tomcat4b1) the classes direcotry with my all
classes (*.class) for all virtual domains and it not found them.
haoi can i put a directory with my all classes for all virtual dimains for
putting the all *.class files?
thanks
my structure is:

/home/virtualdomains/
|
-Virtualdomain1
|
-Virtualdomain2
|
-VirtualdomainX

/tomcat_HOME
|
-classes
-lib
-webapps
.

thanks
Carlos


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: IIS 5.0 and adding contexts (JSPs not being processed)

2001-03-01 Thread Rodriguez Victor A.

Hi,

 One interesting thing to note is that the Javascript is still 
 executed (i.e.
 stuff insideSCRIPT language="Javascript"/SCRIPT tags)

Please, note that JSP executes in the server side, and JavaScript in the
client side (a.k.a. browser).

Cheers.
-- 
Vctor A. Rodrguez ( http://www.bit-man.com.ar) 
Telefnica de Argentina - http://www.Telefonica.com.ar 
Tel. (54-11) 4333-7305 - Fax: (54-11) 4303-5586 int. 1680 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Protecting mysql access (was: re: mySQL again)

2001-03-01 Thread Rob Tanner

Slightly off topic, but important!

Having seen way too much in terms of hacking and system compromises, 
might I suggest you create another, and far less privileged user than 
root, for accessing mysql.  Unless you've gone into the grant tables 
and creatd a different mysql superuser and reduced root's priv, then 
the root login to mysql is like root on unix, superuser, God, etc.  If 
multiple users have shell access to the tomcat host system, and those 
same users are not authorized as mysql root, than I know of no way to 
keep unauthorized eyes from looking at the server.xml file other than 
by making it sysroot protected. But to do that, you need to run tomcat 
under root.

If anyone has a good mechanism for securing the server's and/or 
servlet's credential for db access, I'd certainly love to hear it. 
That issue has been my one and only thorn in the side since I began 
switching for perl/cgi (where the solution to that issue is a 
no-brainer) to using tomcat.

-- Rob

--On Thursday, March 01, 2001 10:19:13 AM +0100 [EMAIL PROTECTED] wrote:

 Hi!
 My connectionURL in server.xml now looks like this:
 "jdbc:mysql://localhost/auth?user=rootpassword=somepassword"

 and tomcat doesn't start up (although there is no error msg or
 anything) and when i execute tomcat stop i get the following
 exception:
 org.xml.sax.SAXParseException: Next character must be ";" terminating
 reference to entity "password" and a stack trace follows...

 why is that?

 I guess you should escape the "" character in your connectionURL by
 replacing it with "amp;", as the XML parser will parse entities like
 "lt;" or "quote;" or things like that...

 Try

 jdbc:mysql://localhost/auth?user=rootamp;password=somepassword

 instead, that should work...

 np: Flanger - Nightbeat 1 (Midnight Sound)

 -
 Sent through MailGateway - http://www.ssw.uni-linz.ac.at:2000/
 Send or read your emails anywhere.
 -

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]





   _ _ _ _   __ _ _ _ _
  /\_\_\_\_\/\_\ /\_\_\_\_\_\
 /\/_/_/_/_/   /\/_/ \/_/_/_/_/_/  QUIDQUID LATINE DICTUM SIT,
/\/_/__\/_/ __/\/_//\/_/  PROFUNDUM VIDITUR
   /\/_/_/_/_/ /\_\  /\/_//\/_/
  /\/_/ \/_/  /\/_/_/\/_//\/_/ (Whatever is said in Latin
  \/_/  \/_/  \/_/_/_/_/ \/_/  appears profound)

  Rob Tanner
  McMinnville, Oregon
  [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




no class def found sun.tools.javac.Main

2001-03-01 Thread Stefán F. Stefánsson

Hi I'm getting the following error.  Anybody have an idea where this
class comes from?  What do I need to have in my classpath to find it?

Thanks, Stefan.

Internal Servlet Error:
javax.servlet.ServletException: sun/tools/javac/Main
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:399)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:11
47)
at org.apache.tomcat.core.Handler.service(Handler.java:311)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcher
Impl.java:194)
at
com.decode.ips.webservice.controller.IPSControllerServlet.login(IPSContr
ollerServlet.java:260)
at
com.decode.ips.webservice.controller.IPSControllerServlet.doGet(IPSContr
ollerServlet.java:191)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.jav
a:797)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(H
ttpConnectionHandler.java:210)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416
)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:49
8)
at java.lang.Thread.run(Thread.java:484)
Root cause: 
java.lang.NoClassDefFoundError: sun/tools/javac/Main
at
org.apache.jasper.compiler.SunJavaCompiler.compile(SunJavaCompiler.java:
128)
at
org.apache.jasper.compiler.Compiler.compile(Compiler.java:245)
at
org.apache.jasper.servlet.JspServlet.doLoadJSP(JspServlet.java:462)
at
org.apache.jasper.servlet.JasperLoader12$1.run(JasperLoader12.java:160)
at java.security.AccessController.doPrivileged(Native Method)
at
org.apache.jasper.servlet.JasperLoader12.loadJSP(JasperLoader12.java:156
)
at
org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:433)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(J
spServlet.java:152)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServle
t.java:164)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:318)
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:11
47)
at org.apache.tomcat.core.Handler.service(Handler.java:311)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcher
Impl.java:194)
at
com.decode.ips.webservice.controller.IPSControllerServlet.login(IPSContr
ollerServlet.java:260)
at
com.decode.ips.webservice.controller.IPSControllerServlet.doGet(IPSContr
ollerServlet.java:191)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.jav
a:797)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(H
ttpConnectionHandler.java:210)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416
)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:49
8)
at java.lang.Thread.run(Thread.java:484)



Stefan Freyr Stefansson
Software Developer
deCODE Genetics, Inc.
http://www.decode.com

Phone: (+354) 570 2854
GSM:   (+354) 861 1718
Fax:   (+354) 491 3782
 



RE: no class def found sun.tools.javac.Main

2001-03-01 Thread Randy Layman


This comes from Tomcat not being able to find your JavaC compiler
(imagine that, not found class sun.tools.javac.Main).  You need to set your
JAVA_HOME variable so that it points to your JDK root directory.

And read the manual and/or mail list archives and/or the FAQ.

Randy


-Original Message-
From: Stefn F. Stefnsson [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 11:33 AM
To: Tomcat-User
Subject: no class def found sun.tools.javac.Main


Hi I'm getting the following error.  Anybody have an idea where this
class comes from?  What do I need to have in my classpath to find it?

Thanks, Stefan.

Internal Servlet Error:
javax.servlet.ServletException: sun/tools/javac/Main
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:399)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:11
47)
at org.apache.tomcat.core.Handler.service(Handler.java:311)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcher
Impl.java:194)
at
com.decode.ips.webservice.controller.IPSControllerServlet.login(IPSContr
ollerServlet.java:260)
at
com.decode.ips.webservice.controller.IPSControllerServlet.doGet(IPSContr
ollerServlet.java:191)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.jav
a:797)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(H
ttpConnectionHandler.java:210)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416
)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:49
8)
at java.lang.Thread.run(Thread.java:484)
Root cause: 
java.lang.NoClassDefFoundError: sun/tools/javac/Main
at
org.apache.jasper.compiler.SunJavaCompiler.compile(SunJavaCompiler.java:
128)
at
org.apache.jasper.compiler.Compiler.compile(Compiler.java:245)
at
org.apache.jasper.servlet.JspServlet.doLoadJSP(JspServlet.java:462)
at
org.apache.jasper.servlet.JasperLoader12$1.run(JasperLoader12.java:160)
at java.security.AccessController.doPrivileged(Native Method)
at
org.apache.jasper.servlet.JasperLoader12.loadJSP(JasperLoader12.java:156
)
at
org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:433)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(J
spServlet.java:152)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServle
t.java:164)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:318)
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:11
47)
at org.apache.tomcat.core.Handler.service(Handler.java:311)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcher
Impl.java:194)
at
com.decode.ips.webservice.controller.IPSControllerServlet.login(IPSContr
ollerServlet.java:260)
at
com.decode.ips.webservice.controller.IPSControllerServlet.doGet(IPSContr
ollerServlet.java:191)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.jav
a:797)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at

RE: Poolman and Tomcat - where does the poolman.props file go

2001-03-01 Thread Ariel


Add some directory (like c:\tomcat\lib) to your CLASSPATH and copy
poolman.props to this directory.

Ariel

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 6:08 PM
To: [EMAIL PROTECTED]
Subject: Poolman and Tomcat - where does the poolman.props file go


Hello all,

My configuration is as follows:  

WIN2K 
Apache 1.3.14
Tomcat 3.2.1
Poolman 1.4.1

I have include the poolman.jar file in my CLASSPATH as per the
documentation.  I have tested the connection with the PoolManSample.java
program provided and all works fine from outside of tomcat.  I have a
servlet which now attempts to connect to the database via PoolMan, but I
keep getting the following error:

 Could not find 'poolman.props' -- now attempting to read deprecated
file name 'pool.props'... failed.

I have tried placing the poolman.props file in my webapps directory,
TOMCAT_HOME\webapps\myapp and in the classes directory under myapp and in
about every other directory I can think of but to no avail.  Is there
something else I need to configure in the web.xml or in tomcat.conf to have
this work correctly?

Any help with this is appreciated.

Regards,

Todd G. Nist
Email:   [EMAIL PROTECTED]



The information in this electronic mail ("e-mail") message may
be confidential and for use of only the named recipient.  The
information may be protected by privilege, work product immunity
or other applicable law.  If you are not the intended recipient
the retention, dissemination, distribution or copying of this
e-mail message is strictly prohibited.  If you receive this e-mail
message in error please notify us immediately by telephone
at 770-723-1011 or [EMAIL PROTECTED]  Thank you. 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




interligo

2001-03-01 Thread dsergent

Does anyone knows something about interligo, where the files are 
and if the project is always used or totaly forget 


thks for your answer

David

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Protecting mysql access (was: re: mySQL again)

2001-03-01 Thread Rick Herrick

On our server, we basically grant NO remote access privileges to ANY users, 
including root.  This means that any access to the database has to be done 
from the localhost.  So instead of doing the two normal grants you might 
do, like this:

GRANT SELECT,INSERT,UPDATE ON *.* TO soandso@localhost IDENTIFIED BY 
'password';
GRANT SELECT,INSERT,UPDATE ON *.* TO soandso@"%" IDENTIFIED BY 'password';

The first allows access from the localhost.  The second allows remote 
access.  Just don't do the second.  Then someone has to hack in and get 
local access to the database somehow and if they can do that, then you've 
got other security problems besides MySql!

At 08:01 AM 3/1/2001 -0800, you wrote:
Slightly off topic, but important!

Having seen way too much in terms of hacking and system compromises, might 
I suggest you create another, and far less privileged user than root, for 
accessing mysql.  Unless you've gone into the grant tables and creatd a 
different mysql superuser and reduced root's priv, then the root login to 
mysql is like root on unix, superuser, God, etc.  If multiple users have 
shell access to the tomcat host system, and those same users are not 
authorized as mysql root, than I know of no way to keep unauthorized eyes 
from looking at the server.xml file other than by making it sysroot 
protected. But to do that, you need to run tomcat under root.

If anyone has a good mechanism for securing the server's and/or servlet's 
credential for db access, I'd certainly love to hear it. That issue has 
been my one and only thorn in the side since I began switching for 
perl/cgi (where the solution to that issue is a no-brainer) to using tomcat.

-- Rob

--On Thursday, March 01, 2001 10:19:13 AM +0100 [EMAIL PROTECTED] wrote:

Hi!
My connectionURL in server.xml now looks like this:
"jdbc:mysql://localhost/auth?user=rootpassword=somepassword"

and tomcat doesn't start up (although there is no error msg or
anything) and when i execute tomcat stop i get the following
exception:
org.xml.sax.SAXParseException: Next character must be ";" terminating
reference to entity "password" and a stack trace follows...

why is that?

I guess you should escape the "" character in your connectionURL by
replacing it with "amp;", as the XML parser will parse entities like
"lt;" or "quote;" or things like that...

Try

jdbc:mysql://localhost/auth?user=rootamp;password=somepassword

instead, that should work...

np: Flanger - Nightbeat 1 (Midnight Sound)

-
Sent through MailGateway - http://www.ssw.uni-linz.ac.at:2000/
Send or read your emails anywhere.
-

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




   _ _ _ _   __ _ _ _ _
  /\_\_\_\_\/\_\ /\_\_\_\_\_\
 /\/_/_/_/_/   /\/_/ \/_/_/_/_/_/  QUIDQUID LATINE DICTUM SIT,
/\/_/__\/_/ __/\/_//\/_/  PROFUNDUM VIDITUR
   /\/_/_/_/_/ /\_\  /\/_//\/_/
  /\/_/ \/_/  /\/_/_/\/_//\/_/ (Whatever is said in Latin
  \/_/  \/_/  \/_/_/_/_/ \/_/  appears profound)

  Rob Tanner
  McMinnville, Oregon
  [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]


--
Rick Herrick
[EMAIL PROTECTED]
Nothing is amusing in zero gravity...
PGP: http://www.rickherrick.com/pgpkey


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: no class def found sun.tools.javac.Main

2001-03-01 Thread Stefán F. Stefánsson

Thanks for your answer.

I should have been more clear in my previous post.

Ok... so here's the deal,

I have a server application that integrates Tomcat.  This server starts
tomcat up through use of the EmbeddedTomcat class.  So far so good.
When I start the server from a command line or within JBuilder
everything is just fine and dandy and works oh so well ;o)
However, I'm trying to create an ant buildfile to do everything for me.
I've managed to have the buildfile build everything and create a jar
file and all that but when I try to have it run the server, the server
goes up but the first JSP I try to access gives me that error I was
talking about.

I'm not a newbie to Tomcat so I knew about that JAVA_HOME variable (and
it _is_ set on my computer)... I should have mentioned that in my first
post... sorry about that.

Regards, Stefan.


-Original Message-
From: Randy Layman [mailto:[EMAIL PROTECTED]]
Sent: 1. mars 2001 16:03
To: [EMAIL PROTECTED]
Subject: RE: no class def found sun.tools.javac.Main



This comes from Tomcat not being able to find your JavaC
compiler
(imagine that, not found class sun.tools.javac.Main).  You need to set
your
JAVA_HOME variable so that it points to your JDK root directory.

And read the manual and/or mail list archives and/or the FAQ.

Randy


-Original Message-
From: Stefn F. Stefnsson [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 11:33 AM
To: Tomcat-User
Subject: no class def found sun.tools.javac.Main


Hi I'm getting the following error.  Anybody have an idea where this
class comes from?  What do I need to have in my classpath to find it?

Thanks, Stefan.

Internal Servlet Error:
javax.servlet.ServletException: sun/tools/javac/Main
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:399)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:11
47)
at org.apache.tomcat.core.Handler.service(Handler.java:311)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcher
Impl.java:194)
at
com.decode.ips.webservice.controller.IPSControllerServlet.login(IPSContr
ollerServlet.java:260)
at
com.decode.ips.webservice.controller.IPSControllerServlet.doGet(IPSContr
ollerServlet.java:191)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.jav
a:797)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(H
ttpConnectionHandler.java:210)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416
)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:49
8)
at java.lang.Thread.run(Thread.java:484)
Root cause: 
java.lang.NoClassDefFoundError: sun/tools/javac/Main
at
org.apache.jasper.compiler.SunJavaCompiler.compile(SunJavaCompiler.java:
128)
at
org.apache.jasper.compiler.Compiler.compile(Compiler.java:245)
at
org.apache.jasper.servlet.JspServlet.doLoadJSP(JspServlet.java:462)
at
org.apache.jasper.servlet.JasperLoader12$1.run(JasperLoader12.java:160)
at java.security.AccessController.doPrivileged(Native Method)
at
org.apache.jasper.servlet.JasperLoader12.loadJSP(JasperLoader12.java:156
)
at
org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:433)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(J
spServlet.java:152)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServle
t.java:164)
at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:318)
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:391)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:11
47)
at 

RE: no class def found sun.tools.javac.Main

2001-03-01 Thread Randy Layman


If I understand your problems - its that when Ant starts the server
you can't compile your JSPs?  

I think your problem is in your Ant build file not setting the Java
home. How are you trying to invoke Tomcat - script or calling the class?  If
the class, make sure to add tools.jar to the classpath, if by script, make
sure that you set the environment variables, either in the script or
otherwise.

Randy

-Original Message-
From: Stefn F. Stefnsson [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 11:50 AM
To: [EMAIL PROTECTED]
Subject: RE: no class def found sun.tools.javac.Main


Thanks for your answer.

I should have been more clear in my previous post.

Ok... so here's the deal,

I have a server application that integrates Tomcat.  This server starts
tomcat up through use of the EmbeddedTomcat class.  So far so good.
When I start the server from a command line or within JBuilder
everything is just fine and dandy and works oh so well ;o)
However, I'm trying to create an ant buildfile to do everything for me.
I've managed to have the buildfile build everything and create a jar
file and all that but when I try to have it run the server, the server
goes up but the first JSP I try to access gives me that error I was
talking about.

I'm not a newbie to Tomcat so I knew about that JAVA_HOME variable (and
it _is_ set on my computer)... I should have mentioned that in my first
post... sorry about that.

Regards, Stefan.


-Original Message-
From: Randy Layman [mailto:[EMAIL PROTECTED]]
Sent: 1. mars 2001 16:03
To: [EMAIL PROTECTED]
Subject: RE: no class def found sun.tools.javac.Main



This comes from Tomcat not being able to find your JavaC
compiler
(imagine that, not found class sun.tools.javac.Main).  You need to set
your
JAVA_HOME variable so that it points to your JDK root directory.

And read the manual and/or mail list archives and/or the FAQ.

Randy


-Original Message-
From: Stefn F. Stefnsson [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 11:33 AM
To: Tomcat-User
Subject: no class def found sun.tools.javac.Main


Hi I'm getting the following error.  Anybody have an idea where this
class comes from?  What do I need to have in my classpath to find it?

Thanks, Stefan.

Internal Servlet Error:
javax.servlet.ServletException: sun/tools/javac/Main
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:399)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.handleError(ContextManager.java:11
47)
at org.apache.tomcat.core.Handler.service(Handler.java:311)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcher
Impl.java:194)
at
com.decode.ips.webservice.controller.IPSControllerServlet.login(IPSContr
ollerServlet.java:260)
at
com.decode.ips.webservice.controller.IPSControllerServlet.doGet(IPSContr
ollerServlet.java:191)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.jav
a:797)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(H
ttpConnectionHandler.java:210)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416
)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:49
8)
at java.lang.Thread.run(Thread.java:484)
Root cause: 
java.lang.NoClassDefFoundError: sun/tools/javac/Main
at
org.apache.jasper.compiler.SunJavaCompiler.compile(SunJavaCompiler.java:
128)
at
org.apache.jasper.compiler.Compiler.compile(Compiler.java:245)
at
org.apache.jasper.servlet.JspServlet.doLoadJSP(JspServlet.java:462)
at
org.apache.jasper.servlet.JasperLoader12$1.run(JasperLoader12.java:160)
at java.security.AccessController.doPrivileged(Native Method)
at
org.apache.jasper.servlet.JasperLoader12.loadJSP(JasperLoader12.java:156
)
at
org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:433)
at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(J
spServlet.java:152)
at

Please help. Going Nuts.

2001-03-01 Thread mikhail malamud

Here is the setup I have.
Tomcat 3.2.1 with mod_jk
Apache 1.3.17. DocRoot /usr/local/apache/htdocs.

First, I got the existing /examples webapp to work. Apache is calling
tomcat and its all good. But now I am trying to deploy my first tomcat
application and going through hell. My DocRoot looks the following way.

DocRoot/vitamin/WEB-INF/
DocRoot/vitamin/WEB-INF/classes/edu/myschool/util/HelloWorldExample
Vitamin is the top level of an application I am trying to deploy.

I added following  information to the following files.


mod_jk.conf. Apache Includes it in httpd.conf

Alias /vitamin "/usr/local/apache/htdocs/vitamin"
Directory "/usr/local/apache/htdocs/vitamin"
Options Indexes FollowSymLinks
/Directory

JkMount /vitamin/servlet/* ajp13
JkMount /vitamin/*.jsp ajp13


Location "/vitamin/WEB-INF/"
AllowOverride None
deny from all
/Location
#

Then, I added following entry into the server.xml

##
Context path="/vitamin"
 docBase="/usr/local/apache/htdocs/vitamin"
 crossContext="false"
 debug="0"
 reloadable="true" 
/Context
##

At last. I added following entry into web.xml.

#
servlet
servlet-nameHelloWorld/servlet-name

servlet-classedu.myschool.util.HelloWorldExample/servlet-class
/servlet
servlet-mapping
servlet-nameHelloWorld/servlet-name
/url-pattern/*/url-pattern
/servlet-mapping
#

This does not look good to me, I am more than sure that there is
something wrong with it. I just dont know what.
When I try to access the servlet using
http://myhost.edu/servlet/edu.myschool.util.HelloWorldExample or
http://myhost.edu/servlet/edu.myschool.util.HelloWorld. I dont know
which one goes into URL class name or servlet name. Please help. Any
advice is greately apreciated.










-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Generating a random alphanumeric string

2001-03-01 Thread Craig O'Brien

This intrigued me so I just wrote this little program.  Of course it could
be wrapped up in a bean and it needs to check against a list of established
passwords but it gives you upper-lower case random sequence of alpha-numeric
characters. Just feed it the length that you want. It even cleans up after
itself. :0)

public class CraigsRandomizer   {

// generates a random alpha-numeric sequence

public static void main(String[] args)  {
CraigsRandomizer t = new CraigsRandomizer();
t.randomPass(12); // set to length of 12
}

final void randomPass(int len)  {
int[] random = new int[len];
int i = 0;
String result = "";

while(i  random.length){
int n = (int)(Math.random() * 122);

if (!(n  49)  (!((n = 58)  (n = 64)))  (!((n = 91) 
 (n =
96  {
random[i] = n;
i++;
}
}
for(int j = 0; j  random.length; j++)  {
result += (char)random[j];
}
random = null;
System.out.println(result);
}
}

Let me know if I can help.

Regards,
Craig O'Brien

Java Programmer/Web Developer


 -Oryginalna wiadomooe-
 Od: Cato, Christopher [mailto:[EMAIL PROTECTED]]
 Wysano: 1 marca 2001 15:05
 Do: '[EMAIL PROTECTED]'
 Temat: Generating a random alphanumeric string


 Hello, can anyone show me an example or give me a clue about how
 to generate a random alphanumeric string of lets say 16-32 chars?
 TomCat is obviously doing it for the session ids, but how would I
 do the same in a servlet?

 Regards,

 Christopher Cato

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Please help. Going Nuts.

2001-03-01 Thread Chris Andreou

join the club :) 

at any means if you find a solution let me know

Chris


-Original Message-
From: mikhail malamud [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 11:21 AM
To: [EMAIL PROTECTED]
Subject: Please help. Going Nuts.


Here is the setup I have.
Tomcat 3.2.1 with mod_jk
Apache 1.3.17. DocRoot /usr/local/apache/htdocs.

First, I got the existing /examples webapp to work. Apache is calling
tomcat and its all good. But now I am trying to deploy my first tomcat
application and going through hell. My DocRoot looks the following way.

DocRoot/vitamin/WEB-INF/
DocRoot/vitamin/WEB-INF/classes/edu/myschool/util/HelloWorldExample
Vitamin is the top level of an application I am trying to deploy.

I added following  information to the following files.


mod_jk.conf. Apache Includes it in httpd.conf

Alias /vitamin "/usr/local/apache/htdocs/vitamin"
Directory "/usr/local/apache/htdocs/vitamin"
Options Indexes FollowSymLinks
/Directory

JkMount /vitamin/servlet/* ajp13
JkMount /vitamin/*.jsp ajp13


Location "/vitamin/WEB-INF/"
AllowOverride None
deny from all
/Location
#

Then, I added following entry into the server.xml

##
Context path="/vitamin"
 docBase="/usr/local/apache/htdocs/vitamin"
 crossContext="false"
 debug="0"
 reloadable="true" 
/Context
##

At last. I added following entry into web.xml.

#
servlet
servlet-nameHelloWorld/servlet-name

servlet-classedu.myschool.util.HelloWorldExample/servlet-class
/servlet
servlet-mapping
servlet-nameHelloWorld/servlet-name
/url-pattern/*/url-pattern
/servlet-mapping
#

This does not look good to me, I am more than sure that there is
something wrong with it. I just dont know what.
When I try to access the servlet using
http://myhost.edu/servlet/edu.myschool.util.HelloWorldExample or
http://myhost.edu/servlet/edu.myschool.util.HelloWorld. I dont know
which one goes into URL class name or servlet name. Please help. Any
advice is greately apreciated.










-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: ajp12 or ajp13

2001-03-01 Thread Chris Andreou

Tomasz,

The documentation is very confusing. Would it be possible to send us your
configuration files?

Thanks

Chris

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 2:34 AM
To: [EMAIL PROTECTED]
Subject: Re:ajp12 or ajp13


Well, you should make chages in mod_jk.conf file (which is included in
Apache
http.conf).
Then add new connector for apjv13 in server.xml file (look at dokumentation
in
mod_jk section).

Tomasz Sucharzewski
ING Bank



Reply Separator
Subject:ajp12 or ajp13
Author: [EMAIL PROTECTED]
Date:   01-02-28 11:29

Hello,

I have configed Apache to work with Tomcat.  However, in the
mod_jk.conf-auto file,  it still uses JkMount /example/servlet/* ajp12, even
I already configed Apache to use ajp13.  Why tomcat still use ajp12?  Could
you please give me a help?   Thank you in advance.

Jianming Wang

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]



-
ATTENTION:
The information in this electronic mail message is private and
confidential, and only intended for the addressee. Should you
receive this message by mistake, you are hereby notified that
any disclosure, reproduction, distribution or use of this
message is strictly prohibited. Please inform the sender by
reply transmission and delete the message without copying or
opening it.

Messages and attachments are scanned for all viruses known.
If this message contains password-protected attachments, the
files have NOT been scanned for viruses by the ING mail domain.
Always scan attachments before opening them.
-

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Please help. Going Nuts.

2001-03-01 Thread Jan Labanowski

One thing at a time... Do not start from most complicated stuff... Try
to make hello world JSP to work first
In your directory
/usr/local/apache/htdocs/vitamin put a file:

hello.jsp

HTML
BODY
Hello World
/BODY
HTML

and try to get it in the browser:

http://my.machine.com:8080/vitamin/hello.jsp
and do it the same with your apache port, say
http://my.machine.com/vitamin/hello.jsp

(I do not know what your ports are, so you need to change it)


On Thu, 1 Mar 2001, mikhail malamud wrote:

 
 mod_jk.conf. Apache Includes it in httpd.conf
 
 Alias /vitamin "/usr/local/apache/htdocs/vitamin"
 Directory "/usr/local/apache/htdocs/vitamin"
 Options Indexes FollowSymLinks
 /Directory
 
 JkMount /vitamin/servlet/* ajp13
 JkMount /vitamin/*.jsp ajp13
 
 
 Location "/vitamin/WEB-INF/"
 AllowOverride None
 deny from all
 /Location

Looks OK...


 ##
 Context path="/vitamin"
  docBase="/usr/local/apache/htdocs/vitamin"
  crossContext="false"
  debug="0"
  reloadable="true" 
 /Context


Can you see anything on the Tomcat port 8080 (or whatever it is in your case).
i.e., 
http://my.machine.com:8080/vitamin/hello.jsp

Is your apj13 connected activated? 

 ##
 
 At last. I added following entry into web.xml.

Which web.xml? The /usr/local/apache/htdocs/vitamin/WEB-INF/web.xml ?

 
 #
 servlet
 servlet-nameHelloWorld/servlet-name
The servlet name is not HelloWorld, it is HelloWorldExample
 
 servlet-classedu.myschool.util.HelloWorldExample/servlet-class
 /servlet
 servlet-mapping
 servlet-nameHelloWorld/servlet-name
The servlet name is not HelloWorld, it is HelloWorldExample
 /url-pattern/*/url-pattern

This is wrong...
 url-pattern/*/url-pattern

 /servlet-mapping
 #


Jan K. Labanowski|phone: 614-292-9279,  FAX: 614-292-7168
Ohio Supercomputer Center|Internet: [EMAIL PROTECTED] 
1224 Kinnear Rd, |http://www.ccl.net/chemistry.html
Columbus, OH 43212-1163  |http://www.osc.edu/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Please help. Going Nuts.

2001-03-01 Thread Bill_Fellows/MO/americancentury






"mikhail malamud" [EMAIL PROTECTED] on 03/01/2001 11:20:31 AM



Please respond to [EMAIL PROTECTED]

To:   [EMAIL PROTECTED]
cc:(bcc: Bill Fellows/MO/americancentury)
Subject:  Please help. Going Nuts.



Here is the setup I have.
Tomcat 3.2.1 with mod_jk
Apache 1.3.17. DocRoot /usr/local/apache/htdocs.

First, I got the existing /examples webapp to work. Apache is calling
tomcat and its all good. But now I am trying to deploy my first tomcat
application and going through hell. My DocRoot looks the following way.

{snip}

At last. I added following entry into web.xml.

#
servlet
servlet-nameHelloWorld/servlet-name

servlet-classedu.myschool.util.HelloWorldExample/servlet-class
/servlet
servlet-mapping
servlet-nameHelloWorld/servlet-name
   /url-pattern/*/url-pattern
/servlet-mapping
#

Just a WAG, but in servlet-class you spect edu.myschool.util.HelloWorldExample
Is that right?  I haven't packaged any of my classes yet so I haven't tested
that.
Also, have you tried it without Apache?  Just hit :8080  Does that work?


This does not look good to me, I am more than sure that there is
something wrong with it. I just dont know what.
When I try to access the servlet using
http://myhost.edu/servlet/edu.myschool.util.HelloWorldExample or
http://myhost.edu/servlet/edu.myschool.util.HelloWorld. I dont know
which one goes into URL class name or servlet name. Please help. Any
advice is greately apreciated.

A minor WAG here but would it not be /servlet/HelloWorld since the servlet name
is
HelloWorld (it doesn't matter what your class name is, whatever the servlet name
is, is
what Tomcat will refer to it as.)
/bill



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




*** Please help me

2001-03-01 Thread tefan Babos

Welcome,
I can't configure the ISAPI Redirector. I perform four installations, and I
exactly keep your procedure, but the
http://localhost/examples/jsp/index.html, cannot execute...
I don't known where problem is.
My configuration is Windows 98, PWS 4(working properly).
To this message I attached all needed files, mean conf(I use Microsoft Java
SDK), logs, pws and registry information about my settings.
Thank You very much for answer.

Stefan Babos
Czech Republic

 my_jakarta.zip

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]


RE: Please help. Going Nuts.

2001-03-01 Thread mikhail malamud

OK. I got this to work. What's the next step, Jan?

-Original Message-
From: Jan Labanowski [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 12:51 PM
To: [EMAIL PROTECTED]
Cc: Jan Labanowski
Subject: Re: Please help. Going Nuts.


One thing at a time... Do not start from most complicated stuff... Try
to make hello world JSP to work first
In your directory
/usr/local/apache/htdocs/vitamin put a file:

hello.jsp

HTML
BODY
Hello World
/BODY
HTML

and try to get it in the browser:

http://my.machine.com:8080/vitamin/hello.jsp
and do it the same with your apache port, say
http://my.machine.com/vitamin/hello.jsp

(I do not know what your ports are, so you need to change it)


On Thu, 1 Mar 2001, mikhail malamud wrote:

 
 mod_jk.conf. Apache Includes it in httpd.conf

 Alias /vitamin "/usr/local/apache/htdocs/vitamin"
 Directory "/usr/local/apache/htdocs/vitamin"
 Options Indexes FollowSymLinks
 /Directory

 JkMount /vitamin/servlet/* ajp13
 JkMount /vitamin/*.jsp ajp13


 Location "/vitamin/WEB-INF/"
 AllowOverride None
 deny from all
 /Location

Looks OK...


 ##
 Context path="/vitamin"
  docBase="/usr/local/apache/htdocs/vitamin"
  crossContext="false"
  debug="0"
  reloadable="true" 
 /Context


Can you see anything on the Tomcat port 8080 (or whatever it is in your
case).
i.e.,
http://my.machine.com:8080/vitamin/hello.jsp

Is your apj13 connected activated?

 ##

 At last. I added following entry into web.xml.

Which web.xml? The /usr/local/apache/htdocs/vitamin/WEB-INF/web.xml ?


 #
 servlet
 servlet-nameHelloWorld/servlet-name
The servlet name is not HelloWorld, it is HelloWorldExample

 servlet-classedu.myschool.util.HelloWorldExample/servlet-class
 /servlet
 servlet-mapping
 servlet-nameHelloWorld/servlet-name
The servlet name is not HelloWorld, it is HelloWorldExample
 /url-pattern/*/url-pattern

This is wrong...
 url-pattern/*/url-pattern

 /servlet-mapping
 #


Jan K. Labanowski|phone: 614-292-9279,  FAX:
614-292-7168
Ohio Supercomputer Center|Internet: [EMAIL PROTECTED]
1224 Kinnear Rd, |http://www.ccl.net/chemistry.html
Columbus, OH 43212-1163  |http://www.osc.edu/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: *** Please help me

2001-03-01 Thread Randy Layman


It would appear that your Tomcat is not working correctly (looking
at the isapi log it determines it should redirect, however the the service()
method indicates that its failing.

Does Tomcat work on port 8080?  I would guess that the Microsoft JVM
is causing your problems.  Try installing either Sun's JVM or IBM's.

Randy


-Original Message-
From: tefan Babos [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 1:00 PM
To: [EMAIL PROTECTED]
Subject: *** Please help me


Welcome,
I can't configure the ISAPI Redirector. I perform four installations, and I
exactly keep your procedure, but the
http://localhost/examples/jsp/index.html, cannot execute...
I don't known where problem is.
My configuration is Windows 98, PWS 4(working properly).
To this message I attached all needed files, mean conf(I use Microsoft Java
SDK), logs, pws and registry information about my settings.
Thank You very much for answer.

Stefan Babos
Czech Republic

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Please help. Going Nuts.

2001-03-01 Thread Jan Labanowski

On Thu, 1 Mar 2001, mikhail malamud wrote:

 OK. I got this to work. What's the next step, Jan?

Read my message again... There were more steps there {:-)}...
Read the notes at http://www.ccl.net/cca/software/UNIX/apache/index.shtml 
and http://www.ccl.net/cca/software/UNIX/apache/tomcatfaq.shtml

Primarily check if your web.xml is correct and in correct place, if
your server.xml has an entry:
   !-- Apache AJP13 support. This is also used to shut down tomcat.
  --
Connector className="org.apache.tomcat.service.PoolTcpConnector"
Parameter name="handler" 
   value="org.apache.tomcat.service.connector.Ajp13ConnectionHandler"/
Parameter name="port" value="8006"/
/Connector

and  you have
  Context path="/vitamin" 
docBase="/usr/local/apache/htdocs/vitamin" 
  crossContext="false"
  debug="0" 
  reloadable="true"  
   /Context
there.


And if the port is for ajp13 is the same as in worker.properties file.
Check if your worker.properties are configured correctly for apj13
and if you are including the right file in the httpd.conf

Once you corrected/cheked everything restart kill apache, kill tomcat
start tomcat, start apache.
 
 -Original Message-
 From: Jan Labanowski [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, March 01, 2001 12:51 PM
 To: [EMAIL PROTECTED]
 Cc: Jan Labanowski
 Subject: Re: Please help. Going Nuts.
 
 
 One thing at a time... Do not start from most complicated stuff... Try
 to make hello world JSP to work first
 In your directory
 /usr/local/apache/htdocs/vitamin put a file:
 
 hello.jsp
 
 HTML
 BODY
 Hello World
 /BODY
 HTML
 
 and try to get it in the browser:
 
 http://my.machine.com:8080/vitamin/hello.jsp
 and do it the same with your apache port, say
 http://my.machine.com/vitamin/hello.jsp
 
 (I do not know what your ports are, so you need to change it)
 
 
 On Thu, 1 Mar 2001, mikhail malamud wrote:
 
  
  mod_jk.conf. Apache Includes it in httpd.conf
 
  Alias /vitamin "/usr/local/apache/htdocs/vitamin"
  Directory "/usr/local/apache/htdocs/vitamin"
  Options Indexes FollowSymLinks
  /Directory
 
  JkMount /vitamin/servlet/* ajp13
  JkMount /vitamin/*.jsp ajp13
 
 
  Location "/vitamin/WEB-INF/"
  AllowOverride None
  deny from all
  /Location
 
 Looks OK...
 
 
  ##
  Context path="/vitamin"
   docBase="/usr/local/apache/htdocs/vitamin"
   crossContext="false"
   debug="0"
   reloadable="true" 
  /Context
 
 
 Can you see anything on the Tomcat port 8080 (or whatever it is in your
 case).
 i.e.,
 http://my.machine.com:8080/vitamin/hello.jsp
 
 Is your apj13 connected activated?
 
  ##
 
  At last. I added following entry into web.xml.
 
 Which web.xml? The /usr/local/apache/htdocs/vitamin/WEB-INF/web.xml ?
 
 
  #
  servlet
  servlet-nameHelloWorld/servlet-name
 The servlet name is not HelloWorld, it is HelloWorldExample
 
  servlet-classedu.myschool.util.HelloWorldExample/servlet-class
  /servlet
  servlet-mapping
  servlet-nameHelloWorld/servlet-name
 The servlet name is not HelloWorld, it is HelloWorldExample
  /url-pattern/*/url-pattern
 
 This is wrong...
  url-pattern/*/url-pattern
 
  /servlet-mapping
  #
 
 
 Jan K. Labanowski|phone: 614-292-9279,  FAX:
 614-292-7168
 Ohio Supercomputer Center|Internet: [EMAIL PROTECTED]
 1224 Kinnear Rd, |http://www.ccl.net/chemistry.html
 Columbus, OH 43212-1163  |http://www.osc.edu/
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
 

Jan K. Labanowski|phone: 614-292-9279,  FAX: 614-292-7168
Ohio Supercomputer Center|Internet: [EMAIL PROTECTED] 
1224 Kinnear Rd, |http://www.ccl.net/chemistry.html
Columbus, OH 43212-1163  |http://www.osc.edu/


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Reading a file from a Context

2001-03-01 Thread Brett G. Palmer

What is the best way to read a file from a Context in Tomcat?  I know I can
get the context path from the "getContextPath()" method, but most file
stream APIs require a full path.  There most be a clean way to accomplish
this without hard coding any directory path info.

Any suggestions would be appreciated?

Thanks,

Brett


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Startup AND shutdown of separate JVM's

2001-03-01 Thread Scott Tatum


I have been using Tomcat for a while now and with good success. I
recently setup virtual hosts (named vhosts) and was surprised when it
all worked the first time. =) The documentation in the mod_jk-howto was
a great help.

Here is my setup: I have two different (eventually more) virtual hosts
on one machine being served by Tomcat 3.2.1 and Apache 1.3.14. Right now
there is only one Tomcat JVM running, but I'm getting ready to break
this up into 2 separate JVM's. The configuration part is trivial now
that I have virtual hosts working, but there is one part I can't figure
out.

The two vhost setup is for production and development versions of the
same application. So one JVM I will need to restart regularly, and the
other needs to stay up as much as possible.

There are a couple of problems I forsee that I need to understand and
tackle before moving forward. One is that there is only startup/shutdown
script for Tomcat. I understand that, by creating different server.xml
configuration files and using (e.g.) startup.sh -f server1.xml, I can
start separate servers. My question is, how do I stop them separately?
If I have to write my own scripts I am willing to go that route, I just
want to make sure there's not some preexisting method.

Also I read in the FAQ that if you restart Tomcat, you also have to
restart Apache. I've tested this out with mixed results. Is this true?
If that is the case, running separate JVM's for each website becomes
useless to me. No offense to the other benefits of running separate
JVM's! If I have my production JVM which needs to stay up, but Apache
has to restart every time I restart my development JVM, wouldn't that
mean I have to restart my production JVM every time I restart my
development JVM? Worst case, I can run my development on the built-in
webserver, but it would be nice to use app.domain.com and
app-dev.domain.com without having to tack on a :8080.

So in review, my questions are: If running separate JVM's connected to a
single Apache, how do I restart one JVM while leaving the other running?
Also, if running under said setup, does restarting one Tomcat JVM mean
that Apache and any other Tomcat JVM's have to be restarted as well?
Thanks in advance for any insight.

-Scott
(p.s. was running JRun 3 before Tomcat. Experienced daily lockups. No
lockups with Tomcat and it is noticeably faster. JRun 3 has a nice
web-based admin setup though.)
--
Scott Tatum | [EMAIL PROTECTED]
Senior Applications Developer, Special Projects
WorldCom | http://www.wcom.com/



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: I CANT COMPILE SERVLETS!!!HELP

2001-03-01 Thread Zakaria .

Thanks everyone, my problem was that i just included the servlet.jar to the 
classpath, but in fact i had to include all in the tomcat\lib jars to the 
classpath, now i can compile by using only the javac command as with a 
regular java program...

_
Get your FREE download of MSN Explorer at http://explorer.msn.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Please help. Going Nuts.

2001-03-01 Thread mikhail malamud

ajp13 connector is set up properly because default app works fine with
it and so do my jsp's.
As you recommended, I decided to get simple things to get to work first.
So, I tried to execute a servlet not in
/WEB-INF/classes/edu/myschoo/util/HelloWorldExample
but simply in
/WEB-INF/classes/HelloWorldExample. This time tomcat found it. And here
is the error I got.
Why does the same servlet work under default package or even in
/examples-test but wont work under my webapp directory.
**
Error: 500
Location: /vitamin/servlet/HelloWorldExample
Internal Servlet Error:

java.util.MissingResourceException: Can't find bundle for base name
LocalStrings, locale en_US
at
java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.ja
va:707)
at java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:604)
at java.util.ResourceBundle.getBundle(ResourceBundle.java:559)
at HelloWorldExample.doGet(HelloWorldExample.java:25)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at
org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at
org.apache.tomcat.core.ContextManager.internalService(ContextManager.jav
a:797)
at
org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at
org.apache.tomcat.service.connector.Ajp13ConnectionHandler.processConnec
tion(Ajp13ConnectionHandler.java:160)
at
org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416
)
at
org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:49
8)
at java.lang.Thread.run(Thread.java:484)
**


-Original Message-
From: Jan Labanowski [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 1:28 PM
To: [EMAIL PROTECTED]
Cc: Jan Labanowski
Subject: RE: Please help. Going Nuts.


On Thu, 1 Mar 2001, mikhail malamud wrote:

 OK. I got this to work. What's the next step, Jan?

Read my message again... There were more steps there {:-)}...
Read the notes at
http://www.ccl.net/cca/software/UNIX/apache/index.shtml
and http://www.ccl.net/cca/software/UNIX/apache/tomcatfaq.shtml

Primarily check if your web.xml is correct and in correct place, if
your server.xml has an entry:
   !-- Apache AJP13 support. This is also used to shut down tomcat.
  --
Connector
className="org.apache.tomcat.service.PoolTcpConnector"
Parameter name="handler"

value="org.apache.tomcat.service.connector.Ajp13ConnectionHandler"/
Parameter name="port" value="8006"/
/Connector

and  you have
  Context path="/vitamin"
docBase="/usr/local/apache/htdocs/vitamin"
  crossContext="false"
  debug="0"
  reloadable="true" 
   /Context
there.


And if the port is for ajp13 is the same as in worker.properties file.
Check if your worker.properties are configured correctly for apj13
and if you are including the right file in the httpd.conf

Once you corrected/cheked everything restart kill apache, kill tomcat
start tomcat, start apache.

 -Original Message-
 From: Jan Labanowski [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, March 01, 2001 12:51 PM
 To: [EMAIL PROTECTED]
 Cc: Jan Labanowski
 Subject: Re: Please help. Going Nuts.


 One thing at a time... Do not start from most complicated stuff... Try
 to make hello world JSP to work first
 In your directory
 /usr/local/apache/htdocs/vitamin put a file:

 hello.jsp

 HTML
 BODY
 Hello World
 /BODY
 HTML

 and try to get it in the browser:

 http://my.machine.com:8080/vitamin/hello.jsp
 and do it the same with your apache port, say
 http://my.machine.com/vitamin/hello.jsp

 (I do not know what your ports are, so you need to change it)


 On Thu, 1 Mar 2001, mikhail malamud wrote:

  
  mod_jk.conf. Apache Includes it in httpd.conf
 
  Alias /vitamin "/usr/local/apache/htdocs/vitamin"
  Directory "/usr/local/apache/htdocs/vitamin"
  Options Indexes FollowSymLinks
  /Directory
 
  JkMount /vitamin/servlet/* ajp13
  JkMount /vitamin/*.jsp ajp13
 
 
  Location "/vitamin/WEB-INF/"
  AllowOverride None
  deny from all
  /Location

 Looks OK...


  ##
  Context path="/vitamin"
   docBase="/usr/local/apache/htdocs/vitamin"
   crossContext="false"
   debug="0"
   reloadable="true" 
  /Context


 Can you see anything on the Tomcat port 8080 (or whatever it is in
your
 case).
 i.e.,
 http://my.machine.com:8080/vitamin/hello.jsp

 Is your apj13 connected activated?

  ##
 
  At last. I 

Re: Life of a class?

2001-03-01 Thread Bo Xu

Neil Edney wrote:

 Hi,

 We have implemented a database connection pool class (extract below) and use
 the 'getInstance' method to ensuire that there is only one instance created
 at any one time.

 What we need to know is when will this class be destroyed? Is it went the
 server is stopped (or crashed!) or will it timeout after a period of
 non-use?

 Regards,
 Neil

 public class DbPool extends Object implements java.io.Serializable {

 private static DbPool instance;

 public static DbPool getInstance(){
 if (instance == null)
 instance = new DbPool();
 return instance;
 }

 /** Creates new dbPool */
 private DbPool(){

 /** dbPool code */

 }
 }
 [...]

Hi :-)   from a email in Servlet-List, there is a sample code
for DBConnectionPool in the following link:
http://www.webdevelopersjournal.com/columns/connection_pool.html

and in Jason Hunter's book, from P266, there is also a sample of
ConnectionPool.

I think you need make getInstance() method "synchronized",
please see the first sample.

The following is just my understanding, as a reference:
( I use "MyServlet" to standard for my Servlet class,
  I use "MyHelper" to standard for DBConnectionPool)

*  the steps:
- the bytecode of MyHelper in MyHelper.class file
  (or in a database...)
- it is loaded by a classloader, now we have "a Class
  object of MyHelper", now this classloader holds a
  reference to this Class object, this Class object itself
  is a instance of "the class Class"
- several instances(or only one, for example, SingleTon in
   your code) of MyHelper  are/is made "from" that Class
   object. normally our Servlet holds the reference(s) to
   these/this instance(s). But with SingleTon mode, "the Class
   object of MyHelper" Also hold a reference to that
   OnlyOneInstance of MyHelper with a static field(in your
   code,  its name is "instance")

- the classloader of MyServlet may be Or may Not be the same
  one with that classloader who loads MyHelper. with
  jakarta-tomcat-4.0-b1, it depends on Where we put
  MyHelper.class(or MyHelper.jar) .

*  now there are several cases:
- MyServlet lose/release the reference(s)(for example, after
   reloading), now because "the Class object of MyHelper"
   Also hold a reference to that OnlyOneInstance of MyHelper
   with a static field (its name is "instance"), so "that
   OnlyOneInstance" will not be GCed.
 - if the classloader of MyHelper is destroied, then
"the Class object of MyHelper" is not there, but perhaps
that OnlyOneInstance is still there(if MyServlet still hold
a reference to it, or if we already put a reference to it into
ServletContext or somewhere else...), now perhaps our
code will get a Exception.

- if the classloader of MyServlet and MyHelper is the same
   one, now with jakarta-tomcat-4.0-b1, when MyServlet
   is reloaded, the classloader will be destroied, and so,
   MyHelper also lose its classloader.

- so if we want to let MyHelper live "Longer" than MyServlet,
   perhaps we need to load MyHelper with another classloader
   (for example, Shared classloader or "System classloader"  or
other)

- another question: if we use classloaderA(for example, an instance
  of URLClassLoader) to load MyHelper,  and we are sure that
  classloaderA  will not be destroied, then is it Possible that
  classloaderA will "unload" MyHelper and re-load it again?
  I am not sure, but I guess perhaps it is not possible. I find
  the following in "The Java Language Specification"(Second
  Edition): http://java.sun.com/docs/books/jls/

...
12.7 Unloading of Classes and Interfaces
An implementation of the Java programming language may unload
classes. A class or interface may be unloaded if and only if its
defining class loader may be reclaimed by the garbage collector as
discussed in 12.6. Classes and interfaces loaded by the bootstrap
loader may not be unloaded.Here is the rationale for the rule given
in the previous paragraph:

Class unloading is an optimization that helps reduce memory use.
Obviously, the semantics of a program should not depend on whether
and how a system chooses to implement an optimization such as class
unloading. To do otherwise would compromise the portability of
programs. Consequently, whether a class or interface has been
unloaded or not should be transparent to a program.

However, if a class or interface C was unloaded while its defining loader
was potentially reachable, then C might be reloaded. One could never
ensure that this would not happen. Even if the class was not referenced
by any other currently loaded class, it might be referenced by some class
or interface, D, that had not yet been loaded. When D is loaded by C's
defining loader, its execution might cause reloading of C.

Reloading may not be transparent 

Virtual hosts

2001-03-01 Thread Julie Ruiz

Hi,

How can I setup virtual hosts in Tomcat using SSL direct

Thanks,

Julie.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: CLASSPATH and Load-on-startup related issue - bug ??

2001-03-01 Thread Srinivas Kurella



Anuj,
Do you 
have a servlet that is loaded on startup ? I have a feeling that to laod the 
servlet on startup , tomcat needs all the classes in the classpath, which forces 
me to put the jars in the classpath. I can't get to the jasper.log stage, if the 
startup servlet can't be loaded. 
Can 
somebody who knows the specs and the implementation please respond and clarify 
if this is a known bug .
Thanks,
Srini

  -Original Message-From: Anuj Agrawal 
  [mailto:[EMAIL PROTECTED]]Sent: Wednesday, February 28, 2001 6:04 
  PMTo: [EMAIL PROTECTED]Subject: Re: 
  CLASSPATH and Load-on-startup related issue - bug 
  ??Actually, i believe tomcat does pick up the jars from 
  the WEB-INF/lib directory. You might want to try looking in the 
  jasper.log file in the logs directory. It should show something like: 
  Classpath according to the Servlet Engine is: list of jar files in 
  WEB-INF/lib dir 
  I'm using tomcat 3.2.1 - not sure if that makes a diff. Originally i 
  thought i needed to add the jar files to classpath via the wrapper.properties 
  file, but then i found that i didn't need to. 
  Hope that helps. Anuj. 
  Srinivas Kurella wrote: 
  i am reposting this. I didn't 
get any responses. Does anybody have an answer 
??Thanks in 
advance.Srini 

  -Original Message- From: Srinivas Kurella 
  Sent: Wednesday, February 28, 
  2001 1:04 PM To: 
  '[EMAIL PROTECTED]' Subject: RE: CLASSPATH and Load-on-startup related issue - 
  bug ?? Actually , it looks as 
  if tomcat doesn't pick up the jars from the web-inf/lib directory. Once i 
  added the jars explicitly to the classpath is worked. Is this a bug 
  ??? 
  Srini 
  -Original Message- From: 
  Srinivas Kurella Sent: Wednesday, February 28, 
  2001 12:32 PM To: 
  '[EMAIL PROTECTED]' Subject: 
  CLASSPATH and Load-on-startup related issue ??  
  I have an application which is running under tomcat. 
  However i donot use the 2.2 spec directory 
  structure. I have a servlet that is loaded on startup. I explicitly set the CLASSPATH with all the jars needed. 
  I am trying to move to the webapps/ directory structure 
  where i can put all the jars under 
  WEB-INF/lib. However the startup servlet fails 
  with some class not found exception. Is the 
  CLASSPATH variable ignored in this case ?? What could be the problem 
  ?? The startup servlet is a class in a jar in 
  WEB-INF/lib. 
  Thanks 
  Srini 
  - 
  To unsubscribe, e-mail: 
  [EMAIL PROTECTED] For 
  additional commands, email: 
[EMAIL PROTECTED]- 
  To unsubscribe, e-mail: [EMAIL PROTECTED] For 
  additional commands, email: [EMAIL PROTECTED] 



RE: Poolman and Tomcat - where does the poolman.props file go

2001-03-01 Thread tnist

Ariel,

Thanks for the reply, but I have already tried this with no success.  I sent
the classpath set by tomcat out to a file and the directory containing the
property file is in there, but I still get the error.  Any other ideas?

Regards,

Todd

-Original Message-
From: Ariel [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 11:56 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Poolman and Tomcat - where does the poolman.props file go



Add some directory (like c:\tomcat\lib) to your CLASSPATH and copy
poolman.props to this directory.

Ariel

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 6:08 PM
To: [EMAIL PROTECTED]
Subject: Poolman and Tomcat - where does the poolman.props file go


Hello all,

My configuration is as follows:  

WIN2K 
Apache 1.3.14
Tomcat 3.2.1
Poolman 1.4.1

I have include the poolman.jar file in my CLASSPATH as per the
documentation.  I have tested the connection with the PoolManSample.java
program provided and all works fine from outside of tomcat.  I have a
servlet which now attempts to connect to the database via PoolMan, but I
keep getting the following error:

 Could not find 'poolman.props' -- now attempting to read deprecated
file name 'pool.props'... failed.

I have tried placing the poolman.props file in my webapps directory,
TOMCAT_HOME\webapps\myapp and in the classes directory under myapp and in
about every other directory I can think of but to no avail.  Is there
something else I need to configure in the web.xml or in tomcat.conf to have
this work correctly?

Any help with this is appreciated.

Regards,

Todd G. Nist
Email:   [EMAIL PROTECTED]



The information in this electronic mail ("e-mail") message may
be confidential and for use of only the named recipient.  The
information may be protected by privilege, work product immunity
or other applicable law.  If you are not the intended recipient
the retention, dissemination, distribution or copying of this
e-mail message is strictly prohibited.  If you receive this e-mail
message in error please notify us immediately by telephone
at 770-723-1011 or [EMAIL PROTECTED]  Thank you. 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]


The information in this electronic mail ("e-mail") message may
be confidential and for use of only the named recipient.  The
information may be protected by privilege, work product immunity
or other applicable law.  If you are not the intended recipient
the retention, dissemination, distribution or copying of this
e-mail message is strictly prohibited.  If you receive this e-mail
message in error please notify us immediately by telephone
at 770-723-1011 or [EMAIL PROTECTED]  Thank you. 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Servlet and JDBC driver problems

2001-03-01 Thread Steve G

I have an Oracle database that I can connect to from a java program.  When I 
convert this program to a servlet and try to bring it up in Netscape through 
the Tomcat Server I get a ClassNotFoundException OracleDriver.

Is there anything special I need to do in Tomcat to connect to Oracle.

Thanks for the help.
Steve
_
Get your FREE download of MSN Explorer at http://explorer.msn.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




documentation

2001-03-01 Thread tom



Hi all,

I am new to this list and have been learning how to 
use Cocoon and Tomcat after getting interestedin XML. I have had 
real problems with all the documentation. Even Brett McLaughlin's book "Java and 
XML", which I bought,seems out of date already - and the instructions do 
not work (at least not when I try them).
This means that days, even weeksare wasted 
just trying to piece together enough information to get the basic tools up and 
running.
I do not mean this as criticism: preparing 
documentation is an enormous undertaking, especially doing it for people 
who might have a very "limited" - perhaps non-existent ;) - knowledge, and 
particularly when people preparing the documentation are so familiar with 
platforms, standards, OSes, programming etc.

The point I would like to make is that we need a 
new approach to documentation preparation:

1 the success of the "works out of the box" 
software brigade is precisely because it installs when double-clicked!! it may 
not do much else, it will almost certainly adhere to proprietary standards, but 
after the excruciatingly painful time I have had to get Cocoon and Tomcat 
working, just on a laptop, it is obvious why people stick with "out of the box" 
stuff;

2 IMHO a new publishing framework will only truly 
succeed when non-programmers etc like myself can access the new tools in a less 
painful way, gain familiarity with them and thinkof things to do with them 
- this might result in tools being used in ways that are less dominated by the 
IT industries various mentalities, and mean that Standards that are set (by eg 
W3C) prevail in the longer term;

3 the success of open source depends upon people 
with limited computer skills being able to specify and use open source tools in 
their projects, work etc. without having to run to their sysadmins, programmers 
etc every five minutes over what are, to the experienced, ridiculously simple 
problems;

4 there is also a problem with accessibility: many 
people use dial-up to access the internet; in a lot of countries, as here in the 
UK, that dial-up is not free of charge - this means that to spend hours trying 
to piece together the various, inconsistent sources of documentation, even the 
archives, to try and get a picture of how to get something up and running is so 
full of frustration and so expensive,that having "played" around for a 
while you just retreat and look at the old, proprietary ways of doing 
things;

These problems are not unique to this project, I 
have found it before - also with proprietary packages - as I am sure we all 
have. However, just as the internetworked world does not belong only to 
the corporates, neither does it belong only to people who are computer or 
software experts. The success of proprietary standards is not because 
people are lazy, but becausealternative tools are so 
inaccessible.

I would like to help to find a way of improving the 
documentation so that the tools are more accessible.

I repeat that this is not a criticism 
-documentation is a large task and who wants to do that when they are 
brilliant software engineers at the cutting edge ;) !! and have so little 
time.

I do not know how to proceed from here but would be 
willing to help out. 

I apologise to those who may consider this e-mail 
off-topic, but I just could not keep silent any longer.

Best wishes

Tom Nimmo




RE: How to avoid the following exception

2001-03-01 Thread Dmitry Rogatkin

I eliminated the problem, but since i did two things, i do not know which one is the 
cure. 1st. i have download last t build. 2nd I added checking on null where actual 
erro was happened.

Dmitry R., [EMAIL PROTECTED]
Chief Architect, MetricStream.COM
Santa Clara, CA






-Original Message-
From:niv the tool [EMAIL PROTECTED]
Sent:Thu, 1 Mar 2001 13:05:14 +0200
To:  [EMAIL PROTECTED], [EMAIL PROTECTED]
Subject: RE: How to avoid the following exception



i also got it .


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, February 20, 2001 10:49 PM
To: [EMAIL PROTECTED]
Subject: How to avoid the following exception


Anybody knows what can be issue for:
Catalina.start: LifecycleException:  start: :
java.lang.IllegalArgumentExceptio
n: addRepositoryInternal: java.lang.NullPointerException
LifecycleException:  start: :  java.lang.IllegalArgumentException:
addRepository
Internal: java.lang.NullPointerException
at
org.apache.catalina.loader.StandardLoader.start(StandardLoader.java:5
62)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1136)

at
org.apache.catalina.core.StandardContext.start(StandardContext.java:2
903)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1160)

at
org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1160)

at
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:217
)
at
org.apache.catalina.core.StandardService.start(StandardService.java:3
53)
at
org.apache.catalina.core.StandardServer.start(StandardServer.java:454
)
at org.apache.catalina.startup.Catalina.start(Catalina.java:677)
at org.apache.catalina.startup.Catalina.execute(Catalina.java:618)
at org.apache.catalina.startup.Catalina.process(Catalina.java:175)
at java.lang.reflect.Method.invoke(Native Method)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:134)
All classes and jars are valid and work without problem when JServ is ised.

Thanks,
Dmitry R., [EMAIL PROTECTED]
Chief Architect, MetricStream.COM
Santa Clara, CA

___
Visit http://www.visto.com/info, your free web-based communications center.
Visto.com. Life on the Dot.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




___
Visit http://www.visto.com/info, your free web-based communications center.
Visto.com. Life on the Dot.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Too many open files with Tomcat-3.2.1 under Solaris

2001-03-01 Thread Ben Flaumenhaft

Hi Zsolt,

Most UNIX systems need one file descriptor per open socket. That error
message almost always means you don't have enough file descriptors. In
Linux, at least the last time I checked, you need to recompile the kernel to
change the number of file descriptors allocated by the system. Under
Solaris, you can change it in /etc/system.

See:

http://www.rational.com/technotes/clearcase_html/ClearCase_html/technote_344
.html

I'd recommend bumping it to 1024 and see if your problem goes away.

Hope that helps.

Regards,
Ben Flaumenhaft
Principal, Sidelight Consulting
http://www.sidelight.com

- Original Message -
From: "Zsolt Koppany" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 6:59 AM
Subject: Too many open files with Tomcat-3.2.1 under Solaris


 Hi,

 I just want to port our tomcat application to Solaris-2.7 and after a
 short time I get the error message "Too many open files" from
 java.net.SocketException.

 The same applications does not have the problem under Linux.

 I'm pretty sure that not our application causes the problem.

 I use j2sdk1_3_0_02 under Solaris.

 Any ideas?


 --
 Zsolt Koppany
 Intland GmbH www.intland.com
 Schulze-Delitzsch-Strasse 16
 D-70565 Stuttgart
 Tel: +49-711-7871080 Fax: +49-711-7871017

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Tomcat Crashes

2001-03-01 Thread Ben Flaumenhaft


You might also try a different VM ... IBM, for example.

Regards,
Ben Flaumenhaft
Principal, Sidelight Consulting
http://www.sidelight.com

- Original Message - 
From: "Kishor K" [EMAIL PROTECTED]
To: "Tomcat User Mailing List" [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 2:57 AM
Subject: Tomcat Crashes


 hi,
  I have Tomcat 3.1 and jdk 1.2.2 on  TWO Windows NT machines.
 Both the machines are loaded with the same code,same database.
  But on one machine it is causing Dr.Watson error 2-3 times a day whereas
 the other one is working properly.
 
  Could you help in anyway on this?
 
  thanks in advance
  kishor
 
 
 
 
 _
 Do You Yahoo!?
 Get your free @yahoo.com address at http://mail.yahoo.com
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: Life of a class?

2001-03-01 Thread Ben Flaumenhaft


Hi Neil,

Your pool class probably has a static member for the single instance
retrieved by getInstance (), right? If so, this instance is reset only when
the server is restarted or stopped, or when you explicitly release it
yourself.

(By the way, Tomcat maintains a separate classloader for each context (i.e.,
each webapp). Static variables exist within the classloader. This means if
you have multiple contexts, i.e., the same app instantiated several times in
the same Tomcat, you'll have several instances).

Regards,
Ben Flaumenhaft
Principal, Sidelight Consulting
http://www.sidelight.com

- Original Message -
From: "Neil Edney" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 01, 2001 2:00 AM
Subject: Life of a class?


 Hi,

 We have implemented a database connection pool class (extract below) and
use
 the 'getInstance' method to ensuire that there is only one instance
created
 at any one time.

 What we need to know is when will this class be destroyed? Is it went the
 server is stopped (or crashed!) or will it timeout after a period of
 non-use?

 Regards,
 Neil


 public class DbPool extends Object implements java.io.Serializable {

 private static DbPool instance;

 public static DbPool getInstance(){
 if (instance == null)
 instance = new DbPool();
 return instance;
 }

 /** Creates new dbPool */
 private DbPool(){

 /** dbPool code */

 }
 }


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Re: RMI

2001-03-01 Thread Sergey V. Udaltsov

 I've just got my serlevt working as an RMI client. To do this I had to edit
 the tomcat.policy file to give all permissions to everything, and use the
 rmiSecurityManager. See my earlier posts for more info
So it is impossible to publish such a servlet without affecting base
Tomcat configuration, isn't it? That's pity:(
And I am not sure I want to give AllPermissions. Did you try to refine
the permissions?

Sergey

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Multiple Concurrent Servlet Initialization

2001-03-01 Thread Arne Handt

Hello All,

I know that this topic has been discussed about two months ago but I wasn't
able to find a hint helping me to solve my problem in the archive, so I
touch it again.
My problem: I have a multithreaded using W3C's Jigsaw HTTP Stack to access
my servlet (on Jakarta Tomcat v3.1) with multiple requests concurrently,
using the same URL (with a gap of about 20 ms between sending the requests).
This is, of course, no problem, when the servlet is already initialized, but
it leads to multiple servlet instantiation and initialization, if the
servlet has not been initialized before.
Is this a Tomcat bug or can it be switched off ? Can anyone help me ? Please
tell me if you need more information in order to help.
Thanks for your effort.

Best regards,
Arne

--

 Arne Handt
 Shinka Technologies AG
 Tempelhofer Ufer 8-9
 10963 Berlin
 http://www.shinkatech.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Please help. Going Nuts.

2001-03-01 Thread Jan Labanowski

Again, My advice would be to put a simple HelloWorldExample.java servlet.
You probably have some complicated stuff. Keep it simple like:
--- cut -
/* $Id: HelloWorldExample.java,v 1.1.1.1 1999/10/09 00:19:59 duncan Exp $
 *  Modifed by jkl
 */

import java.io.*;
import java.text.*;
import java.util.*;
import javax.servlet.*;
import javax.servlet.http.*;

public class HelloWorldExample extends HttpServlet {
  HttpServletResponse response)
throws IOException, ServletException
{
response.setContentType("text/html");
PrintWriter out = response.getWriter();

out.println("html");
out.println("head");
out.println("titletest/title");
out.println("/head");
out.println("body bgcolor=\"yellow\"");
out.println("H1Hello there/H1BR");
out.println("/body");
out.println("/html");
}
}
--- cut -

in the /usr/local/apache/htdocs/vitamin/WEB-INF/classes
than do 
  javac HelloWorldExample.java
Assuming that you have the classpath to servlet.jar and your JDK classes set
it would produce HelloWorldExample.class in the same directory.
Then do:
   http://mymachine.com:8080/servlet/HelloWorldExample
and
   http://mymachine.com/servlet/HelloWorldExample
and see if you can see it working.

Jan


On Thu, 1 Mar 2001, mikhail malamud wrote:

 ajp13 connector is set up properly because default app works fine with
 it and so do my jsp's.
 As you recommended, I decided to get simple things to get to work first.
 So, I tried to execute a servlet not in
 /WEB-INF/classes/edu/myschoo/util/HelloWorldExample
 but simply in
 /WEB-INF/classes/HelloWorldExample. This time tomcat found it. And here
 is the error I got.
 Why does the same servlet work under default package or even in
 /examples-test but wont work under my webapp directory.
 **
 Error: 500
 Location: /vitamin/servlet/HelloWorldExample
 Internal Servlet Error:
 
 java.util.MissingResourceException: Can't find bundle for base name
 LocalStrings, locale en_US
   at
 java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.ja
 va:707)
   at java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:604)
   at java.util.ResourceBundle.getBundle(ResourceBundle.java:559)
   at HelloWorldExample.doGet(HelloWorldExample.java:25)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
   at
 org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
   at org.apache.tomcat.core.Handler.service(Handler.java:286)
   at
 org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
   at
 org.apache.tomcat.core.ContextManager.internalService(ContextManager.jav
 a:797)
   at
 org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
   at
 org.apache.tomcat.service.connector.Ajp13ConnectionHandler.processConnec
 tion(Ajp13ConnectionHandler.java:160)
   at
 org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416
 )
   at
 org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:49
 8)
   at java.lang.Thread.run(Thread.java:484)
 **
 
 
 -Original Message-
 From: Jan Labanowski [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, March 01, 2001 1:28 PM
 To: [EMAIL PROTECTED]
 Cc: Jan Labanowski
 Subject: RE: Please help. Going Nuts.
 
 
 On Thu, 1 Mar 2001, mikhail malamud wrote:
 
  OK. I got this to work. What's the next step, Jan?
 
 Read my message again... There were more steps there {:-)}...
 Read the notes at
 http://www.ccl.net/cca/software/UNIX/apache/index.shtml
 and http://www.ccl.net/cca/software/UNIX/apache/tomcatfaq.shtml
 
 Primarily check if your web.xml is correct and in correct place, if
 your server.xml has an entry:
!-- Apache AJP13 support. This is also used to shut down tomcat.
   --
 Connector
 className="org.apache.tomcat.service.PoolTcpConnector"
 Parameter name="handler"
 
 value="org.apache.tomcat.service.connector.Ajp13ConnectionHandler"/
 Parameter name="port" value="8006"/
 /Connector
 
 and  you have
   Context path="/vitamin"
 docBase="/usr/local/apache/htdocs/vitamin"
   crossContext="false"
   debug="0"
   reloadable="true" 
/Context
 there.
 
 
 And if the port is for ajp13 is the same as in worker.properties file.
 Check if your worker.properties are configured correctly for apj13
 and if you are including the right file in the httpd.conf
 
 Once you corrected/cheked everything restart kill apache, kill tomcat
 start tomcat, start apache.
 
  -Original Message-
  From: Jan Labanowski [mailto:[EMAIL PROTECTED]]
  Sent: Thursday, March 01, 2001 12:51 PM
  To: [EMAIL PROTECTED]
  Cc: Jan Labanowski
  Subject: Re: Please 

Log File isapi.log Too Big

2001-03-01 Thread Eli Segev


After using Tomcat with IIS 4.0 with the the ISAPI redirector for a while, I
have realized that the log file is growing and growing.  I would like to empty
the file once in a while.  Is there any clean way of doing it?

--
Eli Segev
PTC
(781)370-6127



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Error building DSO support with Apache

2001-03-01 Thread Craig Bush


Hey guys this indirectly is a Tomcat question

SGI Octane II running IRIX 6.5.10 dual 400 MHz processor 1 Gig RAM

Used 

./configure \
--prefix=/usr/local/apache \
--enable-rule=SHARED_CORE \
--enable-module=so

with no problems.  

However, when I run make (GNU make) I get:

=
=== src/modules/standard
=== src/modules
gcc -c  -I./os/unix -I./include   -DIRIX -DUSE_HSREGEX -DUSE_EXPAT
-I./lib/expat-lite -fpic -DSHARED_CORE `./apaci` modules.c
gcc -c  -I./os/unix -I./include   -DIRIX -DUSE_HSREGEX -DUSE_EXPAT
-I./lib/expat-lite -fpic -DSHARED_CORE `./apaci` buildmark.c
ld -shared -o libhttpd.so buildmark.o modules.o
modules/standard/libstandard.a main/libmain.a ./os/unix/libos.a
ap/libap.a regex/libregex.a lib/expat-lite/libexpat.a  
ln libhttpd.so libhttpd.so.1
ln libhttpd.so libhttpd.so.1.3
ln libhttpd.so libhttpd.so.1.3.19
gcc  -I./os/unix -I./include   -DIRIX -DUSE_HSREGEX -DUSE_EXPAT
-I./lib/expat-lite -fpic -DSHARED_CORE `./apaci`\
  -o libhttpd.ep -DSHARED_CORE_TIESTATIC main/http_main.c \
  -L. -lhttpd  
ld32: WARNING 84 : ./libhttpd.so is not used for resolving any symbol.
ld32: ERROR   33 : Unresolved text symbol "ap_main" -- 1st referenced by
/var/tmp/ccUOZ2Fd.o.
Use linker option -v to see when and which objects, archives and
dsos are loaded.  
ld32: ERROR   33 : Unresolved text symbol "ap_validate_password" -- 1st
referenced by /var/tmp/ccUOZ2Fd.o.
Use linker option -v to see when and which objects, archives and
dsos are loaded.  
ld32: ERROR   33 : Unresolved text symbol "XML_ErrorString" -- 1st
referenced by /var/tmp/ccUOZ2Fd.o.
Use linker option -v to see when and which objects, archives and
dsos are loaded.  
ld32: INFO152: Output file removed because of error.
collect2: ld returned 2 exit status
make[2]: *** [libhttpd.ep] Error 1
make[2]: Leaving directory `/usr/local/apache_1.3.19/src'
make[1]: *** [build-std] Error 2
make[1]: Leaving directory `/usr/local/apache_1.3.19'
make: *** [build] Error 2



Any ideas?

Thanks,
-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  Craig R. Bush
  Bioinformatics Software Engineer
  Sealy Center for Structural Biology
  Dept. of Human Biological Chemistry  Genetics
  University of Texas Medical Branch
  Galveston, TX  77555-1157 (409)747-6809; Fax -6850
  http://www.bioinfo.utmb.edu http://www.hbcg.utmb.edu
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Log File isapi.log Too Big

2001-03-01 Thread Randy Layman


Sadly, no.  You must stop IIS, remove the file, and restart IIS.
Not to hard with a .bat file, however it causes outages in your
availability.

Batch file would be something like:
net stop "World Wide Web Publishing Service"
del isapi.log
net start "World Wide Web Publishing Service"

Once I got my server running, I turned the logging down to FATAL and
it doesn't seem to grow to much.

Randy

-Original Message-
From: Eli Segev [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 3:27 PM
To: [EMAIL PROTECTED]
Subject: Log File isapi.log Too Big



After using Tomcat with IIS 4.0 with the the ISAPI redirector for a while, I
have realized that the log file is growing and growing.  I would like to
empty
the file once in a while.  Is there any clean way of doing it?

--
Eli Segev
PTC
(781)370-6127



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Unable to compile servlet in Windows-NT-Please help

2001-03-01 Thread RaviShankar K




Hi,

I could not compile servlet in Windows 
NT.Tomcat is running successfully. I included all jar files in CLASSPATH . 
But in the class path Tomcat is showing a part as C:\tomcat\classes . I could 
not see "classes" under tomcat . Is that a problem ?
 Please tell me to compile a 
servlet in Tomcat .

Regards,
Ravi


RE: Error building DSO support with Apache

2001-03-01 Thread Mike Braden

This is what I usually use to build apache:

# ./configure --prefix=/usr/local/apache \
  --enable-module=most \
  --enable-shared=max

# make
# make install

Try and see if you still get errors.
Were you able to build apache before you tried shared_core?

--
Mike Braden
[EMAIL PROTECTED]


-Original Message-
From: Craig Bush [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 4:06 PM
To: [EMAIL PROTECTED]
Subject: Error building DSO support with Apache



Hey guys this indirectly is a Tomcat question

SGI Octane II running IRIX 6.5.10 dual 400 MHz processor 1 Gig RAM

Used 

./configure \
--prefix=/usr/local/apache \
--enable-rule=SHARED_CORE \
--enable-module=so

with no problems.  

However, when I run make (GNU make) I get:


=
=== src/modules/standard
=== src/modules
gcc -c  -I./os/unix -I./include   -DIRIX -DUSE_HSREGEX -DUSE_EXPAT
-I./lib/expat-lite -fpic -DSHARED_CORE `./apaci` modules.c
gcc -c  -I./os/unix -I./include   -DIRIX -DUSE_HSREGEX -DUSE_EXPAT
-I./lib/expat-lite -fpic -DSHARED_CORE `./apaci` buildmark.c
ld -shared -o libhttpd.so buildmark.o modules.o
modules/standard/libstandard.a main/libmain.a ./os/unix/libos.a
ap/libap.a regex/libregex.a lib/expat-lite/libexpat.a  
ln libhttpd.so libhttpd.so.1
ln libhttpd.so libhttpd.so.1.3
ln libhttpd.so libhttpd.so.1.3.19
gcc  -I./os/unix -I./include   -DIRIX -DUSE_HSREGEX -DUSE_EXPAT
-I./lib/expat-lite -fpic -DSHARED_CORE `./apaci`\
  -o libhttpd.ep -DSHARED_CORE_TIESTATIC main/http_main.c \
  -L. -lhttpd  
ld32: WARNING 84 : ./libhttpd.so is not used for resolving any symbol.
ld32: ERROR   33 : Unresolved text symbol "ap_main" -- 1st referenced by
/var/tmp/ccUOZ2Fd.o.
Use linker option -v to see when and which objects, archives and
dsos are loaded.  
ld32: ERROR   33 : Unresolved text symbol "ap_validate_password" -- 1st
referenced by /var/tmp/ccUOZ2Fd.o.
Use linker option -v to see when and which objects, archives and
dsos are loaded.  
ld32: ERROR   33 : Unresolved text symbol "XML_ErrorString" -- 1st
referenced by /var/tmp/ccUOZ2Fd.o.
Use linker option -v to see when and which objects, archives and
dsos are loaded.  
ld32: INFO152: Output file removed because of error.
collect2: ld returned 2 exit status
make[2]: *** [libhttpd.ep] Error 1
make[2]: Leaving directory `/usr/local/apache_1.3.19/src'
make[1]: *** [build-std] Error 2
make[1]: Leaving directory `/usr/local/apache_1.3.19'
make: *** [build] Error 2




Any ideas?

Thanks,
-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
  Craig R. Bush
  Bioinformatics Software Engineer
  Sealy Center for Structural Biology
  Dept. of Human Biological Chemistry  Genetics
  University of Texas Medical Branch
  Galveston, TX  77555-1157 (409)747-6809; Fax -6850
  http://www.bioinfo.utmb.edu http://www.hbcg.utmb.edu
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




trouble in starting tomcat

2001-03-01 Thread Adilakshmi Lingam

Hi,
I've been using tomcat 3.2.1 successfully on win2k with jdk1.2.2. I was
having frequent tomcat crashes fromt the time I started having jdbc-odbc
connectivity in my servlets. I was thinking of changing my JVM to avoud the
crashes. and Now before I made any changes, the tomcat doesn't start at all.
or maybe I should say, it crashes immediately(I just get the glimpse of the
window).
What to do?

Thanks in advance,
Lakshmi


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: trouble in starting tomcat

2001-03-01 Thread Randy Layman


First, try starting tomcat with bin\tomcat run (note the parameter
run) - this will start in the same window and will keep the error on screen.

Second, the cause of your crashes is the JDBC-OBDC bridge.  This
component is not thread safe.  As soon as the second concurrent access is
attempted, a crash occurs.  You must either serialize your requests
(completely, you can only have one connection object at a time) or find
another way to access your data.

Randy

-Original Message-
From: Adilakshmi Lingam [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 3:58 PM
To: [EMAIL PROTECTED]
Subject: trouble in starting tomcat


Hi,
I've been using tomcat 3.2.1 successfully on win2k with jdk1.2.2. I was
having frequent tomcat crashes fromt the time I started having jdbc-odbc
connectivity in my servlets. I was thinking of changing my JVM to avoud the
crashes. and Now before I made any changes, the tomcat doesn't start at all.
or maybe I should say, it crashes immediately(I just get the glimpse of the
window).
What to do?

Thanks in advance,
Lakshmi


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




RE: Servlet and JDBC driver problems

2001-03-01 Thread Mike Braden

You need to make the oracle jdbc drivers avaiable in either the classpath
or in the lib dir of the webapp you are using ( webapps/myapp/WEB-INF/lib ).

I have been successful using the thin driver.  The oci8 driver needs to
have access to the oracle libraries while the thin driver only needs the
odbc class files.

The oracle classes crash tomcat if you put them in $TOMCAT_HOME/lib

Mike.
--
Mike Braden
[EMAIL PROTECTED]


-Original Message-
From: Steve G [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 01, 2001 2:55 PM
To: [EMAIL PROTECTED]
Subject: Servlet and JDBC driver problems


I have an Oracle database that I can connect to from a java program.  When I

convert this program to a servlet and try to bring it up in Netscape through

the Tomcat Server I get a ClassNotFoundException OracleDriver.

Is there anything special I need to do in Tomcat to connect to Oracle.

Thanks for the help.
Steve
_
Get your FREE download of MSN Explorer at http://explorer.msn.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




  1   2   >