You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Kumar Gaurav Srivastava <ga...@sathone.com> on 2008/06/19 12:49:51 UTC

JNDI realm strange problem(Tomcat 6.0.16)

hello ,

i will be really grateful if someone can help me on this. 

i have my realm configuration in server.xml, every thing is fine i can
login. but when i try to login the next morning it gives error 

SEVERE: Exception performing authentication
javax.naming.NoInitialContextException: Need to specify class name in
environment or system property, or as an applet parameter, or in an
application resource file: java.naming.factory.initial at
javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:645)

first i thought the cause of error is "JNDIRealm fails when server
disconnects after time". Then I looked at the jndirealm code from apache
there i found out "on connection close it reconnects". 

i am very puzzled by this situation, it finds the ldap initial context
first time,but not second time.



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


Re: JNDI realm strange problem(Tomcat 6.0.16)

Posted by Kumar Gaurav Srivastava <ga...@sathone.com>.
hello chris, 

	yes, our ldap server and tomcat server are both up for 24 hours  and 7
days.

yes, restarting tomcat server, problem vanishes. 

thank you, 
 
On Fri, 2008-06-20 at 10:20 -0400, Christopher Schultz wrote:
> king again?
-- 
Kumar Gaurav Srivastava
A B Technologies
SDF Building, Mudule 417
Sector - V, SaltLake
Kolkata, 700 091, India
Phone: +91.33.2357.7172


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


Re: JNDI realm strange problem(Tomcat 6.0.16)

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Kuman,

Kumar Gaurav Srivastava wrote:
| i have my realm configuration in server.xml, every thing is fine i can
| login. but when i try to login the next morning it gives error
|
| SEVERE: Exception performing authentication
| javax.naming.NoInitialContextException: Need to specify class name in
| environment or system property, or as an applet parameter, or in an
| application resource file: java.naming.factory.initial at
| javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:645)

Hmm... are you sure your server is staying up all night, or does it get
restarted or anything like that? NoInitialContextException is very strange.

If you restart Tomcat, does it start working again?

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkhbvLQACgkQ9CaO5/Lv0PCAtQCgmlDIAYefCW33BAi1Y2lEzWKM
WacAnirMgdFZVpfg2aOJM4Y+va4+fDMZ
=D+S0
-----END PGP SIGNATURE-----

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