Could not find portal application SAPJ2EE::library:bi~mmr~db

Hi,
   I am trying to connect to BW system using BI_XMLA Connector using System com.sap.portal.systems.BIUDI.
And created a portal Application which is given in the document (How To Use the BI Java SDK in a Portal iView)
tried to access the BW system created through this code.
I deployed the par file into portal and when i run it i got the following error:
"Could not find portal application SAPJ2EE::library:bimmrdb"
SAPJ2EE::library:bimmrdb is in the portalapp.xml file in the application.
This was the following code in the xml file
<property name="SharingReference"
value="SAPJ2EE::library:com.sap.ip.bi.sdk,SAPJ2EE::library:bi~mmr~jmi,SAPJ2EE::library:bi~mmr~core,SAPJ2EE::library:bi~mmr~db,SAPJ2EE::library:bi~mmr~cwm_1.0_library,com.sap.portal.htmlb,com.sap.portal.ivs.connectors
ervice"/>
Please help me to solve this problem. And please tell me how to use bi java sdk and where can i find the examples or steps to do so.
Thanks and Regards
Padmaja.

Hi Amit
No the problem is still there.
We had BI Java and EP* application running OK up to SP13. After I applied SP14 I had the error.
Continued to SP15. Problem still there.
Then I rolled back the whole bloody J2ee instance to SP13 incl JSPM/SDM
And guess what... problem is now also there in SP13.. so there must be something written into the db that is persistent no matter what you do in SDM or JSPM
My only solution I now are facing is to restore a backup of the db and continue from there and NOT apply any patches for the BIJava which made the problem to happen!
What is your scenario? Same as mine?
Best Regards
/Tobbe

