How to specify min/max memory on Tomcat 3.3?

2004-08-29 Thread nyhgan
 
Hi,
 
Is there anyway to specify the minimum and maximum memory on Tomcat 3.3?  What is the 
default maximum memory? Thanks!
 
 
nyhgan.
 
 
 


-
Do you Yahoo!?
Take Yahoo! Mail with you! Get it on your mobile phone.

Problem with WebApp Classloader using remote Jmx initialization of the Web module.

2004-08-29 Thread Alex Smirnoff
I'm trying to create the WebAppContext remotely with JMX (Tomcat 5.0.27, JDK
1.5)and doing something like this:

public void deployApplication(String context, String path) throws
CoreException {
  init();
  try {
   ObjectName webmodule =
 new
ObjectName(DOMAIN+":j2eetype=WebModule,name=//localhost/"+context+",J2EEAppl
ication=none,J2EEServer=none");
   mbsc.createMBean("org.apache.commons.modeler.BaseModelMBean", webmodule,
 new Object[] {"org.apache.catalina.core.StandardContext"}, new String[]
{"java.lang.String"});
   mbsc.setAttribute(webmodule, new Attribute("docBase", path));
   mbsc.setAttribute(webmodule, new Attribute("defaultWebXml", "web.xml"));
   mbsc.setAttribute(webmodule, new Attribute("engineName", DOMAIN));
   mbsc.setAttribute(webmodule, new Attribute("delegate", new
Boolean(true)));
   mbsc.invoke(webmodule, "init", new Object[] {}, new String[] {});
   //mbsc.invoke(webmodule, "start", new Object[] {}, new String[] {});
  } catch (Throwable e){
   throw new CoreException(new Status(IStatus.ERROR, TomcatPlugin.PLUGIN_ID,
IStatus.ERROR, "Cannot create the application context for "+context, e));
  }
 }

This code initialize, but does not starting the WebContext. When I force the
startup from JConsole it fails on NoClassDefFoundError. The class it fails
to find is in WEB-INF/lib directory.

I see that the classloader is initialized as well. But I'm not sure how to
assing it to Web App module.

Do I have to explicitly set loader atribute?

Thanks,
Alex.


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



[ANN] Apache Jakarta Tomcat 5.0.28 Released

2004-08-29 Thread Yoav Shapira
The Tomcat Team announces the immediate availability of Apache Jakarta Tomcat 
5.0.28.

Please refer to the change log for the list of changes:
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/changelog.html

Release notes:
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/RELEASE-NOTES

Downloads:
Binaries: http://jakarta.apache.org/site/binindex.cgi
Sources: http://jakarta.apache.org/site/sourceindex.cgi

Please note that the stability rating (alpha/beta/stable) for this release will
be announced separately in about a week.

The Apache Jakarta Tomcat Team



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



Catch Exception throw in useBean

2004-08-29 Thread Daron
Does anyone know how to catch an exception thrown by a constructor in
jsp:useBean ?
 
Regards,
Daron.

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.740 / Virus Database: 494 - Release Date: 16/08/2004
 


Re: Tomcat will not run JSPs

2004-08-29 Thread Michael McQuade
Sorry to bother you again Jacob.  But heres what I have found out,
first time into a program,  the database opens, updates and closes all with
a Status of  0 and 0...  Enter another program,and the database
opens with a Status of SqlCode = -1 and SqlState = 08002  (connection name
in Use). And then, any other attempt to access database results in -1
and 08000 thereafter.  By backing out to Tomcat manager,   stopping and
restarting the application,   seems to take care of the 08002,  but then it
reappears right after you do an initial open/close..  Is there anything
at all that you are aware of,  that Tomcat keeps a resource open?
On my close,  I do a  COMMIT  followed by DISCONNECT ALL..
Im so sorry for bothering you.

Mike

- Original Message - 
From: "Jacob Kjome" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Friday, August 27, 2004 12:46 PM
Subject: RE: Tomcat will not run JSPs


> Quoting "Nelson, Jerry W, Contractor 146CF, SCB"
<[EMAIL PROTECTED]>:
>
> > In the envorinment settings they are capitalized, it's just the way I
typed
> > the echo command.
> >
> > I also tried the %CATALINA_HOME% pointing to where you said, it didn't
work
> > either.
> >
> > Cheerfully waiting for more suggestions...
> >
> > And to Jake, Apache-Tomcat (Jakarta Project) version 5.0.27 (the one I'm
> > running) does run under a server service and it has an installer to set
> > everything up for you (supposedly)
> >
>
> And what I'm telling you is that:
>
> 1.  Don't bother with the installer.  I've never seen anything but trouble
with it.
>
> 2.  The installer doesn't do much more than what you can do more simply
with the
> zip file.  Just a couple extra manual steps that everyone should do anyway
> (setting up the system vars)
>
> 3.  The service that gets installed doesn't have tools.jar in the
classpath (at
> least with service.bat).  You'll have to add that before JSP's will be
compiled
> properly.  Please do what I recommended.  Start up Tomcat with the
startup.bat
> and see if it works.  If it does, then the problem is the service.  If you
> refuse to try this, then you won't be able to narrow down your issue.
>
> Sorry, but that's all the help I can provide.  If you ignore the advice
I've
> given you so far, you are on your own.
>
> Jake
>
>
> > //SIGNED//
> >
> > Jerry Nelson
> >
> >
> > -Original Message-
> > From: Dennis Dai [mailto:[EMAIL PROTECTED]
> > Sent: Thursday, August 26, 2004 10:10 PM
> > To: Tomcat Users List
> > Subject: Re: Tomcat will not run JSPs
> >
> >
> > Of course it will not work!
> >
> > First, I believe the environment variables need to be CAPITALIZED, as in
> > %JAVA_HOME% and %CATALINA_HOME%.
> >
> > Second, your %CATALINA_HOME% is pointing to the wrong place. It should
> > be the root of tomcat installation (ie., "D:\Program Files\Apache
> > Software Foundation\Tomcat 5.0"), not webapps\ROOT.
> >
> > On 8/26/2004 8:44 PM, Nelson, Jerry W, Contractor 146CF, SCB wrote:
> >
> > > That didn't work either and I have been researching this for a week,
some
> > > days as many as 10 hours.  I've probably spent an entire work week on
this
> > > problem and I am getting really frustrated.
> > >
> > > Here are my current envirnment settings:
> > >
> > > L:\>echo %java_home%
> > > C:\j2sdk1.4.2_05
> > >
> > > L:\>echo %catalina_home%
> > > D:\Program Files\Apache Software Foundation\Tomcat 5.0\webapps\ROOT
> > >
> > > It STILL doesn't work!
> > >
> > > //SIGNED//
> > >
> > > Jerry Nelson
> > >
> > >
> > > -Original Message-
> > > From: Dennis Dai [mailto:[EMAIL PROTECTED]
> > > Sent: Thursday, August 26, 2004 6:17 PM
> > > To: Tomcat Users List
> > > Subject: Re: Tomcat will not run JSPs
> > >
> > >
> > > You need to set %JAVA_HOME% to the installation directory of JDK, Not
> > > JRE. The JDK is installed in C:\j2sdk1.4.2_05 by default.
> > >
> > > I agree with Fredrik that you need to do some more home work by
yourself
> > > since this is fairly basic stuff.
> > >
> > > On 8/26/2004 6:01 PM, Nelson, Jerry W, Contractor 146CF, SCB wrote:
> > >
> > >> OK, I got the instructions and the homes are set as follows:
> > >>
> > >> L:\>echo %JAVA_HOME%
> > >> C:\Program Files\Java\j2re1.4.2_05\bin\client
> > >>
> > >> L:\>ECHO %CATALINA_HOME%
> > >> D:\Program Files\Apache Software Foundation\Tomcat 5.0
> > >>
> > >> Tomcat STILL can't find javac!!!  What's next
> > >>
> > >> //SIGNED//
> > >>
> > >> Jerry Nelson
> > >>
> > >>
> > >> -Original Message-
> > >> From: Fredrik Liden [mailto:[EMAIL PROTECTED]
> > >> Sent: Thursday, August 26, 2004 5:41 PM
> > >> To: Tomcat Users List
> > >> Subject: RE: Tomcat will not run JSPs
> > >>
> > >>
> > >> Go to google:
> > >>
> > >> Search for "setting java_home" click the first link in the result
link.
> > >> Follow step-by-step instructions.
> > >>
> > >> Once you get passed the step of setting the paths you'll no doubt
> > >> encounter tons of problems and questions. Make 

Re: Tomcat will not run JSPs

2004-08-29 Thread Michael McQuade
Hi, is this Jerry   Could I ask you a question,wondering if you are
having the same problem as I am.  Im using Tomcat for windows  The
Installer version..  I added my application,  went to the Comapny Logon
screen,which opens MySql database,   updates it, and closes it. All
successfully.  I then go to the User Login screen,which does the
same functions as above, open, update, closeand on my Open database,  I
get a  08002 (connection name in use). Any subsequent call gives an
08000.

By backing out to Tomcat manager,   stopping and restarting the application,
seems to take care of the 08002,  but then it reappears right after you do
an initial open/close..  Is there anything at all that you are aware of,
that Tomcat keeps a resource open?
On my close,  I do a  COMMIT  followed by DISCONNECT ALL..
Im so sorry for bothering you.

What problem were you experiencing?   By the way, Im running Servlets..
Do you have any idea what my problem may be,   Im totally new to this type
of programming,  and extremely frustrated,   cause my App works fine in CGI
format under a different Web Browser,  only problem is,   CGI is extremely
slow..  I need it to work in Servlets

Thank You
Mike




- Original Message - 
From: "Nelson, Jerry W, Contractor 146CF, SCB"
<[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <[EMAIL PROTECTED]>
Sent: Friday, August 27, 2004 11:34 AM
Subject: RE: Tomcat will not run JSPs


> THANK YOU TO ALL OF YOU THAT HELPED.
>
> I finally took Jakes sugestion.  I abandoned the Tomcat EXE and downloaded
> the zip file from Jakarta, unzipped it into the Tomcat directory and setup
> the environment as all of you had instructed and it FINALLY works,
although
> it would be nice if I could run the Tomcat service under windows so that
DOS
> window is not constantly in my task bar.
>
> Thank you again!
>
> //SIGNED//
>
> Jerry Nelson
>
>
> -Original Message-
> From: Jacob Kjome [mailto:[EMAIL PROTECTED]
> Sent: Thursday, August 26, 2004 9:48 PM
> To: Tomcat Users List
> Subject: RE: Tomcat will not run JSPs
>
>
> Ok, start over.  Uninstall Tomcat.  Grab the .zip file distribution and
> extract it to a directory *without spaces*.  Now, change the value of
> CATALINA_HOME to the new location of Tomcat.  Reboot.  The reboot is
> sometimes not necessary, but many times it is in order for your
environment
> variables to be recognized.  Just be safe and reboot.
>
> Now you are ready to run.  The question is, which way are you running
> it?  I suggest running using the startup.bat file.  You can create a
> shortcut to this on your desktop (same with shutdown.bat) to make things
> easier.  Since you seem to be a relative newbie to Tomcat (and possibly to
> programming???), I don't suggest trying to set up the windows service,
> especially since the service.bat currently doesn't include tools.jar in
the
> classpath and will cause JSP not to compile.  Why this hasn't been changed
> by the Tomcat developers is beyond me.  I've reported it many a time and
it
> is simply ignored.  Baffling!
>
> Anyway, you should be set to go.  Seriously, Tomcat is one of the simplest
> apps out there to set up.  If you are having trouble, you might want to
> take a class of some sort to get up to speed on some of this rather than
> banging your head against the wall for as long as you have been.
>
> Jake
>
> At 04:44 AM 8/27/2004 +0100, you wrote:
> >That didn't work either and I have been researching this for a week, some
> >days as many as 10 hours.  I've probably spent an entire work week on
this
> >problem and I am getting really frustrated.
> >
> >Here are my current envirnment settings:
> >
> >L:\>echo %java_home%
> >C:\j2sdk1.4.2_05
> >
> >L:\>echo %catalina_home%
> >D:\Program Files\Apache Software Foundation\Tomcat 5.0\webapps\ROOT
> >
> >It STILL doesn't work!
> >
> >//SIGNED//
> >
> >Jerry Nelson
> >
> >
> >-Original Message-
> >From: Dennis Dai [mailto:[EMAIL PROTECTED]
> >Sent: Thursday, August 26, 2004 6:17 PM
> >To: Tomcat Users List
> >Subject: Re: Tomcat will not run JSPs
> >
> >
> >You need to set %JAVA_HOME% to the installation directory of JDK, Not
> >JRE. The JDK is installed in C:\j2sdk1.4.2_05 by default.
> >
> >I agree with Fredrik that you need to do some more home work by yourself
> >since this is fairly basic stuff.
> >
> >On 8/26/2004 6:01 PM, Nelson, Jerry W, Contractor 146CF, SCB wrote:
> >
> > > OK, I got the instructions and the homes are set as follows:
> > >
> > > L:\>echo %JAVA_HOME%
> > > C:\Program Files\Java\j2re1.4.2_05\bin\client
> > >
> > > L:\>ECHO %CATALINA_HOME%
> > > D:\Program Files\Apache Software Foundation\Tomcat 5.0
> > >
> > > Tomcat STILL can't find javac!!!  What's next
> > >
> > > //SIGNED//
> > >
> > > Jerry Nelson
> > >
> > >
> > > -Original Message-
> > > From: Fredrik Liden [mailto:[EMAIL PROTECTED]
> > > Sent: Thursday, August 26, 2004 5:41 PM
> > > To: Tomcat Users List
> > 

Re: SecurityManager

2004-08-29 Thread Michael McQuade
Hi Benjamin,  Im sorry to bother you,  but Im desperate and you seem pretty
knowledgeable re Tomcat.  Im using the Windows Installer version
5.0.27..

Could I ask you a question,  I added my application thru the Application
Manager...  went to the Company Logon
screen,which opens MySql database,   updates it, and closes it. All
successfully.  I then go to the User Login screen,which does the
same functions as above, open, update, closeand on my Open database,  I
get a  08002 (connection name in use). Any subsequent call gives an
08000.

By backing out to Tomcat manager,   stopping and restarting the application,
seems to take care of the 08002,  but then it reappears right after you do
an initial open/close..  Is there anything at all that you are aware of,
that Tomcat keeps a resource open?
On my close,  I do a  COMMIT  followed by DISCONNECT ALL..
Im so sorry for bothering you.

By the way, Im running Servlets.. Do you have any idea what my problem
may be,   Im totally new to this type
of programming,  and extremely frustrated,   cause my App works fine in CGI
format under a different Web Browser,  only problem is,   CGI is extremely
slow..  I need it to work in Servlets

Thank You for any help you may be able to offer me...
Mike

- Original Message - 
From: "Benjamin Armintor" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Friday, August 27, 2004 11:06 AM
Subject: RE: SecurityManager


Where did you add the -security?  Did you move the catalina.policy file?


System.getSecurityManager() returning null is generally taken to mean
that the JVM is not running under the manager at all: this is obvious, I
know, but it also indicates the converse.  So if you start a security
manager up, the system's behavior will change.  In fact, I never
considered the trouble one could cause calling setSecurityManager at
runtime when there was no manager in effect (as opposed to trying to
override an existing policy, for which there's a permission check).

The AccessControlException means that after you started the manager,
some bit of code tried to get its ContextClassLoader, and it did not
have the appropriate runtime permissions.  Are the policy file entries
you indicated are all that is in your policy file?

Benjamin J. Armintor
Operations Systems Specialist
ITS-Systems: Mainframe Group
University of Texas - Austin
tele: (512) 232-6562
email: [EMAIL PROTECTED]



-Original Message-
From: Seaman, Sloan [mailto:[EMAIL PROTECTED]
Sent: Thursday, August 26, 2004 1:28 PM
To: '[EMAIL PROTECTED]'
Subject: SecurityManager


I'm trying to get an application I have to use the SecurityManager
object from Tomcat.

I've added the -security to my startup so that it is enabled.

When I do a System.getSecurityManager() it returns a null object.

If I try and create my own SecurityManager and set it via
System.setSecurityManager, I get: 004-08-26 14:07:47
StandardContext[/clinicalTrials]Exception starting filter SessionFilter
java.security.AccessControlException: access denied
(java.lang.RuntimePermission getClassLoader)
at
java.security.AccessControlContext.checkPermission(AccessControlContext.
java
:269)
at
java.security.AccessController.checkPermission(AccessController.java:401
)
at
java.lang.SecurityManager.checkPermission(SecurityManager.java:524)
at java.lang.Thread.getContextClassLoader(Thread.java:1182)
at
org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFi
lter
Config.java:207)
at
org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(Applicatio
nFil
terConfig.java:308)
at
org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilte
rCon
fig.java:79)

The only info I have added to the catalina.policy file is: grant {
permission javax.security.auth.AuthPermission "createLoginContext";
permission javax.security.auth.AuthPermission "doAs";
permission javax.security.auth.AuthPermission "doAsPrivileged";
permission javax.security.auth.AuthPermission "modifyPrincipals";
permission javax.security.auth.AuthPermission "getSubject";
};

grant principal
com.ptilabs.commons.jaas.authentication.ldap.LDAPPrincipal
"_app_Clinical_Trials" {
permission com.ptilabs.commons.jaas.authorization.URLPermission
"/clinicalTrials/app/*";
};

Can someone tell me what I am doing wrong?

I have a command line version for testing that works fine.  It is when I
try and do things under Tomcat that everything blows up.

Thanks!

--
Sloan

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


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



Re: Tomcat causes Apache to hang. Any ideas?

2004-08-29 Thread Sean Finkel
Shapira, Yoav wrote:
I already have. This exact same setup worked flawlessly under RH 7.3
   

and
 

RH 9.0
   

Actually, I meant a non-Linux platform.  But even your results so far
suggest an RHEL-specific issue.  Maybe try LD_ASSUME_KERNEL=2.2.5
instead of 2.4?  I remember people having success with that in the past.
 

You know what's funny? I stopped APF (the firewall) and it runs fine. I 
don't understand this. The needed ports were open (the shutdown, 
standalone and connector ports). I used the same firewall with the same 
ports open on the other servers/OSs and it worked fine. But I turn the 
firewall off and it stops hanging immediately.

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


Re: [ANN] Apache Jakarta Tomcat 5.0.28 Released

2004-08-29 Thread Vic
(I know I speak for many)
THANK YOU very much.
.V
Yoav Shapira wrote:
The Tomcat Team announces the immediate availability of Apache Jakarta Tomcat 
5.0.28.

Please refer to the change log for the list of changes:
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/changelog.html
Release notes:
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/RELEASE-NOTES
Downloads:
Binaries: http://jakarta.apache.org/site/binindex.cgi
Sources: http://jakarta.apache.org/site/sourceindex.cgi
Please note that the stability rating (alpha/beta/stable) for this release will
be announced separately in about a week.
The Apache Jakarta Tomcat Team

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


[OFFTOPIC] Re: [ANN] Apache Jakarta Tomcat 5.0.28 Released

2004-08-29 Thread John Villar
Thank you tomcat. taking the apache group as an example, i'm 
beginning to release my closed source Apps on open source. thanks 
everyone out there for helping me an my coworkers understand the open 
source theory

Vic escribió:
(I know I speak for many)
THANK YOU very much.
.V
Yoav Shapira wrote:
The Tomcat Team announces the immediate availability of Apache 
Jakarta Tomcat 5.0.28.

Please refer to the change log for the list of changes:
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/changelog.html
Release notes:
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/RELEASE-NOTES
Downloads:
Binaries: http://jakarta.apache.org/site/binindex.cgi
Sources: http://jakarta.apache.org/site/sourceindex.cgi
Please note that the stability rating (alpha/beta/stable) for this 
release will
be announced separately in about a week.

The Apache Jakarta Tomcat Team

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

--
John Villar
Gerente de Proyectos
Computadores Flor Hard Soft 2058 C.A.
www.florhard.com

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

DataSource Question

2004-08-29 Thread Jack Lauman
I'm using the following code in a servlet to get a JDBC connection:
Context ctx = new InitialContext();
DataSource ds = (DataSource) ctx.lookup("java:comp/env/jdbc/DBNameDS");
Connection conn = ds.getConnection();
It works fine... but I would like to be able to substitute "DBNameDS"
with the actual name of the ds as defined in the web.xml file.
How can this be done?
Jack

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


Re: Tomcat will not run JSPs

2004-08-29 Thread Jacob Kjome
sounds to me like you aren't using connection pooling.  Rather, you are 
opening a connection each time, but not fully closing the 
connection.  Additionally, your database is probably set to only support 1 
connection for this particular user at a time.  You might want to check 
into allowing more connections and using connection pooling so that they 
stay open constantly so it isn't so expensive to use them.

Jake
At 12:00 PM 8/29/2004 -0400, you wrote:
Sorry to bother you again Jacob.  But heres what I have found out,
first time into a program,  the database opens, updates and closes all with
a Status of  0 and 0...  Enter another program,and the database
opens with a Status of SqlCode = -1 and SqlState = 08002  (connection name
in Use). And then, any other attempt to access database results in -1
and 08000 thereafter.  By backing out to Tomcat manager,   stopping and
restarting the application,   seems to take care of the 08002,  but then it
reappears right after you do an initial open/close..  Is there anything
at all that you are aware of,  that Tomcat keeps a resource open?
On my close,  I do a  COMMIT  followed by DISCONNECT ALL..
Im so sorry for bothering you.
Mike
- Original Message -
From: "Jacob Kjome" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Friday, August 27, 2004 12:46 PM
Subject: RE: Tomcat will not run JSPs
> Quoting "Nelson, Jerry W, Contractor 146CF, SCB"
<[EMAIL PROTECTED]>:
>
> > In the envorinment settings they are capitalized, it's just the way I
typed
> > the echo command.
> >
> > I also tried the %CATALINA_HOME% pointing to where you said, it didn't
work
> > either.
> >
> > Cheerfully waiting for more suggestions...
> >
> > And to Jake, Apache-Tomcat (Jakarta Project) version 5.0.27 (the one I'm
> > running) does run under a server service and it has an installer to set
> > everything up for you (supposedly)
> >
>
> And what I'm telling you is that:
>
> 1.  Don't bother with the installer.  I've never seen anything but trouble
with it.
>
> 2.  The installer doesn't do much more than what you can do more simply
with the
> zip file.  Just a couple extra manual steps that everyone should do anyway
> (setting up the system vars)
>
> 3.  The service that gets installed doesn't have tools.jar in the
classpath (at
> least with service.bat).  You'll have to add that before JSP's will be
compiled
> properly.  Please do what I recommended.  Start up Tomcat with the
startup.bat
> and see if it works.  If it does, then the problem is the service.  If you
> refuse to try this, then you won't be able to narrow down your issue.
>
> Sorry, but that's all the help I can provide.  If you ignore the advice
I've
> given you so far, you are on your own.
>
> Jake
>
>
> > //SIGNED//
> >
> > Jerry Nelson
> >
> >
> > -Original Message-
> > From: Dennis Dai [mailto:[EMAIL PROTECTED]
> > Sent: Thursday, August 26, 2004 10:10 PM
> > To: Tomcat Users List
> > Subject: Re: Tomcat will not run JSPs
> >
> >
> > Of course it will not work!
> >
> > First, I believe the environment variables need to be CAPITALIZED, as in
> > %JAVA_HOME% and %CATALINA_HOME%.
> >
> > Second, your %CATALINA_HOME% is pointing to the wrong place. It should
> > be the root of tomcat installation (ie., "D:\Program Files\Apache
> > Software Foundation\Tomcat 5.0"), not webapps\ROOT.
> >
> > On 8/26/2004 8:44 PM, Nelson, Jerry W, Contractor 146CF, SCB wrote:
> >
> > > That didn't work either and I have been researching this for a week,
some
> > > days as many as 10 hours.  I've probably spent an entire work week on
this
> > > problem and I am getting really frustrated.
> > >
> > > Here are my current envirnment settings:
> > >
> > > L:\>echo %java_home%
> > > C:\j2sdk1.4.2_05
> > >
> > > L:\>echo %catalina_home%
> > > D:\Program Files\Apache Software Foundation\Tomcat 5.0\webapps\ROOT
> > >
> > > It STILL doesn't work!
> > >
> > > //SIGNED//
> > >
> > > Jerry Nelson
> > >
> > >
> > > -Original Message-
> > > From: Dennis Dai [mailto:[EMAIL PROTECTED]
> > > Sent: Thursday, August 26, 2004 6:17 PM
> > > To: Tomcat Users List
> > > Subject: Re: Tomcat will not run JSPs
> > >
> > >
> > > You need to set %JAVA_HOME% to the installation directory of JDK, Not
> > > JRE. The JDK is installed in C:\j2sdk1.4.2_05 by default.
> > >
> > > I agree with Fredrik that you need to do some more home work by
yourself
> > > since this is fairly basic stuff.
> > >
> > > On 8/26/2004 6:01 PM, Nelson, Jerry W, Contractor 146CF, SCB wrote:
> > >
> > >> OK, I got the instructions and the homes are set as follows:
> > >>
> > >> L:\>echo %JAVA_HOME%
> > >> C:\Program Files\Java\j2re1.4.2_05\bin\client
> > >>
> > >> L:\>ECHO %CATALINA_HOME%
> > >> D:\Program Files\Apache Software Foundation\Tomcat 5.0
> > >>
> > >> Tomcat STILL can't find javac!!!  What's next
> > >>
> > >> //SIGNED//
> > >>
> > >> Jerry Nelson
> > >>
> > >>
> > >> -Original Message-
> > >> From: Fr

Re: SecurityManager

2004-08-29 Thread Jacob Kjome
Mike,
You do not need to post your question specifically to 3 different 
people.  It's all on one list, just ask one question.  Not only that, but 
you seem to have hijacked two threads in the process.  Create a new thread 
for a new question.  Does a post about JSP's or a post about the Tomcat 
SecurityManager sound anything like they have to do with databases?  I 
don't think so, and it ought to be obvious even to the most newbie or 
newbies.  You ought to know that you risk being ignored if you continue 
this behavior on the list.  Yes, we all understand you have a problem that 
needs solving, but you are less, not more, likely to get an answer with 
this line of questioning.

Jake
At 12:23 PM 8/29/2004 -0400, you wrote:
Hi Benjamin,  Im sorry to bother you,  but Im desperate and you seem pretty
knowledgeable re Tomcat.  Im using the Windows Installer version
5.0.27..
Could I ask you a question,  I added my application thru the Application
Manager...  went to the Company Logon
screen,which opens MySql database,   updates it, and closes it. All
successfully.  I then go to the User Login screen,which does the
same functions as above, open, update, closeand on my Open database,  I
get a  08002 (connection name in use). Any subsequent call gives an
08000.
By backing out to Tomcat manager,   stopping and restarting the application,
seems to take care of the 08002,  but then it reappears right after you do
an initial open/close..  Is there anything at all that you are aware of,
that Tomcat keeps a resource open?
On my close,  I do a  COMMIT  followed by DISCONNECT ALL..
Im so sorry for bothering you.
By the way, Im running Servlets.. Do you have any idea what my problem
may be,   Im totally new to this type
of programming,  and extremely frustrated,   cause my App works fine in CGI
format under a different Web Browser,  only problem is,   CGI is extremely
slow..  I need it to work in Servlets
Thank You for any help you may be able to offer me...
Mike
- Original Message -
From: "Benjamin Armintor" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Friday, August 27, 2004 11:06 AM
Subject: RE: SecurityManager
Where did you add the -security?  Did you move the catalina.policy file?
System.getSecurityManager() returning null is generally taken to mean
that the JVM is not running under the manager at all: this is obvious, I
know, but it also indicates the converse.  So if you start a security
manager up, the system's behavior will change.  In fact, I never
considered the trouble one could cause calling setSecurityManager at
runtime when there was no manager in effect (as opposed to trying to
override an existing policy, for which there's a permission check).
The AccessControlException means that after you started the manager,
some bit of code tried to get its ContextClassLoader, and it did not
have the appropriate runtime permissions.  Are the policy file entries
you indicated are all that is in your policy file?
Benjamin J. Armintor
Operations Systems Specialist
ITS-Systems: Mainframe Group
University of Texas - Austin
tele: (512) 232-6562
email: [EMAIL PROTECTED]

-Original Message-
From: Seaman, Sloan [mailto:[EMAIL PROTECTED]
Sent: Thursday, August 26, 2004 1:28 PM
To: '[EMAIL PROTECTED]'
Subject: SecurityManager
I'm trying to get an application I have to use the SecurityManager
object from Tomcat.
I've added the -security to my startup so that it is enabled.
When I do a System.getSecurityManager() it returns a null object.
If I try and create my own SecurityManager and set it via
System.setSecurityManager, I get: 004-08-26 14:07:47
StandardContext[/clinicalTrials]Exception starting filter SessionFilter
java.security.AccessControlException: access denied
(java.lang.RuntimePermission getClassLoader)
at
java.security.AccessControlContext.checkPermission(AccessControlContext.
java
:269)
at
java.security.AccessController.checkPermission(AccessController.java:401
)
at
java.lang.SecurityManager.checkPermission(SecurityManager.java:524)
at java.lang.Thread.getContextClassLoader(Thread.java:1182)
at
org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFi
lter
Config.java:207)
at
org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(Applicatio
nFil
terConfig.java:308)
at
org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilte
rCon
fig.java:79)
The only info I have added to the catalina.policy file is: grant {
permission javax.security.auth.AuthPermission "createLoginContext";
permission javax.security.auth.AuthPermission "doAs";
permission javax.security.auth.AuthPermission "doAsPrivileged";
permission javax.security.auth.AuthPermission "modifyPrincipals";
permission javax.security.auth.AuthPermission "getSubject";
};
grant principal
com.ptilabs.commons.jaas.authentication.ldap.LDAPPrincipal
"_app_Clinical_Trials" {
permission com.ptilabs.commons.jaas.authorization.U

Re: SecurityManager

2004-08-29 Thread Michael McQuade
So sorry,   didnt realize it showed up all over the place,  thought I was
just asking you a question...

- Original Message - 
From: "Jacob Kjome" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Sunday, August 29, 2004 6:12 PM
Subject: Re: SecurityManager


> Mike,
>
> You do not need to post your question specifically to 3 different
> people.  It's all on one list, just ask one question.  Not only that, but
> you seem to have hijacked two threads in the process.  Create a new thread
> for a new question.  Does a post about JSP's or a post about the Tomcat
> SecurityManager sound anything like they have to do with databases?  I
> don't think so, and it ought to be obvious even to the most newbie or
> newbies.  You ought to know that you risk being ignored if you continue
> this behavior on the list.  Yes, we all understand you have a problem that
> needs solving, but you are less, not more, likely to get an answer with
> this line of questioning.
>
> Jake
>
> At 12:23 PM 8/29/2004 -0400, you wrote:
> >Hi Benjamin,  Im sorry to bother you,  but Im desperate and you seem
pretty
> >knowledgeable re Tomcat.  Im using the Windows Installer version
> >5.0.27..
> >
> >Could I ask you a question,  I added my application thru the Application
> >Manager...  went to the Company Logon
> >screen,which opens MySql database,   updates it, and closes it.
All
> >successfully.  I then go to the User Login screen,which does the
> >same functions as above, open, update, closeand on my Open database,
I
> >get a  08002 (connection name in use). Any subsequent call gives an
> >08000.
> >
> >By backing out to Tomcat manager,   stopping and restarting the
application,
> >seems to take care of the 08002,  but then it reappears right after you
do
> >an initial open/close..  Is there anything at all that you are aware
of,
> >that Tomcat keeps a resource open?
> >On my close,  I do a  COMMIT  followed by DISCONNECT ALL..
> >Im so sorry for bothering you.
> >
> >By the way, Im running Servlets.. Do you have any idea what my
problem
> >may be,   Im totally new to this type
> >of programming,  and extremely frustrated,   cause my App works fine in
CGI
> >format under a different Web Browser,  only problem is,   CGI is
extremely
> >slow..  I need it to work in Servlets
> >
> >Thank You for any help you may be able to offer me...
> >Mike
> >
> >- Original Message -
> >From: "Benjamin Armintor" <[EMAIL PROTECTED]>
> >To: "Tomcat Users List" <[EMAIL PROTECTED]>
> >Sent: Friday, August 27, 2004 11:06 AM
> >Subject: RE: SecurityManager
> >
> >
> >Where did you add the -security?  Did you move the catalina.policy file?
> >
> >
> >System.getSecurityManager() returning null is generally taken to mean
> >that the JVM is not running under the manager at all: this is obvious, I
> >know, but it also indicates the converse.  So if you start a security
> >manager up, the system's behavior will change.  In fact, I never
> >considered the trouble one could cause calling setSecurityManager at
> >runtime when there was no manager in effect (as opposed to trying to
> >override an existing policy, for which there's a permission check).
> >
> >The AccessControlException means that after you started the manager,
> >some bit of code tried to get its ContextClassLoader, and it did not
> >have the appropriate runtime permissions.  Are the policy file entries
> >you indicated are all that is in your policy file?
> >
> >Benjamin J. Armintor
> >Operations Systems Specialist
> >ITS-Systems: Mainframe Group
> >University of Texas - Austin
> >tele: (512) 232-6562
> >email: [EMAIL PROTECTED]
> >
> >
> >
> >-Original Message-
> >From: Seaman, Sloan [mailto:[EMAIL PROTECTED]
> >Sent: Thursday, August 26, 2004 1:28 PM
> >To: '[EMAIL PROTECTED]'
> >Subject: SecurityManager
> >
> >
> >I'm trying to get an application I have to use the SecurityManager
> >object from Tomcat.
> >
> >I've added the -security to my startup so that it is enabled.
> >
> >When I do a System.getSecurityManager() it returns a null object.
> >
> >If I try and create my own SecurityManager and set it via
> >System.setSecurityManager, I get: 004-08-26 14:07:47
> >StandardContext[/clinicalTrials]Exception starting filter SessionFilter
> >java.security.AccessControlException: access denied
> >(java.lang.RuntimePermission getClassLoader)
> >at
> >java.security.AccessControlContext.checkPermission(AccessControlContext.
> >java
> >:269)
> >at
> >java.security.AccessController.checkPermission(AccessController.java:401
> >)
> >at
> >java.lang.SecurityManager.checkPermission(SecurityManager.java:524)
> >at java.lang.Thread.getContextClassLoader(Thread.java:1182)
> >at
> >org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFi
> >lter
> >Config.java:207)
> >at
> >org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(Applicatio
> >nFil
> >terConfig.java:308)
> >at
> >org.apache

Re: DataSource Question

2004-08-29 Thread Big Chiz
there can be two things to change: if ur using tc5 you can change your
dbcp resource via yourcustomapp.xml (conf/catalina/localhost/)

  
  


and then in your web.xml

javax.servlet.jsp.jstl.sql.dataSource
jdbc/yourcustomname
 

On Sun, 29 Aug 2004 14:29:22 -0700, Jack Lauman <[EMAIL PROTECTED]> wrote:
> I'm using the following code in a servlet to get a JDBC connection:
> 
> Context ctx = new InitialContext();
> DataSource ds = (DataSource) ctx.lookup("java:comp/env/jdbc/DBNameDS");
> Connection conn = ds.getConnection();
> 
> It works fine... but I would like to be able to substitute "DBNameDS"
> with the actual name of the ds as defined in the web.xml file.
> 
> How can this be done?
> 
> Jack
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
>

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



tomcat 5.0.27 xml schema or DTD for server.xml

2004-08-29 Thread Luke (Terry) Vanderfluit
Hi,

I am running tomcat 5.0.27. 
I'm looking for a copy of the xml schema for the server.xml file.
I've looked on the jakarta website and in the 2.4 servlet spec, but
can't find it, 
Maybe there's only a DTD at this stage,

Anyone know where to find it?

TIA,
Luke

-- 

Luke (Terry) Vanderfluit 
Mobile: 0421 276 282 



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



RE: tomcat 5.0.27 xml schema or DTD for server.xml

2004-08-29 Thread Benjamin Armintor
You wouldn't find it in the servlet spec, because it's specific to Tomcat.

Check the archives, but as I recall, there's no published grammar for the server.xml: 
It's parsed in non-validating mode by the Digester.  A DTD wouldn't work because the 
attributes for an element are arbitrary (to accomodate user implementations of the 
Catalina interfaces).  I appreciate the idea: I wrote a schema for the 4.1.x 
server.xml when I wanted one to validate against, but it was kind of a bear.  What are 
you trying to do? 

-- Benjamin Armintor 


-Original Message-
From: Luke (Terry) Vanderfluit [mailto:[EMAIL PROTECTED]
Sent: Sun 8/29/2004 10:53 PM
To: [EMAIL PROTECTED]
Subject: tomcat 5.0.27 xml schema or DTD for server.xml
 
Hi,

I am running tomcat 5.0.27. 
I'm looking for a copy of the xml schema for the server.xml file.
I've looked on the jakarta website and in the 2.4 servlet spec, but
can't find it, 
Maybe there's only a DTD at this stage,

Anyone know where to find it?

TIA,
Luke

-- 

Luke (Terry) Vanderfluit 
Mobile: 0421 276 282 



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





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

Re: tomcat 5.0.27 xml schema or DTD for server.xml

2004-08-29 Thread Paul Gregoire
This should point you in the right direction..

Luke (Terry) Vanderfluit wrote:
Hi,
I am running tomcat 5.0.27. 
I'm looking for a copy of the xml schema for the server.xml file.
I've looked on the jakarta website and in the 2.4 servlet spec, but
can't find it, 
Maybe there's only a DTD at this stage,

Anyone know where to find it?
TIA,
Luke
 


--
(¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯)
The early bird gets the worm, but the second mouse gets the cheese...
ICQ 1202948
(¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯`·.¸¸.·´¯)

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


RE: tomcat 5.0.27 xml schema or DTD for server.xml

2004-08-29 Thread Luke (Terry) Vanderfluit
Hi, 
Actually my intentions are modest. I want to validate whether the tags
in server.xml are properly nested. I've had difficulty with this in
web.xml before (when setting url-mappings). That's besides the general
goal of improving my understanding of tomcat's configuration &
terminlogy.
L.


On Mon, 2004-08-30 at 13:39, Benjamin Armintor wrote:
> You wouldn't find it in the servlet spec, because it's specific to Tomcat.
> 
> Check the archives, but as I recall, there's no published grammar for the 
> server.xml: It's parsed in non-validating mode by the Digester.  A DTD wouldn't work 
> because the attributes for an element are arbitrary (to accomodate user 
> implementations of the Catalina interfaces).  I appreciate the idea: I wrote a 
> schema for the 4.1.x server.xml when I wanted one to validate against, but it was 
> kind of a bear.  What are you trying to do? 
> 
> -- Benjamin Armintor 
> 
> 
> -Original Message-
> From: Luke (Terry) Vanderfluit [mailto:[EMAIL PROTECTED]
> Sent: Sun 8/29/2004 10:53 PM
> To: [EMAIL PROTECTED]
> Subject: tomcat 5.0.27 xml schema or DTD for server.xml
>  
> Hi,
> 
> I am running tomcat 5.0.27. 
> I'm looking for a copy of the xml schema for the server.xml file.
> I've looked on the jakarta website and in the 2.4 servlet spec, but
> can't find it, 
> Maybe there's only a DTD at this stage,
> 
> Anyone know where to find it?
> 
> TIA,
> Luke
-- 

Luke (Terry) Vanderfluit 
Mobile: 0421 276 282 



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



save generated from xslt data in file

2004-08-29 Thread Eugene
How possible to store the HTML generated from XSLT by
servlet in html file located on the server?

Thanks in advance.
 Eugene


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



Re: save generated from xslt data in file

2004-08-29 Thread Lyndon Samson
No sorry, this sort of thing is way beyond the power of the JVM... ;-)



On Mon, 30 Aug 2004 01:05:10 -0300, Eugene
<[EMAIL PROTECTED]> wrote:
> How possible to store the HTML generated from XSLT by
> servlet in html file located on the server?
> 
> Thanks in advance.
>  Eugene
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
>

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



404 response form authentication problem

2004-08-29 Thread Jon Wilmoth
I have a login form that works fine in my local
development environment with a single webapp deployed
to the default localhost "host".  However, in a hosted
environment with multiple "host"s defined in my
server.xml Tomcat returns a 404 response and a blank
page.  The html form follows the servlet spec
definition, the application deploys successfully in
(confirmed via log files), and I'm successfully
redirected to my login page when trying to access a
protected resource.  I have cookies enabled in my
browser and I see that a call to
request.isRequestedSessionIdFromCookie() = true in my
log files.  If I change the web.xml's 
element from FORM to BASIC, I get challenged for a
login and then successfully redirected.  I'm at a loss
for why this isn't working any help/thoughts are
greatly appreciated!







I've defined a host in the server.xml that uses a
sub-domain.  I also have another host running on the
same Tomcat instance




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



Re: How to specify min/max memory on Tomcat 3.3?

2004-08-29 Thread Bill Barker
Using the standard scripts, you would pass the options via the TOMCAT_OPTS
environment variable.  The actual options depends on the JVM vendor, but for
the Sun JVM you would do something like:
  TOMCAT_OPTS="-Xms128M -Xmx512M"

Tomcat just uses the default values for the JVM.

"nyhgan" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
>
> Hi,
>
> Is there anyway to specify the minimum and maximum memory on Tomcat 3.3?
What is the default maximum memory? Thanks!
>
>
> nyhgan.
>
>
>
>
>
> -
> Do you Yahoo!?
> Take Yahoo! Mail with you! Get it on your mobile phone.




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



Context

2004-08-29 Thread Mario Moroni
Hi all,

I put some name-value properties in the context putting them in the web.xml
in this way:

 
companyName
My Company, Incorporated
 

Is this right?

Now I need to read them from within my classes... How can I do?

Is there someone who have a sample java code to give me?

Thanks.

 Mario

 

 

 --

 Email.it, the professional e-mail, gratis per te: http://www.email.it/f

 

 Sponsor:

 Stanco di avere la casella piena? Risolvi i tuoi problemi di spazio con Email.it 
PRO100 avrai 100 MB di per spedire e ricevere ciò che vuoi

 Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid=1626&d=30-8

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