Pages

Wednesday, June 13, 2012

oracle.iam.platform.utils.NoSuchServiceException

Problem:



The Oracle Identity Manager throws Exception oracle.iam.platform.utils.NoSuchServiceException while deploying the Oracle Identity Manager Plugin.


[java] oracle.iam.platform.utils.NoSuchServiceException: java.lang.reflect.InvocationTargetException
[java] at oracle.iam.platform.OIMClient.getServiceDelegate(OIMClient.java:197)
[java] at oracle.iam.platform.OIMClient.getService(OIMClient.java:174)
[java] at oracle.iam.platform.OIMClient.loginSessionCreated(OIMClient.java:209)
[java] at oracle.iam.platform.OIMClient.login(OIMClient.java:136)
[java] at oracle.iam.platform.OIMClient.login(OIMClient.java:114)
[java] at oracle.iam.platformservice.utils.PluginUtility.main(PluginUtility.java:125)
[java] Caused by: java.lang.reflect.InvocationTargetException
[java] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
[java] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
[java] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
[java] at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
[java] at oracle.iam.platform.OIMClient.getServiceDelegate(OIMClient.java:193)
[java] ... 5 more
[java] Caused by: oracle.iam.platform.utils.NoSuchServiceException: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
[java] java.io.EOFException]
[java] at oracle.iam.platformservice.api.ClientLoginSessionServiceDelegate.(Unknown Source)
[java] ... 10 more
[java] Caused by: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
[java] java.io.EOFException]
[java] at weblogic.jrmp.Context.lookup(Context.java:189)
[java] at weblogic.jrmp.Context.lookup(Context.java:195)
[java] at javax.naming.InitialContext.lookup(InitialContext.java:392)
[java] at org.springframework.jndi.JndiTemplate$1.doInContext(JndiTemplate.java:132)
[java] at org.springframework.jndi.JndiTemplate.execute(JndiTemplate.java:88)
[java] at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:130)
[java] at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:155)
[java] ... 11 more
[java] Caused by: java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
[java] java.io.EOFException
[java] at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:286)
[java] at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:184)
[java] at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:322)
[java] at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
[java] at weblogic.jrmp.Context.lookup(Context.java:185)
[java] ... 17 more
[java] Caused by: java.io.EOFException
[java] at java.io.DataInputStream.readByte(DataInputStream.java:250)
[java] at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:228)
[java] ... 21 more
[java] Error occured during the use of plugin registering utility. java.lang.reflect.InvocationTargetException
[java] Jun 13, 2012 3:54:10 PM PluginUtility main
[java] SEVERE: Exception occured {0}
[java] oracle.iam.platform.utils.NoSuchServiceException: java.lang.reflect.InvocationTargetException
[java] at oracle.iam.platform.OIMClient.getServiceDelegate(OIMClient.java:197)
[java] at oracle.iam.platform.OIMClient.getService(OIMClient.java:174)
[java] at oracle.iam.platformservice.utils.PluginUtility.main(PluginUtility.java:128)
[java] Caused by: java.lang.reflect.InvocationTargetException
[java] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
[java] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
[java] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
[java] at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
[java] at oracle.iam.platform.OIMClient.getServiceDelegate(OIMClient.java:193)
[java] ... 2 more
[java] Caused by: oracle.iam.platform.utils.NoSuchServiceException: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
[java] java.io.EOFException]
[java] at oracle.iam.platformservice.api.PlatformServiceDelegate.(Unknown Source)
[java] ... 7 more
[java] Caused by: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
[java] java.io.EOFException]
[java] at weblogic.jrmp.Context.lookup(Context.java:189)
[java] at weblogic.jrmp.Context.lookup(Context.java:195)
[java] at javax.naming.InitialContext.lookup(InitialContext.java:392)
[java] at org.springframework.jndi.JndiTemplate$1.doInContext(JndiTemplate.java:132)
[java] at org.springframework.jndi.JndiTemplate.execute(JndiTemplate.java:88)
[java] at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:130)
[java] at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:155)
[java] ... 8 more
[java] Caused by: java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
[java] java.io.EOFException
[java] at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:286)
[java] at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:184)
[java] at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:322)
[java] at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
[java] at weblogic.jrmp.Context.lookup(Context.java:185)
[java] ... 14 more
[java] Caused by: java.io.EOFException
[java] at java.io.DataInputStream.readByte(DataInputStream.java:250)
[java] at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:228)
[java] ... 18 more
[java] Exception in thread "main" oracle.iam.platform.utils.NoSuchServiceException: java.lang.reflect.InvocationTargetException
[java] at oracle.iam.platform.OIMClient.getServiceDelegate(OIMClient.java:197)
[java] at oracle.iam.platform.OIMClient.getService(OIMClient.java:174)
[java] at oracle.iam.platformservice.utils.PluginUtility.main(PluginUtility.java:128)
[java] Caused by: java.lang.reflect.InvocationTargetException
[java] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
[java] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
[java] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
[java] at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
[java] at oracle.iam.platform.OIMClient.getServiceDelegate(OIMClient.java:193)
[java] ... 2 more
[java] Caused by: oracle.iam.platform.utils.NoSuchServiceException: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
[java] java.io.EOFException]
[java] at oracle.iam.platformservice.api.PlatformServiceDelegate.(Unknown Source)
[java] ... 7 more
[java] Caused by: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
[java] java.io.EOFException]
[java] at weblogic.jrmp.Context.lookup(Context.java:189)
[java] at weblogic.jrmp.Context.lookup(Context.java:195)
[java] at javax.naming.InitialContext.lookup(InitialContext.java:392)
[java] at org.springframework.jndi.JndiTemplate$1.doInContext(JndiTemplate.java:132)
[java] at org.springframework.jndi.JndiTemplate.execute(JndiTemplate.java:88)
[java] at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:130)
[java] at org.springframework.jndi.JndiTemplate.lookup(JndiTemplate.java:155)
[java] ... 8 more
[java] Caused by: java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
[java] java.io.EOFException
[java] at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:286)
[java] at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:184)
[java] at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:322)
[java] at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
[java] at weblogic.jrmp.Context.lookup(Context.java:185)
[java] ... 14 more
[java] Caused by: java.io.EOFException
[java] at java.io.DataInputStream.readByte(DataInputStream.java:250)
[java] at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:228)
[java] ... 18 more
[java] Java Result: 1