Similar Messages

  • Could not find portal application com.sap.portal.umeregistration

    Hi friends,
    We have migrated the portal from EP6 SP2 to NW'04 SPS 18. KMC and the portal migration has been done successfully. Now i can login with my ID in the new portal. But after migration some of the iviews stopped working and I am getting the error
    "Page could not create the iView."
    on the screen. In the log file the root cause is
    "Caused by: com.sapportals.portal.prt.core.broker.PortalApplicationNotFoundException: Could not find portal application com.sap.portal.umeregistration"
    Do you have any idea?
    Regards,
    Nilesh Patil

    Bhupesh,
    In EP7.0, you can access the log files in a different way.
    1) Directly accessing the log file on the server. location is <drive>:\usr\sap\<SID>\<instance_number>\j2ee\cluster\server0\log\defaultTrace.<n>.trc
    2) Accessing it through Visual Administrator. Go to the Server -> Services -> Logviewer
    3) Accessing the log file through Netweaver Administrator from Portal. URL for Netweaver Administrator is http://<Portal Server>:50xxx/nwa -> Login with Portal user/pass -> Monitoring -> Logs and Traces -> select predefined view -> Default trace.
    I hope this helps.
    Regards,
    Gowri

  • Windows SharePoint Services Error: Exception Details: System.IO.FileNotFoundException: Could not find the application on the Web

    I am developing a WSS based WCM site for a customer which has a bilingual interface. Now everything is wokring fine in the development environment. Today I backed-up the Content Database and took the related control file (.ascx & .ascx.cs) to deploy it to the cusomter's test machine. I dint face any problems with the deployment, and after deleted and added the Content DB from Central Administration, I was able to access the English part of the website along with my changes without any problem.
    But when I tried accessing the Arbic part of the website, Its giving me the following error,
    تعذر العثور على تطبيق ويب الموجود على http://172.20.5.163/ar/. تأكد من كتابتك لمحدد موقع المعلومات (URL) بشكل صحيح. إذا كان URL يؤدي إلى محتوى موجود، يجب على مسؤول النظام إضافة تعيين URL للتطبيق المراد خاص بالطلب الجديد.
    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
    Exception Details: System.IO.FileNotFoundException: تعذر العثور على تطبيق ويب الموجود على http://172.20.5.163/ar/. تأكد من كتابتك لمحدد موقع المعلومات (URL) بشكل صحيح. إذا كان URL يؤدي إلى محتوى موجود، يجب على مسؤول النظام إضافة تعيين URL للتطبيق المراد خاص بالطلب الجديد.
    Roughly translated, it means "Could not find the application on the Web http://172.20.5.163/ar/. Make sure you create your site specific information (URL) correctly. If the URL to the content of lead present, the system administrator to add URL for the application of the appointment of a special request to be new.
    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
    Exception Details: System.IO.FileNotFoundException: Could not find the application on the Web http://172.20.5.163/ar/. Make sure you create your site specific information (URL) correctly. If the URL to the content of lead present, the system administrator to add URL for the application of the appointment of a special request to be new."
    Can you please tell me what is the cause of the problem and how to rectify it? Also do I need to
    Regards,
    SoniSSP

    It is searching for the page, but that page is not available. Did u install the current language pack?

  • "Could not find the application that created this file" error when trying to combine files

    I am working with a user that is trying to combine a pdf & word doc (docx).  When they try to combine the files she gets the error:  "Could not find the application that created this file" & "Please select a file created by an application that resides on your computer".  The computer is running windows XP, with office 2010 SP1, & Adobe Acrobat Pro X.
    Per previous suggestions, I have already checked to see if Adobe PDFMaker is enabled as a Word plugin, and it is.
    Recentley the user was running Acrobat 6, and this error did not occur.  It is only after upgrading to Acrobat X that this is happening.  Any help with this issue would be appreciated.

    This can also be caused if the files are in a folder deep in the file system. For example C:/xxxxxxxxxxxxxxx/yyyyyyyyyyyyyyy/zzzzzzz/aaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbb /cccccccccccccccccccc/dddddddddddddddd/eeeeeeeeeeeeeeeeeeee/ffffffff/ggggggg/hhhhhhhhhhhhh hhhhhhhhhh/myPDF.pdf
    At some point Adobe PDFMaker cannot handle the path length (also, Windows can't handle the path length either eventually)
    Solution: move the files to a shorther path (perhaps the desktop) and try from there.
    I am filing a bug report with Adobe. A descriptive exception message should be thrown instead of "could not file the app.."

  • Trouble creating a pdf converting Word doc ..."Could not find the application that created the file"

    Hello,
    I am working with Acrobat Pro 8 and am trying to create a pdf by converting a word doc. When I try that, I keep getting an error message, " Could not find the application that created this file...please select a file created by an application that resides on your computer." I can always convert a word into pdf first and then insert it into the pdf project that I am working on, however I have multiple files and I really would like to bypass that long step.
    I found another thread in this forum which talks about a simillar issue (http://forums.adobe.com/thread/429585).I tried the solution suggested there by Bill@vt regarding the print menu. I am not really sure if t have distiller installed, so I tried opening it in acrobat, but it failed. During the process, I got the follwing message "Check the Status column for a list of files that could not be printed".I do not have any clue how to check for AcroTray running in the background.
    I would really appreciate any help.
    Thanks!

    If Distiller failed to open, it sounds like you need to do a repair of your Acrobat installation. Have not heard that one before!

  • Could Not Find The Application That Created This File

    Hello Community,
    I have already been to the Acrobat forum with this post and they re-directed me to this forum.
    My problem seems to be with a InDesign file that will not export to a PDF, nor can I create the PDF from within Acrobat itself.  BTW I have Acrobat 8.1.6 on a Vista OS.
    Here is what I've done thus far:
    restarted my computer, which didn't correct anything
    printed the InDesign file to the PDF printer unsuccessfully
    Checked for InDesign and Acrobat updates and found I'm current with the updates
    Please NOTE:  I have no problem with creating a PDF with either a Word or Illustrator file; it's the InDesign file that's giving me a problem.  The message I get when I try to export from within InDesign to a PDF file is "Could not find the application that created this file; please select a file created by an application that resides on your computer."
    Please help.  Thank you very much.

    Hi John,
    Before replying to you, I decided to give it another go.  This time out, I
    was finally able to export the InDesign file, which I created, to a PDF.
    Hooray!
    I have found, in the past, that restarting my computer will clear something
    in my system, and then I can create the PDF.  Sometimes this inability to
    create a PDF happens in Word.  But this time around it was InDesign that was
    the problem file.
    Maybe it has something to do with the preferences menu.  I'll have to check
    this out.  Otherwise, all is fine.  Thanks for answering.--Pat

  • Could not find the application that created this file Acrobat Pro XI and .pptx file

    Hi,
         I just installed Acrobat Pro XI and I am trying to combine files into one pdf. The combine feature works fine with Word, excel, other pdfs but does not work with powerpoint files (.pptx). I have searched and found others have been having this issues for many past versions. I found a workaround (print the powerpoint to pdf and then merge the files) but I should not have to do it that way. Can someone help me out? Powerpoint is installed on my computer, the print pdf function works, and the Adobe add-in is active (these are the 3 solution I keep encountering) but it still will not combine a powerpoint file. Any help would be greatly appreciated.
    Thank You,
    Steve

    Hi Stephen ,
    Could you please elaborate a bit more  that what exactly happens when you try to combine .pptx file?
    Do you get any error message?
    If yes ,please share the screen shot of the same.
    Are you facing  challenge with the powerpoint files only?
    I have tried the same on my end and it is working perfectly fine .
    Try updating your Acrobat to the latest version .
    Launch Acrobat>Navigate to Help>Check for Updates .
    Regards
    Sukrit Dhingra

  • Could not find application that created this file error in Acrobat

    What is going on? I have an InDesign file that I want to convert by opening Acrobat and then converting to PDF. I am getting the error "Could not find application that created this file. [file name] Please select a file created by an application that resides on your computer."
    I most often use this functionality when I have multiple files of different origins and need to combine them into one document. Now I'm reading the forums and some are saying this functionality is no longer supported by Acrobat. Pardon my language, but WTF?!?! This is functionality that is commonly used by me and I can only assume other users. Now you have two Adobe products that won't communicate? If so, then all the hoopla stating how great the Adobe suite is should be edited. I have never seen these products take such a step backward!
    Sorry for the rant, but I find this to be ridiculous. What is the workaround, besides converting every document to PDF inside its own software and then combing the PDFs?

    InDesign uses a different method of making PDF files when you use the File->Export option in InDesign (even with Acrobat installed, it uses an internal copy of the PDF Library engine). As such, the two applications do not communicate directly with each other.
    Support for driving the PDF conversion process from within Acrobat has been removed from Acrobat X, beacuse with the new features in InDesign CS4+, Acrobat doesn't have access to the settings it needs to control things such as multimedia, spreads and transitions. ID CS5 divides PDFs into two concepts - "print" and "interactive", neither of which match the presets used by Distiller. Creating PDFs from InDesign files must therefore take place from within InDesign itself.

  • Error "Could not find -Xrun library: libjdwp.so" when starting WL 6.1 in debug mode

    Hello,
    I installed WL 6.1 SP4 on Solaris (trial version). The installation went well
    and we were able to start the server and run our application. I then added the
    debug options in the start script :
    $JAVACMD $JAVA_OPTIONS -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,address=7212,suspend=n
    When I then try to start the server I get the following error :
    Error occurred during initialization of VM
    Could not find -Xrun library: libjdwp.so
    I looked and the library is installed in our sdk :
    /products/java/j2sdk1_3_1_07/lib/sparc/libsjwp.so
    What did we do wrong?
    Thanks for your help,
    Roland

    Hi Wayne,
    I took the instructions from our WL 5.1 installation. I hope the options are still
    the same (if not can you tell me where to find the correct ones?).
    You were right about the LD_LIBRARY_PATH. I added the line :
    LD_LIBRARY_PATH=$JAVA_HOME/lib/sparc:$LD_LIBRARY_PATH
    and now I can start the application without any errors.
    Thanks!
    Roland
    "Wayne W. Scott" <[email protected]> wrote:
    >
    Where did you get the instructions for adding the debug options?
    Since libsjwp.so is a shared object, what does your LD_LIBRARY_PATH look
    like?
    Is /products/java/j2sdk1_3_1_07/lib/sparc in it?
    Wayne Scott
    Roland Pennings wrote:
    Hello,
    I installed WL 6.1 SP4 on Solaris (trial version). The installationwent well
    and we were able to start the server and run our application. I thenadded the
    debug options in the start script :
    $JAVACMD $JAVA_OPTIONS -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,address=7212,suspend=n
    When I then try to start the server I get the following error :
    Error occurred during initialization of VM
    Could not find -Xrun library: libjdwp.so
    I looked and the library is installed in our sdk :
    /products/java/j2sdk1_3_1_07/lib/sparc/libsjwp.so
    What did we do wrong?
    Thanks for your help,
    Roland

  • Could not find agent library in absolute path

    Hi,
    I have a JVMTI agent which works on windows that I am trying to port to linux.
    I have compiled to code on Ubuntu 10.04 using Eclipse and have created shared library .so file.
    When I try to run an application with the agentpath argument, I get the error: "Could not find agent library in absolute path"
    When trying to run the mtrace sample from the java JDK, it works fine.
    My Java version is:
    java version "1.6.0_20"
    Java(TM) SE Runtime Environment (build 1.6.0_20-b02)
    Java HotSpot(TM) Client VM (build 16.3-b01, mixed mode, sharing)
    I also tried running nm | grep Agent_OnLoad and got the following:
    00029220 T Agent_OnLoad
    00036230 b ZGVZ12AgentOnLoadE4data
    00030720 r ZZ12AgentOnLoadE19__PRETTY_FUNCTION__
    00036240 b ZZ12AgentOnLoadE4data
    My agent references several libraries such as boost asio and log4cxx could it be related somehow to these?
    I think it might be some sort of compilation issue because on windows it works fine.
    Thanks

    I managed to solve my problem.
    It turned out that the error was caused by missing referenced libraries that were not linked in to my so file.
    Once I added all of the required libraries, the agent started working.

  • Remote could not find my itunes library

    I have try it pairing the remote app with itunes library but without succes i have delete the app few times and start over turning on home sharing in all my devices apple tv itunes and my iphone 4s but still REMOTE could not find the itunes library what else i need to do any help?

    I am taking a complete guess on this one, as I am fairly new'ish to OS X.
    Firewall switched on at the imac? Would that cause this issue?

  • The system could not find a javax.ws.rs.ext.MessageBodyWriter or a DataSourceProvider class for the com.rest.assignment.EmpBean type and application/json mediaType.  Ensure that a javax.ws.rs.ext.MessageBodyWriter exists in the JAX-RS application for the

    Hi,
    Im trying to create a Rest WS with a @GET method that will return me an Emp object. I need the output as a JSON string.
    I have created a dynamic web project and added javax RS jars:
    When im trying to run this, i'm getting the below mentioned error:
    FlushResultHa E org.apache.wink.server.internal.handlers.FlushResultHandler handleResponse The system could not find a javax.ws.rs.ext.MessageBodyWriter or a DataSourceProvider class for the com.rest.assignment.EmpBean type and application/json mediaType.  Ensure that a javax.ws.rs.ext.MessageBodyWriter exists in the JAX-RS application for the type and media type specified.
    RequestProces I org.apache.wink.server.internal.RequestProcessor logException The following error occurred during the invocation of the handlers chain: WebApplicationException (500 - Internal Server Error)
    Please help as im stuck with this from long.
    Thanks in advance.
    Below is the code for my service class:
    package com.rest.assignment;
    import java.io.FileInputStream;
    import java.io.FileNotFoundException;
    import java.io.IOException;
    import java.util.Enumeration;
    import java.util.HashSet;
    import java.util.Properties;
    import java.util.Set;
    import javax.ws.rs.GET;
    import javax.ws.rs.Path;
    import javax.ws.rs.Produces;
    import javax.ws.rs.core.Application;
    import javax.ws.rs.core.MediaType;
    import javax.ws.rs.core.Response;
    @Path("/restService")
    public class RestService extends Application {   
        @GET
        @Path("/getEmpDetails")
        @Produces(MediaType.APPLICATION_JSON)
        public Response getStringResponse()
            EmpBean empBean = new EmpBean();
            String filePath = "C:/Program Files/IBM/workspace/HelloWorld/src/com/rest/resources/EmpData.properties";
            Properties properties = new Properties();
            try {
                properties.load(new FileInputStream(filePath));
            } catch (FileNotFoundException e) {
                e.printStackTrace();
            } catch (IOException e) {
                e.printStackTrace();
             Enumeration e = properties.propertyNames();
             String result="";
            String[] empDetailsArr;
            while (e.hasMoreElements()) {
              String key = (String) e.nextElement();
              String empDetails = properties.getProperty(key);
              empDetailsArr=empDetails.split(",");    
              empBean.setFirstName(empDetailsArr[0]);
              empBean.setLastName(empDetailsArr[1]);
              empBean.setEmpId(empDetailsArr[2]);
              empBean.setDesignation(empDetailsArr[3]);
              empBean.setSkillSet(empDetailsArr[4]);
              result = empDetailsArr[1];
            //return empBean;
            return Response.ok(empBean).type(MediaType.APPLICATION_JSON_TYPE).build();
        @Override
        public Set<Class<?>> getClasses() {
            Set<Class<?>> classes = new HashSet<Class<?>>();
            classes.add(RestService.class);
            classes.add(EmpBean.class);
            return classes;
    and my empBean goes like this:
    package com.rest.assignment;
    public class EmpBean {
        private String firstName;
        private String lastName;
        private String empId;
        private String designation;
        private String skillSet;
        public String getFirstName() {
            return firstName;
        public void setFirstName(String firstName) {
            this.firstName = firstName;
        public String getLastName() {
            return lastName;
        public void setLastName(String lastName) {
            this.lastName = lastName;
        public String getEmpId() {
            return empId;
        public void setEmpId(String empId) {
            this.empId = empId;
        public String getDesignation() {
            return designation;
        public void setDesignation(String designation) {
            this.designation = designation;
        public String getSkillSet() {
            return skillSet;
        public void setSkillSet(String skillSet) {
            this.skillSet = skillSet;
    Web.xml goes like this:
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app id="WebApp_ID" version="3.0" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
    <display-name>restWS</display-name>
    <welcome-file-list>
      <welcome-file>index.html</welcome-file>
      <welcome-file>index.htm</welcome-file>
      <welcome-file>index.jsp</welcome-file>
      <welcome-file>default.html</welcome-file>
      <welcome-file>default.htm</welcome-file>
      <welcome-file>default.jsp</welcome-file>
    </welcome-file-list>
    <servlet>
      <servlet-name>REST</servlet-name>
      <servlet-class>com.ibm.websphere.jaxrs.server.IBMRestServlet</servlet-class>
      <init-param>
       <param-name>javax.ws.rs.Application</param-name>
       <param-value>com.rest.assignment.RestService</param-value>
      </init-param>
      <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
      <servlet-name>REST</servlet-name>
      <url-pattern>/rest/*</url-pattern>
    </servlet-mapping>
    </web-app>
    When i try to return a string from my get method, it gives me a proper response. i get this exception when im trying to return a JSON response.

    Hi,
    Im trying to create a Rest WS with a @GET method that will return me an Emp object. I need the output as a JSON string.
    I have created a dynamic web project and added javax RS jars:
    When im trying to run this, i'm getting the below mentioned error:
    FlushResultHa E org.apache.wink.server.internal.handlers.FlushResultHandler handleResponse The system could not find a javax.ws.rs.ext.MessageBodyWriter or a DataSourceProvider class for the com.rest.assignment.EmpBean type and application/json mediaType.  Ensure that a javax.ws.rs.ext.MessageBodyWriter exists in the JAX-RS application for the type and media type specified.
    RequestProces I org.apache.wink.server.internal.RequestProcessor logException The following error occurred during the invocation of the handlers chain: WebApplicationException (500 - Internal Server Error)
    Please help as im stuck with this from long.
    Thanks in advance.
    Below is the code for my service class:
    package com.rest.assignment;
    import java.io.FileInputStream;
    import java.io.FileNotFoundException;
    import java.io.IOException;
    import java.util.Enumeration;
    import java.util.HashSet;
    import java.util.Properties;
    import java.util.Set;
    import javax.ws.rs.GET;
    import javax.ws.rs.Path;
    import javax.ws.rs.Produces;
    import javax.ws.rs.core.Application;
    import javax.ws.rs.core.MediaType;
    import javax.ws.rs.core.Response;
    @Path("/restService")
    public class RestService extends Application {   
        @GET
        @Path("/getEmpDetails")
        @Produces(MediaType.APPLICATION_JSON)
        public Response getStringResponse()
            EmpBean empBean = new EmpBean();
            String filePath = "C:/Program Files/IBM/workspace/HelloWorld/src/com/rest/resources/EmpData.properties";
            Properties properties = new Properties();
            try {
                properties.load(new FileInputStream(filePath));
            } catch (FileNotFoundException e) {
                e.printStackTrace();
            } catch (IOException e) {
                e.printStackTrace();
             Enumeration e = properties.propertyNames();
             String result="";
            String[] empDetailsArr;
            while (e.hasMoreElements()) {
              String key = (String) e.nextElement();
              String empDetails = properties.getProperty(key);
              empDetailsArr=empDetails.split(",");    
              empBean.setFirstName(empDetailsArr[0]);
              empBean.setLastName(empDetailsArr[1]);
              empBean.setEmpId(empDetailsArr[2]);
              empBean.setDesignation(empDetailsArr[3]);
              empBean.setSkillSet(empDetailsArr[4]);
              result = empDetailsArr[1];
            //return empBean;
            return Response.ok(empBean).type(MediaType.APPLICATION_JSON_TYPE).build();
        @Override
        public Set<Class<?>> getClasses() {
            Set<Class<?>> classes = new HashSet<Class<?>>();
            classes.add(RestService.class);
            classes.add(EmpBean.class);
            return classes;
    and my empBean goes like this:
    package com.rest.assignment;
    public class EmpBean {
        private String firstName;
        private String lastName;
        private String empId;
        private String designation;
        private String skillSet;
        public String getFirstName() {
            return firstName;
        public void setFirstName(String firstName) {
            this.firstName = firstName;
        public String getLastName() {
            return lastName;
        public void setLastName(String lastName) {
            this.lastName = lastName;
        public String getEmpId() {
            return empId;
        public void setEmpId(String empId) {
            this.empId = empId;
        public String getDesignation() {
            return designation;
        public void setDesignation(String designation) {
            this.designation = designation;
        public String getSkillSet() {
            return skillSet;
        public void setSkillSet(String skillSet) {
            this.skillSet = skillSet;
    Web.xml goes like this:
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app id="WebApp_ID" version="3.0" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
    <display-name>restWS</display-name>
    <welcome-file-list>
      <welcome-file>index.html</welcome-file>
      <welcome-file>index.htm</welcome-file>
      <welcome-file>index.jsp</welcome-file>
      <welcome-file>default.html</welcome-file>
      <welcome-file>default.htm</welcome-file>
      <welcome-file>default.jsp</welcome-file>
    </welcome-file-list>
    <servlet>
      <servlet-name>REST</servlet-name>
      <servlet-class>com.ibm.websphere.jaxrs.server.IBMRestServlet</servlet-class>
      <init-param>
       <param-name>javax.ws.rs.Application</param-name>
       <param-value>com.rest.assignment.RestService</param-value>
      </init-param>
      <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
      <servlet-name>REST</servlet-name>
      <url-pattern>/rest/*</url-pattern>
    </servlet-mapping>
    </web-app>
    When i try to return a string from my get method, it gives me a proper response. i get this exception when im trying to return a JSON response.

  • Could not find agent library on the library path or in the local directory

    Hi all,
    I'm trying to write a jvmti agent that write any information in a mysql db. I've written a simple agent that work correctly and now I'll try to insert the mysqlpp library in my agent:
    1) I've added #include <mysql++.h>
    2) and I've added mysqlpp::Connection      conn(false); (global variable)
    I've modify my Makefile and the compiler and linker work correctly but when I test the agent the VM says "Could not find agent library on the library path or in the local directory"
    Below the code:
    -- analizer.cpp --
    #include <iostream>
    #include <stdlib.h>
    #include <jni.h>
    #include <string.h>
    #include <jvmti.h>
    #include <mysql++.h>
    #include "ClassDetail.cpp"
    #define CFN(ptr) checkForNull(ptr, __FILE__, __LINE__);
    static void checkForNull(void *ptr, const char* file, int line) {
        if(ptr == NULL) {
            std::cerr << "ERROR : NullPointerException in " << file <<":"<< line<<"\n";
            abort();
    static char* getErrorName(jvmtiEnv *jvmti, jvmtiError err) {
        jvmtiError errNum;
        char *name;
        errNum = jvmti->GetErrorName(err, &name);
        if( errNum != JVMTI_ERROR_NONE) {
            std::cerr << "ERROR : errore nel reprire l'error name " << errNum;
            abort();
        return name;
    #define CJVMTIE(jvmti, err) checkJvmtiError(jvmti, err, __FILE__, __LINE__);
    static void checkJvmtiError(jvmtiEnv *jvmti, jvmtiError err, const char* file, int line) {
        if(err != JVMTI_ERROR_NONE) {
            char *name = getErrorName(jvmti, err);
            std::cout << "ERROR : JVMTI error " << err << "("<<name<<") in "<<file<<":"<<line;
            abort();
    static void vmInit(jvmtiEnv *jvmti_env, JNIEnv *jni, jthread thread);
    static void startGCEvent(jvmtiEnv *jvmti_env);
    static void finishGCEvent(jvmtiEnv *jvmti_env);
    static jvmtiIterationControl JNICALL heapObject(jlong tag, jlong size, jlong* tag_ptr, void* userData);
    jrawMonitorID           lock;
    int                     gc_count;
    long                    heapSize = 0;
    bool                    heapCheck = false;
    mysqlpp::Connection      conn(false);
    JNIEXPORT jint JNICALL Agent_OnLoad(JavaVM *vm, char *options, void *reserved) {
        std::cout<<"OnLoad\n";
        jint                rc;
        jvmtiEnv            *jvmti = NULL;
        jvmtiError          err;
        jvmtiCapabilities   capabilities;
        jvmtiEventCallbacks callbacks;
        rc = vm->GetEnv((void **)&jvmti, JVMTI_VERSION);
        if( rc != JNI_OK) {
            std::cout << "ERROR : Errore nell'ottenere 'environment rc = " << rc;
            return -1;
        CFN(jvmti);
        err = jvmti->GetCapabilities(&capabilities);
        CJVMTIE(jvmti, err);
        CFN(&capabilities);
        capabilities.can_generate_garbage_collection_events = true;
        capabilities.can_tag_objects = true;
        CJVMTIE(jvmti, jvmti->AddCapabilities(&capabilities));
        CJVMTIE(jvmti, jvmti->CreateRawMonitor("agent lock", &lock));
        callbacks.VMInit = &vmInit;
        callbacks.GarbageCollectionStart = &startGCEvent;
        callbacks.GarbageCollectionFinish = &finishGCEvent;
        CJVMTIE(jvmti, jvmti->SetEventCallbacks(&callbacks, sizeof(callbacks)));
        jvmti->SetEventNotificationMode(JVMTI_ENABLE, JVMTI_EVENT_VM_INIT, NULL);
        jvmti->SetEventNotificationMode(JVMTI_ENABLE, JVMTI_EVENT_GARBAGE_COLLECTION_START, NULL);
        jvmti->SetEventNotificationMode(JVMTI_ENABLE, JVMTI_EVENT_GARBAGE_COLLECTION_FINISH, NULL);
        return 0;
    JNIEXPORT void JNICALL Agent_OnUnload(JavaVM *vm)
        std::cout<<"OnUnload\n";
    static void JNICALL worker(jvmtiEnv *jvmti, JNIEnv *jni, void *p) {
        std::cout << "worker";
        for (;;) {
            CJVMTIE(jvmti, jvmti->RawMonitorEnter(lock));
            while (gc_count == 0) {
                CJVMTIE(jvmti, jvmti->RawMonitorWait(lock, 0));
                jvmti->RawMonitorExit(lock);
            gc_count = 0;
            jvmti->RawMonitorExit(lock);
            /* Perform arbitrary JVMTI/JNI work here to do post-GC cleanup */
            if(!heapCheck) {
                heapCheck = true;
                jint        count;
                jclass    *classes;
                CJVMTIE(jvmti, jvmti->GetLoadedClasses(&count, &classes));
                ClassDetail *details = (ClassDetail*)calloc(sizeof(ClassDetail), count);
                for(int i = 0; i < count; i++) {
                    char *sig;
                    CJVMTIE(jvmti, jvmti->GetClassSignature(classes, &sig, NULL));
    CFN(sig);
    details[i] = ClassDetail(strdup(sig));
    CJVMTIE(jvmti, jvmti->SetTag(classes[i], (jlong)(ptrdiff_t)(void*) (&details[i])));
    heapSize = 0;
    CJVMTIE(jvmti, jvmti->IterateOverHeap(JVMTI_HEAP_OBJECT_EITHER, &heapObject, NULL));
    std::cout << "Heap Memory : " << heapSize<<'\n';
    heapCheck = false;
    static void vmInit(jvmtiEnv jvmti, JNIEnv jni, jthread thread) {
    jclass clazz = jni->FindClass("java/lang/Thread");
    jmethodID mid = jni->GetMethodID(clazz, "<init>", "()V");
    jthread _thread = jni->NewObject(clazz, mid);
    CJVMTIE(jvmti, jvmti->RunAgentThread(_thread, &worker, NULL, JVMTI_THREAD_MAX_PRIORITY));
    static void startGCEvent(jvmtiEnv *jvmti) {
    static void finishGCEvent(jvmtiEnv *jvmti) {
    std::cout << "****************************************************************** <<<<<<<<<<<< Finito gc\n";
    gc_count++;
    CJVMTIE(jvmti,jvmti->RawMonitorEnter(lock));
    CJVMTIE(jvmti,jvmti->RawMonitorNotify(lock));
    CJVMTIE(jvmti,jvmti->RawMonitorExit(lock));
    static jvmtiIterationControl JNICALL heapObject(jlong tag, jlong size, jlong* tag_ptr, void* userData) {
    if(tag != (jlong) 0) {
    std::cout << "Tag : " << tag<< '\n';
    ClassDetail detail = (ClassDetail) (void*) (ptrdiff_t) tag;
    char *sig = detail->getSignature();
    std::cout << "Class " << sig << " size : " << size<<'\n';
    heapSize += size;
    return JVMTI_ITERATION_CONTINUE;
    -- ClassDetail.cpp --class ClassDetail {
    private:
    char* signature;
    public:
    ClassDetail(char* signature){
    this->signature = signature;
    char* getSignature() { return this->signature;}
    --Makefile--########################################################################
    # Sample GNU Makefile for building JVMTI Demo waiters
    # Example uses:
    # gnumake JDK=<java_home> OSNAME=solaris [OPT=true] [LIBARCH=sparc]
    # gnumake JDK=<java_home> OSNAME=solaris [OPT=true] [LIBARCH=sparcv9]
    # gnumake JDK=<java_home> OSNAME=linux [OPT=true]
    # gnumake JDK=<java_home> OSNAME=win32 [OPT=true]
    # Source lists
    LIBNAME=analizer
    SOURCES=analizer.cpp
    MYSQLPP_LIB_PATH=/home/claudio/Desktop/Scaricati2/mysql++-3.0.6/mysqlpp_lib/lib/
    MYSQLPP_HEADER_PATH=/home/claudio/Desktop/Scaricati2/mysql++-3.0.6/mysqlpp_lib/include/mysql++
    MYSQL_PATH=/opt/mysql-5.0.51a-linux-i686-icc-glibc23
    # Solaris Sun C Compiler Version 5.5
    ifeq ($(OSNAME), solaris)
    # Tell gnumake which compilers to use
    CC=cc
    CXX=CC
    # Sun Solaris Compiler options needed
    COMMON_FLAGS=-mt -KPIC
    # Check LIBARCH for any special compiler options
    LIBARCH=$(shell uname -p)
    ifeq ($(LIBARCH), sparc)
    COMMON_FLAGS+=-xarch=v8 -xregs=no%appl
    endif
    ifeq ($(LIBARCH), sparcv9)
    COMMON_FLAGS+=-xarch=v9 -xregs=no%appl
    endif
    ifeq ($(OPT), true)
    CXXFLAGS=-xO2 $(COMMON_FLAGS)
    else
    CXXFLAGS=-g $(COMMON_FLAGS)
    endif
    # Object files needed to create library
    OBJECTS=$(SOURCES:%.cpp=%.o)
    # Library name and options needed to build it
    LIBRARY=lib$(LIBNAME).so
    LDFLAGS=-z defs -ztext
    # Libraries we are dependent on
    LIBRARIES= -lc
    # Building a shared library
    LINK_SHARED=$(LINK.cc) -G -o $@
    endif
    # Linux GNU C Compiler
    ifeq ($(OSNAME), linux)
    # GNU Compiler options needed to build it
    COMMON_FLAGS=-fno-strict-aliasing -fPIC -fno-omit-frame-pointer
    # Options that help find errors
    COMMON_FLAGS+= -W -Wall -Wno-unused -Wno-parentheses
    ifeq ($(OPT), true)
    CXXFLAGS=-O2 $(COMMON_FLAGS)
    else
    CXXFLAGS=-g $(COMMON_FLAGS)
    endif
    # Object files needed to create library
    OBJECTS=$(SOURCES:%.cpp=%.o)
    # Library name and options needed to build it
    LIBRARY=lib$(LIBNAME).so
    LDFLAGS=-Wl,-soname=$(LIBRARY) -static-libgcc -mimpure-text
    LDFLAGS += -lmysqlpp
    # Libraries we are dependent on
    LIBRARIES=
    # Building a shared library
    LINK_SHARED=$(LINK.cc) -shared -o $@
    endif
    # Windows Microsoft C/C++ Optimizing Compiler Version 12
    ifeq ($(OSNAME), win32)
    CC=cl
    # Compiler options needed to build it
    COMMON_FLAGS=-Gy -DWIN32
    # Options that help find errors
    COMMON_FLAGS+=-W0 -WX
    ifeq ($(OPT), true)
    CXXFLAGS= -Ox -Op -Zi $(COMMON_FLAGS)
    else
    CXXFLAGS= -Od -Zi $(COMMON_FLAGS)
    endif
    # Object files needed to create library
    OBJECTS=$(SOURCES:%.cpp=%.obj)
    # Library name and options needed to build it
    LIBRARY=$(LIBNAME).dll
    LDFLAGS=
    # Libraries we are dependent on
    LIBRARIES=
    # Building a shared library
    LINK_SHARED=link -dll -out:$@
    endif
    # Common -I options
    CXXFLAGS += -I.
    #CXXFLAGS += -I../agent_util
    CXXFLAGS += -I$(JDK)/include -I$(JDK)/include/$(OSNAME)
    CXXFLAGS += -I$(MYSQLPP_HEADER_PATH) -I$(MYSQL_PATH)/include -L$(MYSQLPP_LIB_PATH) -I$(MYSQLPP_LIB_PATH)
    # Default rule
    all: $(LIBRARY)
    # Build native library
    $(LIBRARY): $(OBJECTS)
         $(LINK_SHARED) $(OBJECTS) $(LIBRARIES)
    # Cleanup the built bits
    clean:
         rm -f $(LIBRARY) $(OBJECTS)
    # Simple tester
    test: all
         LD_LIBRARY_PATH=`pwd` $(JDK)/bin/java -agentlib:$(LIBNAME) -jar jvmti-test.jar
         #LD_LIBRARY_PATH=`pwd` $(JDK)/bin/java -agentlib:$(LIBNAME) -version
    # Compilation rule only needed on Windows
    ifeq ($(OSNAME), win32)
    %.obj: %.cpp
         $(COMPILE.cc) $<
    endif

    Did you make sure your library (call it x) starts is named libx.so (atleast, on linux, possibly libx.dll on windows, not sure)? It will not load otherwise, and you must specify -agentlib:x (rather than saying libx.so). Yes, it is "funny" how it gives the same uninformative error message for a wide variety of errors. It will also give you this same error message if there are still unresolved symbols upon loading your library (which would be my second guess).

  • Application was not properly initialized at startup, could not find Factory

    I am trying to deploy application on new netweaver installation (it was working on some other SAP AS netweaver installations)
    and I have ran into curious problem
    Warning occurred on server 103571050 during startApp JavaEE/ear : ASJ.web.000607 (Failed in component: JavaEE/ear, ) Initialization of servlet [Faces Servlet] failed. Check init() method of servlet. Error is: [java.lang.IllegalStateException: Application was not properly initialized at startup, could not find Factory: javax.faces.context.FacesContextFactory]
    Anybody can help me at least a little?

    i fixed facelets, that wasnt problem..
    just adding another message from the log
    Cannot notify listener [class com.sun.faces.config.ConfigureListener] that [szc] web application initialization process is starting.
    For more details on the problem please check traces searching by logId: null

  • Could not find -Xrun library: libjmeter.sl

    Hi ..
    My environment is:
    [oracle@yavuz] /oracle # uname -a
    HP-UX yavuz B.11.11 U 9000/800 4205714048 unlimited-user license
    [oracle@yavuz] /oracle # java -version
    java version "1.4.2.10"
    Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2.10-060112-14:28)
    Java HotSpot(TM) Server VM (build 1.4.2 1.4.2.10-060112-16:07-PA_RISC2.0 PA2.0 (aCC_AP), mixed mode)
    And Oracle 10g App Server..
    I have installed HP Jmeter 3.0 and followed the installation instructions. I have added
    -Xbootclasspath/a:/opt/hpjmeter/lib/agent.jar
    -Xrunjmeter
    to my Java options.. (in Oracle App Serv.)
    In .profile
    SHLIB_PATH=$ORACLE_HOME/lib32:$ORACLE_HOME/rdbms/lib32:/opt/hpjmeter/lib
    /PA_RISC2.0;export SHLIB_PATH
    (libjmeter.sl is in /opt/hpjmeter/lib/PA_RISC2.0)
    Note: I have also tried to change LD_LIBRARY_PATH (with/without SHLIB_PATH)
    and I have updated my env with
    . .profile
    And I When I run my Oracle App, got the following error message
    Error occurred during initialization of VM
    Could not find -Xrun library: libjmeter.sl
    What can be the problem.. ?
    TIA

    I had the same error message.
    I forgot to set the SHLIB_PATH. So after reading your post, I set this variable (actually I did it in the app startup script rather than in .profile, since root has to start the app in question).
    After this all worked, so I would suspect your env variable is not being applied somehow.

Maybe you are looking for