Remedy for following exception: java.lang.UnsatisfiedLinkError: ocijdbc10 (Library is already loaded in another ClassLoader)
I am working in web service with RAD and IBM web sphere server so some time I have to kill the java process to stop the server even after stopping it from the IDE. But when I am doing so in next start up I am getting following exception and application is not working in log i am able to see following exception.
Creating a shared Library:
- Switch to the J2EE perspective.
- In the Project Explorer view, expand the Enterprise Applications folder.
- Under the Enterprise Application project folder for which you want to add a shared library, double-click the Deployment Descriptor to open the Application Deployment Descriptor editor.
- Select the Deployment tab at the bottom of the editor.
- Expand the shared library section.
- Click the Add button beside the library list table. The Add Library Entry dialog box opens.
- In the Add a library entry dialog box, specify the any name.
- Search the ocijdbc10.dll file and take the path.
- In the Native path list box, browse or add a path which forms the location for the resource ocijdbc10.
- Save your changes and close the editor. The shared library entry has been added to the deployment descriptor files.
- Logon to the Websphere Application Server console.
- Go to Environment -> Shared Libraries
- Create your own Shared Library. Add the classpath pointing to your JAR files.
- Apply and save this configuration.
Adding a shared Library:
- Go to Servers -> Application Servers -> Websphere_Portal -> Java and Process Management -> ClassLoader.
- Class loader may vary but it should only contain one link. Click on that class loader.
- Click on the Shared Library References.
- You will notice all the shared libraries that are used by Websphere Portal. Click on Add.
- Add your shared library.
- Save and restart Websphere Portal.
Please try yourself. If you face any issue please come back so that I can do better analysis.