javax.naming.ServiceUnavailableException: directory.mycompany.com:389; socket closed; remaining name '' at org.acegisecurity.ldap.LdapTemplate$LdapExceptionTranslator.translate(LdapTemplate.java:295)

Jenkins JIRA | jonathan_w_brown | 9 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    [JENKINS-2489] ldap authentication problem in tomcat - Jenkins JIRA

    jenkins-ci.org | 10 months ago
    javax.naming.ServiceUnavailableException: directory.mycompany.com:389; socket closed; remaining name '' at org.acegisecurity.ldap.LdapTemplate$LdapExceptionTranslator.translate(LdapTemplate.java:295)
  2. 0

    I have Hudson 1.255 running in tomcat 6.0. Security is enabled in Hudson using Hudson's integrated LDAP authentication feature. Everything works fine for awhile and as long as I am active on the site. However, if I close the browser (firefox 3.0.3) and subsequently attempt to access the site after several hours of inactivity I consistently run into the following problem: Oct 17, 2008 10:46:03 PM hudson.security.LDAPSecurityRealm$1 loadUserByUsername WARNING: Failed to search LDAP for username=someuser org.acegisecurity.ldap.LdapDataAccessException: LdapCallback;directory.mycompany.com:389; socket closed; nested exception is javax.naming.ServiceUnavailableException: directory.mycompany.com:389; socket closed; remaining name '' at org.acegisecurity.ldap.LdapTemplate$LdapExceptionTranslator.translate(LdapTemplate.java:295) at org.acegisecurity.ldap.LdapTemplate.execute(LdapTemplate.java:128) at org.acegisecurity.ldap.LdapTemplate.searchForSingleEntry(LdapTemplate.java:246) at org.acegisecurity.ldap.search.FilterBasedLdapUserSearch.searchForUser(FilterBasedLdapUserSearch.java:119) at hudson.security.LDAPSecurityRealm$1.loadUserByUsername(LDAPSecurityRealm.java:187) at hudson.security.UserDetailsServiceProxy.loadUserByUsername(UserDetailsServiceProxy.java:21) at org.acegisecurity.ui.rememberme.TokenBasedRememberMeServices.loadUserDetails(TokenBasedRememberMeServices.java:308) at org.acegisecurity.ui.rememberme.TokenBasedRememberMeServices.autoLogin(TokenBasedRememberMeServices.java:218) at hudson.security.RememberMeServicesProxy.autoLogin(RememberMeServicesProxy.java:30) at org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:104) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:55) at org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:271) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:55) at org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:173) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:55) at org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:249) at hudson.security.HttpSessionContextIntegrationFilter2.doFilter(HttpSessionContextIntegrationFilter2.java:42) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:55) at hudson.security.ChainedServletFilter.doFilter(ChainedServletFilter.java:44) at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:85) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.authenticator.SingleSignOn.invoke(SingleSignOn.java:394) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:283) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:767) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:697) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:889) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:595) Caused by: javax.naming.ServiceUnavailableException: directory.mycompany.com:389; socket closed; remaining name '' at com.sun.jndi.ldap.Connection.readReply(Connection.java:410) at com.sun.jndi.ldap.LdapClient.getSearchReply(LdapClient.java:611) at com.sun.jndi.ldap.LdapClient.search(LdapClient.java:534) at com.sun.jndi.ldap.LdapCtx.doSearch(LdapCtx.java:1944) at com.sun.jndi.ldap.LdapCtx.searchAux(LdapCtx.java:1806) at com.sun.jndi.ldap.LdapCtx.c_search(LdapCtx.java:1731) at com.sun.jndi.ldap.LdapCtx.c_search(LdapCtx.java:1748) at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_search(ComponentDirContext.java:394) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.search(PartialCompositeDirContext.java:376) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.search(PartialCompositeDirContext.java:358) at javax.naming.directory.InitialDirContext.search(InitialDirContext.java:267) at org.acegisecurity.ldap.LdapTemplate$3.doInDirContext(LdapTemplate.java:249) at org.acegisecurity.ldap.LdapTemplate.execute(LdapTemplate.java:126) ... 35 more Any suggestions? Is there a place where I can configure this problem away?

    Jenkins JIRA | 9 years ago | jonathan_w_brown
    javax.naming.ServiceUnavailableException: directory.mycompany.com:389; socket closed; remaining name '' at org.acegisecurity.ldap.LdapTemplate$LdapExceptionTranslator.translate(LdapTemplate.java:295)
  3. 0

    I have Hudson 1.255 running in tomcat 6.0. Security is enabled in Hudson using Hudson's integrated LDAP authentication feature. Everything works fine for awhile and as long as I am active on the site. However, if I close the browser (firefox 3.0.3) and subsequently attempt to access the site after several hours of inactivity I consistently run into the following problem: Oct 17, 2008 10:46:03 PM hudson.security.LDAPSecurityRealm$1 loadUserByUsername WARNING: Failed to search LDAP for username=someuser org.acegisecurity.ldap.LdapDataAccessException: LdapCallback;directory.mycompany.com:389; socket closed; nested exception is javax.naming.ServiceUnavailableException: directory.mycompany.com:389; socket closed; remaining name '' at org.acegisecurity.ldap.LdapTemplate$LdapExceptionTranslator.translate(LdapTemplate.java:295) at org.acegisecurity.ldap.LdapTemplate.execute(LdapTemplate.java:128) at org.acegisecurity.ldap.LdapTemplate.searchForSingleEntry(LdapTemplate.java:246) at org.acegisecurity.ldap.search.FilterBasedLdapUserSearch.searchForUser(FilterBasedLdapUserSearch.java:119) at hudson.security.LDAPSecurityRealm$1.loadUserByUsername(LDAPSecurityRealm.java:187) at hudson.security.UserDetailsServiceProxy.loadUserByUsername(UserDetailsServiceProxy.java:21) at org.acegisecurity.ui.rememberme.TokenBasedRememberMeServices.loadUserDetails(TokenBasedRememberMeServices.java:308) at org.acegisecurity.ui.rememberme.TokenBasedRememberMeServices.autoLogin(TokenBasedRememberMeServices.java:218) at hudson.security.RememberMeServicesProxy.autoLogin(RememberMeServicesProxy.java:30) at org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:104) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:55) at org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:271) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:55) at org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:173) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:55) at org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:249) at hudson.security.HttpSessionContextIntegrationFilter2.doFilter(HttpSessionContextIntegrationFilter2.java:42) at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:55) at hudson.security.ChainedServletFilter.doFilter(ChainedServletFilter.java:44) at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:85) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.authenticator.SingleSignOn.invoke(SingleSignOn.java:394) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:283) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:767) at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:697) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:889) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690) at java.lang.Thread.run(Thread.java:595) Caused by: javax.naming.ServiceUnavailableException: directory.mycompany.com:389; socket closed; remaining name '' at com.sun.jndi.ldap.Connection.readReply(Connection.java:410) at com.sun.jndi.ldap.LdapClient.getSearchReply(LdapClient.java:611) at com.sun.jndi.ldap.LdapClient.search(LdapClient.java:534) at com.sun.jndi.ldap.LdapCtx.doSearch(LdapCtx.java:1944) at com.sun.jndi.ldap.LdapCtx.searchAux(LdapCtx.java:1806) at com.sun.jndi.ldap.LdapCtx.c_search(LdapCtx.java:1731) at com.sun.jndi.ldap.LdapCtx.c_search(LdapCtx.java:1748) at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_search(ComponentDirContext.java:394) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.search(PartialCompositeDirContext.java:376) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.search(PartialCompositeDirContext.java:358) at javax.naming.directory.InitialDirContext.search(InitialDirContext.java:267) at org.acegisecurity.ldap.LdapTemplate$3.doInDirContext(LdapTemplate.java:249) at org.acegisecurity.ldap.LdapTemplate.execute(LdapTemplate.java:126) ... 35 more Any suggestions? Is there a place where I can configure this problem away?

    Jenkins JIRA | 9 years ago | jonathan_w_brown
    javax.naming.ServiceUnavailableException: directory.mycompany.com:389; socket closed; remaining name '' at org.acegisecurity.ldap.LdapTemplate$LdapExceptionTranslator.translate(LdapTemplate.java:295)
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Jenkins issues - [Issue 2489] New - ldap authentication problem in tomcat

    nabble.com | 2 years ago
    javax.naming.ServiceUnavailableException: directory.mycompany.com:389; socket closed; remaining name '' at org.acegisecurity.ldap.LdapTemplate$LdapExceptionTranslator.translate(LdapTemplate.java:295)

    Root Cause Analysis

    1. javax.naming.ServiceUnavailableException

      directory.mycompany.com:389; socket closed; remaining name '' at org.acegisecurity.ldap.LdapTemplate$LdapExceptionTranslator.translate(LdapTemplate.java:295)

      at org.acegisecurity.ldap.LdapTemplate.execute()
    2. Acegi Security Core
      LdapTemplate.searchForSingleEntry
      1. org.acegisecurity.ldap.LdapTemplate.execute(LdapTemplate.java:128)
      2. org.acegisecurity.ldap.LdapTemplate.searchForSingleEntry(LdapTemplate.java:246)
      2 frames