Cause:


Unnecessary Jar Files in the CLASSPATH.





Solution:


Add the following jar files into the classpath. They are


$OIM_ORACLE_HOME/server/ext/spring.jar
$OIM_ORACLE_HOME/server/ext/jakarta-commons/commons-logging.jar
$OIM_ORACLE_HOME/server/ext/internal/toplink.jariam-platform-context.jar
$OIM_ORACLE_HOME/server/platform/iam-platform-utils.jar
$OIM_ORACLE_HOME/server/platform/iam-platform-auth-client.jar
$OIM_ORACLE_HOME/server/platform/iam-platform-pluginframework.jar
$OIM_ORACLE_HOME/server/client/oimclient.jar
$WL_HOME/server/lib/wlfullclient.jar



Once You setup the CLASSPATH and plugin will deploy in OIM without any issue.

15 comments:

  1. Hi

    i didnt get it can you give the steps please.

    Thanks

    ReplyDelete
  2. Please follow the Event Handler Development my existing blog and its available complete steps from development to deployment. Please follow the lync.

    http://idmoim.blogspot.com/2011/07/developing-and-deploying-oim-11g-custom_29.html

    ReplyDelete
  3. Still I am facing issues with

    Problem: oracle.iam.platform.utils.ant.PasswordInputHandler

    c:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility>ant -f pluginregistration
    .xml register
    Unable to locate tools.jar. Expected to find it in C:\Java\jrockit-jre1.6.0_33-R
    28.2.4\lib\tools.jar
    Buildfile: c:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility\pluginregistra
    tion.xml

    register:
    [echo]
    [echo] ********************************************************************
    ***********
    [echo] REGISTRATION TOOL TO REGISTER
    [echo] ********************************************************************
    ***********
    [echo] This tool can be used to register or unregister plugins to OIM.
    [echo]
    [echo] Edit the ant.properties file to set the properties.
    [echo] Invoke the corresponding ant targets (register or unregister) to per
    form registration or unregistration correspondingly.
    [echo]
    [echo] Following are the additional system properties accepted by the utili
    ty. They would be prompted if not passed at the time of invoking the utility
    .
    [echo]
    [echo] OIM.Username (User ID of the oim user)
    [echo] ServerURL (URL of the server. WLS : t3://: W
    AS : corbaloc:iiop:: )
    [echo] Context Factory ( JNDI Context Factory WLS : weblogic.jn
    di.WLInitialContextFactory WAS: com.ibm.websphere.naming.WsnInitialContextFactor
    y)
    [echo] PluginZipToRegister (Complete name with path of the plug
    in file. Required for registering a plugin.)
    [echo]
    [echo] Set the other properties in ant.properties file:
    [echo] wls.home/was.home
    [echo] oim.home
    [echo] login.config
    [echo]
    [echo]
    [echo] C:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility\OracleMiddlew
    areOracle_IDM1server\ext\spring.jar;C:\Oracle\Middleware\Oracle_IDM1\server\plug
    in_utility\OracleMiddlewareOracle_IDM1server\ext\jakarta-commons\commons-logging
    .jar;C:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility\OracleMiddlewareOrac
    le_IDM1server\ext\internal\toplink.jar;C:\Oracle\Middleware\Oracle_IDM1\server\p
    lugin_utility\OracleMiddlewareOracle_IDM1server\platform\iam-platform-context.ja
    r;C:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility\OracleMiddlewareOracle_
    IDM1server\platform\iam-platform-utils.jar;C:\Oracle\Middleware\Oracle_IDM1\serv
    er\plugin_utility\OracleMiddlewareOracle_IDM1server\platform\iam-platform-auth-c
    lient.jar;C:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility\OracleMiddlewar
    eOracle_IDM1server\platform\iam-platform-pluginframework.jar;C:\Oracle\Middlewar
    e\Oracle_IDM1\server\plugin_utility\OracleMiddlewareOracle_IDM1server\client\oim
    client.jar;C:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility\OracleMiddlewa
    rewlserver_10.3\server\lib\wlfullclient.jar;C:\Oracle\Middleware\Oracle_IDM1\ser
    ver\plugin_utility\OracleMiddleware\oracle_common\modules\oracle.jrf_11.1.1\jrf-
    api.jar
    [input] Enter the oim user id:
    xelsysadm

    BUILD FAILED
    c:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility\pluginregistration.xml:74
    : Class not found: oracle.iam.platform.utils.ant.PasswordInputHandler

    Total time: 5 seconds

    c:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility>

    ReplyDelete
    Replies
    1. HI
      Tools.jar is not available in the class path. setting the classpath as follows in weblogic environments:
      1. Go to WebLogic Domain directory c:\Oracle\Middleware\user_projects\domains\yourdomain\bin\
      2. run the setSOADomainEnv.bat file.
      3. Deploy the plugin.
      Please let me know if you have any issues.

      Delete
  4. Hi,
    I have getting below error.
    BUILD FAILED
    c:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility\pluginregistration.xml:74
    : Class not found: oracle.iam.platform.utils.ant.PasswordInputHandler

    Total time: 5 seconds

    c:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility>

    I have followed above what you said still i am getting same error.
    Please help me

    ReplyDelete
    Replies
    1. 1. Open the Command Windows.
      2. Go to the c:\Oracle\Middleware\user_projects\domain\\bin directory.
      3. Execute the setDomainEnt.bat file and It will set the OIM classpath.
      4. Go to the c:\Oracle\Middleware\Oracle_IDM1\server\plugin_utility directory.
      5. Execute the ant -f pluginregistration.xml register command and it will ask the following parameters:
      1) OIM Admin User Name : xelsysadm
      2) OIM Admin Password : xelsysadm password
      3) OIM URL : t3://localhost:14000
      4) Plugin Zip File absolute path.

      The plugin will deploy.

      Delete
    2. Hi,

      Thank you for solution.
      I have successfully deployed the event handler for uniq ID generation.but post deploying event handler also the code is not working.
      Any steps is required post deploying of event handler for effecting code in to OIM.
      Please let me know.

      Thanks,
      Venu

      Delete
    3. Hi venu.

      Thanks for your info. I have already blogged to deploy the event handler with example for pre-processor. You can modify the pre-process code to post processor. I am providing the link as follows:

      http://idmoim.blogspot.com/2011/07/developing-and-deploying-oim-11g-custom_29.html

      Delete
  5. Hi,
    I am facing with this exception for a week,
    I have a class which have a function to connect oim. While calling this function from main , it works perfectly,
    I added this class to jsf app. but in jsf app, it throws same exception.
    you have any suggestion about it?
    Development Env: Jdev and weblogic 12 C

    ReplyDelete
  6. Hi
    Already jar files exists in the web logic classpath. Please can you remove weblogic related jar files from your WEB-INF/lib directory. Please let me know if you need more help.

    ReplyDelete
  7. Deleted all jars and libs in web-inf/lib but same error . Here is web-inf/lib
    http://tinypic.com/r/ipczsm/8

    ReplyDelete
    Replies
    1. Hi

      Can you post the stack trace details and I will look the stack trace and let you know the details to you.


      Delete
    2. All details here:
      http://stackoverflow.com/questions/25630220/oracle-iam-platform-utils-nosuchserviceexception-java-lang-reflect-invocationt

      Delete
    3. Hi
      Server and JSF LIB jar files causing the problem. In your stack trace actual error is java.lang.NoSuchMethodError: weblogic.rmi.internal.MethodDescriptor.(Ljava/lang/reflect/Method;Ljava/lang/Class;ZZZZII)V

      Please can you verify is this supported web logic version for OIM. If supported version, please can you generate the wlfullclient.jar file as follows:

      http://idmoim.blogspot.com/2011/07/generating-wlfullclientjar-file.html

      Delete
  8. Hi.

    I have an issue trying to register my plugin, I added the Jar files that your comment, but the issue still ocurred.

    [echo] Feb 5, 2016 8:01:38 PM PluginUtility main
    [echo] SEVERE: Exception occured {0}
    [echo] javax.ejb.EJBException: ; nested exception is:
    [echo] java.io.EOFException; nested exception is: java.io.EOFException
    [echo] java.io.EOFException
    [echo] at weblogic.rjvm.t3.MuxableSocketT3.endOfStream(MuxableSocketT3.java:345)
    [echo] at weblogic.socket.SocketMuxer.deliverExceptionAndCleanup(SocketMuxer.java:826)
    [echo] at weblogic.socket.SocketMuxer.deliverEndOfStream(SocketMuxer.java:760)
    [echo] at weblogic.socket.SocketMuxer.readReadySocketOnce(SocketMuxer.java:941)
    [echo] at weblogic.socket.SocketMuxer.readReadySocket(SocketMuxer.java:888)
    [echo] at weblogic.socket.JavaSocketMuxer.processSockets(JavaSocketMuxer.java:339)
    [echo] at weblogic.socket.SocketReaderRequest.run(SocketReaderRequest.java:29)
    [echo] at weblogic.work.ExecuteRequestAdapter.execute(ExecuteRequestAdapter.java:21)
    [echo] at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:145)
    [echo] at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:117)
    [echo] javax.ejb.EJBException: ; nested exception is:
    [echo] java.io.EOFException; nested exception is: java.io.EOFException
    [echo] at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.unwrapRemoteException(RemoteBusinessIntfProxy.java:121)
    [echo] at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(RemoteBusinessIntfProxy.java:103)
    [echo] at $Proxy2.registerPluginx(Unknown Source)
    [echo] at oracle.iam.platformservice.api.PlatformServiceDelegate.registerPlugin(Unknown Source)
    [echo] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [echo] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    [echo] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    [echo] at java.lang.reflect.Method.invoke(Method.java:597)
    [echo] at Thor.API.Base.SecurityInvocationHandler$1.run(SecurityInvocationHandler.java:68)
    [echo] at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
    [echo] at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
    [echo] at weblogic.security.Security.runAs(Security.java:41)
    [echo] at Thor.API.Security.LoginHandler.weblogicLoginSession.runAs(weblogicLoginSession.java:52)
    [echo] at Thor.API.Base.SecurityInvocationHandler.invoke(SecurityInvocationHandler.java:79)
    [echo] at $Proxy3.registerPlugin(Unknown Source)
    [echo] at oracle.iam.platformservice.utils.PluginUtility.registerPlugin(PluginUtility.java:164)
    [echo] at oracle.iam.platformservice.utils.PluginUtility.main(PluginUtility.java:132)
    [echo] Caused by: java.io.EOFException
    [echo] at weblogic.rjvm.t3.MuxableSocketT3.endOfStream(MuxableSocketT3.java:345)
    [echo] at weblogic.socket.SocketMuxer.deliverExceptionAndCleanup(SocketMuxer.java:826)
    [echo] at weblogic.socket.SocketMuxer.deliverEndOfStream(SocketMuxer.java:760)
    [echo] at weblogic.socket.SocketMuxer.readReadySocketOnce(SocketMuxer.java:941)
    [echo] at weblogic.socket.SocketMuxer.readReadySocket(SocketMuxer.java:888)
    [echo] at weblogic.socket.JavaSocketMuxer.processSockets(JavaSocketMuxer.java:339)
    [echo] at weblogic.socket.SocketReaderRequest.run(SocketReaderRequest.java:29)
    [echo] at weblogic.work.ExecuteRequestAdapter.execute(ExecuteRequestAdapter.java:21)
    [echo] at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:145)
    [echo] at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:117)

    ReplyDelete