Access Violation in CallStaticVoidMethod() using JNI

Hey all,
I have a C++ app which I successfully used about a year ago to put up a Java dialog from within QuarkXPress, which has a C/C++ API. I got it out and rebuilt it and ran it, and I am now getting an Access Violation (0xC0000005) exception in JVM.dll somewhere. I am getting the exception in the CallStaticVoidMethod() call. Here is the relevant snippet from the method I am using: if anyone can spot anything obviously amiss, I would appreciate knowing about it! (This snippet borrows heavily from the "invoke.c" example program in the JNI tutorial.)
  JavaVM *jvm;
  jint res;
  jclass cls;
  jmethodID mid;
  jthrowable except = NULL;
  JavaVMInitArgs vm_args;
  JavaVMOption options[2];
  char newcpath[512];
  char newlibpath[512];
  sprintf (newcpath, "-Djava.class.path=.;C:\\Program Files\\QuarkXpress 4.0\\XTENSION"); 
  sprintf (newlibpath, "-Djava.library.path=.;C:\\Program Files\\QuarkXpress 4.0\\XTENSION");
  options[0].optionString = newcpath;
  options[1].optionString = newlibpath;
  vm_args.version = 0x00010002;
  vm_args.options = options;
  vm_args.nOptions = 2;
  vm_args.ignoreUnrecognized = JNI_TRUE;
  /* Create the Java VM */
  res = JNI_CreateJavaVM(&jvm, (void**)&env, &vm_args);
  if (res == JNI_EEXIST)
    JavaVM *jvms[1];
    jsize nVMs;
    res = JNI_GetCreatedJavaVMs(jvms, 1, &nVMs);
    jvm = jvms[0];
    jvm->AttachCurrentThread((void**)&env, NULL);
  else if (res < 0)
    return UNKNOWN_ERROR;
  cls = env->FindClass(g_javaName);
  if (cls == 0)
    checkException();
    destroy(jvm);
    return MISSING_CLASS;
  mid = env->GetStaticMethodID(cls, "main", "([Ljava/lang/String;)V");
  if (mid == 0)
    destroy(jvm);
    return MISSING_METHOD;
  env->CallStaticVoidMethod(cls, mid);

Hi ,
The method id that you get is for the public static void main(String args[]) of a class.
mid = env->GetStaticMethodID(cls, "main", "([Ljava/lang/String;)V");  if (mid == 0)  
destroy(jvm);   
return MISSING_METHOD; 
env->CallStaticVoidMethod(cls, mid);
Change the above line to
jstring jStringArgs[];
env->CallStaticVoidMethod(cls, mid, jStringArgs);
You need to pass an argument i.e. an array of jstring .
It is immaterial that they possess valid value or not .
LathaDhamo

Similar Messages

  • Unigraphics CPP JNI Memory Access violation.

    I have written a CPP code to get datas from Unigraphics which internally calls java through jni. I have created a dll using vc++6.0.
    when i run the dll from Unigraphics I am getting this problem.
    Prob: memory access violation.
    But i can able to create JVM using
    res = JNI_CreateJavaVM(&jvm, (void**)&env, &vm_args);
    But when i use cls = env->FindClass("Prog");
    i am getting this error from Unigraphics.
    (Note : CPP code can be invoked only from Unigraphics. b'cos Its a internal call from unigraphics through dll. This works fine when i write external cpp code to retrive datas from Unigraphics with jni code).
    If needed vl send the code.

    thanks for your reply.
    Most of the examples I have found on the net use a 3 parameter call to getStringUTFchars looking something similar to this:
    const char *str = GetStringUTFChars( env, some_jstring, 0);However when I try and add a third param in my dll file using VC++, i get a compile error saying:
    error C2660: 'JNIEnv_::GetStringUTFChars' : function does not take 3 argumentseven though clearly in the stacktrace output I previously included, in one of the lines it says that JINEnv does take 3 params:
    at JNIEnv_.GetStringUTFChars(JNIEnv_* , _jstring* str, Byte* isCopy)I am not sure why but using 2 params is the only way i can get the dll to compile correctly.
    That is why I used      const char *cName;
         const char *wName;
         cName = env->GetStringUTFChars( className,false);
         wName = env->GetStringUTFChars( windowName, false);Also, as I said at the end of my first post, somehow the program worked a few times ( 3-4 ) without giving me the errors, and thus, gave me the intended output. However, I have not been able to get it to work since then, nor do I know what I did, or what happened so that it would work in the first place.
    -Dale
    Message was edited by:
    smithdale87

  • Security Access Violation while using AudioClip

    'Sounds[6]= Applet.newAudioClip(new URL("file:audio/itemsprout.wav"));'
    When I try and run the applet on a browser, I get a access violation error. I'm pretty sure it's the URL part, but how do I bypass it? Or go around it?
    Thanks in advance,
    Adrian Kwok

    Argh.. But it doesn't convert mid files.. >_<its not supprted with Applet.AudioClip either so don't worry 'bout d'at -
    though if you wish to venture into the javax.sound.sampled API (never used it - but I do know its there) midi is supported

  • Accessing VB Code using JNI

    Can access functions implemented in Visual Basic from a Java program using JNI?
    I was thinking like, since there's no .h file concept in VB, we can't access VB code from Java. Correct me if i am wrong....
    Thanks,
    Vasu

    As long as the VB app somehow exports its functions via the standard "C" interface (which is how all DLLs are exported), then you can call into it via JNI. I've successfully used JNI to call into a Delphi DLL, for example.
    The hard part is that VB doesn't want to do this by default, and to be honest, I'm not enough of a VB expert to tell you how you could do this. You can check your success, however, by running the dumpbin.exe utility (comes with MSVC) on the compiled DLL and see if your method shows up in some form. Once you know that name and how the parameters look (by-ref or by-val), you should be in good shape.
    I won't say it's an easy road to go, however--you may have more luck just hosting the VB code as an ActiveX control and connecting to it via the higher-level Java->COM APIs. Stu Halloway has a collection of such links on his home page: http://staff.develop.com/halloway.

  • Access violation using snapshot for Firefox 1.0

    I'm trying to snapshot Firefox but I get an error: "Access violation at
    address 1000B64B. Read of address 00000000"
    I've snapshotted Firefox before (older versions) without any trouble but
    I've tried 1.0 on different machines and as different users without any
    success. Any idea as to why this is happening or possible workarounds? It's
    only happening with Firefox 1.0.
    Environment details: Windows 2000SP4, Novell client 4.9SP1a, ZfD 3.2,
    NetWare 5.1
    Thanks in advance.
    Michael

    See - http://support.novell.com/cgi-bin/se...?/10095571.htm
    Try deleting the values before doing the snapshot.
    Readding them via a REG file may be possible.
    Michael Steigman wrote:
    > Hmmm. Hadn't considered that. I've had bad luck with Netscape in the past
    > when the profiles were on the server (lots of writes to the history file
    > causing performance hiccups) but I'd be willing to try it, though I'd still
    > like to figure out this issue. Are you running Firefox in that manner? Any
    > particular suggestions?
    >
    > "Deyan Stoykov" <[email protected]> wrote in message
    > news:%[email protected]...
    > > Michael, this won't help you directly with your problem, but why are you
    > > taking a snapshot of Firefox in the first place? Firefox works just fine
    > > when installed on a file server and it doesn't depend on any registry
    > > settings or locally installed files.
    > >
    > > Deyan
    > >
    > > Michael Steigman wrote:
    > >> Just to follow up, I've tried with the /SLOW switch using both the
    > >> version of snapshot on my server and the version that came with ZfD 3.2
    > >> SP3 dated 3/1/2004 without any luck. Any other suggestions? The TID you
    > >> sent says " ZFD401_IR5.EXE contains the ZENworks 6.5 version of
    > >> Snappshot, but only has the resource (NLS) files for English." but I
    > >> cannot figure out which files to use - there isn't anything that matches
    > >> a "snap*" search in that archive other than the snapin folders.
    > >>
    > >> Thanks again.
    > >>
    > >> Michael
    > >>
    > >> "Craig Wilson" <[email protected]> wrote in message
    > >> news:[email protected]...
    > >>
    > >>>Perhaps trying the ZFD6.5 version of snapshot could help.....
    > >>>
    > >>>1) Saving Fils locally and running snapshot with the /SLOW option could
    > >>>help.
    > >>>
    > >>>http://support.novell.com/cgi-bin/se...?/10095150.htm
    > >>>
    > >>>Michael Steigman wrote:
    > >>>
    > >>>
    > >>>>I'm trying to snapshot Firefox but I get an error: "Access violation at
    > >>>>address 1000B64B. Read of address 00000000"
    > >>>>
    > >>>>I've snapshotted Firefox before (older versions) without any trouble but
    > >>>>I've tried 1.0 on different machines and as different users without any
    > >>>>success. Any idea as to why this is happening or possible workarounds?
    > >>>>It's
    > >>>>only happening with Firefox 1.0.
    > >>>>
    > >>>>Environment details: Windows 2000SP4, Novell client 4.9SP1a, ZfD 3.2,
    > >>>>NetWare 5.1
    > >>>>
    > >>>>Thanks in advance.
    > >>>>
    > >>>>Michael

  • Can I access BIOS using JNI?

    Hi,
    Can I access BIOS using JNI on Windows and Linux platforms?
    Mathew

    I guess that the old BIOS functions (INT 15 for instance) are "emulated" by Windows when you are running old 16-bit DOS programs. They're mapped into equivalent Windows calls. Even if the BIOS implement different features you can't run the exact BIOS code. (Please correct me if I'm wrong)
    I don't know about Linux handling of BIOS calls.
    If you simply want to read (not execute) the BIOS code in Linux you can use a special device (/dev/kmem? I can't remember the exact name) and seek to the BIOS address.

  • JVM Crash When Using JNI and COM

    I'm trying to call a DLL compiled from VB6 source code that I do not have access to. The VB6 code simply retrieves data from a DB2 database using ADO and my client code grabs that data and marshals it to my Java code. I'm attempting to achieve this using JNI and COM (without a third-party bridge). It works 75% of the time, but the other 25% of the time, the JVM crashes with the usual Hotspot crash log containing an access violation exception. However, I don't know what in my C++ code (VC++ 8) could be causing this except for passing a "wild" pointer to the code lying underneath the COM object interface. If that is the case, I don't know how I am doing that.
    The Java code that is calling my native method is running on Tomcat 5.5.25 and just to be safe, I am not allowing multiple threads to concurrently call the method in my JNI DLL (though I realize that this will kill performance). Once I can get past this problem, I'll do the COM interfacing on a worker thread in my native code so I don't screw up CoInitialize and CoUninitialize calls in the case the same thread is concurrently executing multiple calls to my native code.
    I've noticed that in most cases, the JVM crashes during my call to the pClsAccount->OpenConnection method. However, my DLL isn't what is listed on the top of the call stack, which is why I suspect the passing of a wild pointer, though I'm just taking a guess at that. Does anyone have an idea as to what's going on ?
    JNIEXPORT jobject JNICALL Java_CustomerInfo_nGetCustomerAccountInfo(JNIEnv *env, jobject customerInfo, jstring accountNumber, jstring iniFileName)
    jboolean isCopy;
    // Account info class and instance to be instantiated
    jclass accountInfoCls = NULL;
    jobject accountInfoObj = NULL;
    // The constructor ID of the accountInfoCls
    jmethodID ctorID = NULL;
    // Pointer to the interface for the ClsAccount COM object
    _clsAccount *pClsAccount = NULL;
    HRESULT hr;
    BSTR bstrIniFileName(L"");
    try
    const char *nativeAccountNumber = NULL;
    if (accountNumber != NULL)
    nativeAccountNumber = env->GetStringUTFChars(accountNumber, &isCopy);
    else
    jclass newExcCls;
    env->ExceptionDescribe();
    env->ExceptionClear();
    newExcCls = env->FindClass("java/lang/IllegalArgumentException");
    env->ThrowNew(newExcCls, "accountNumber passed in was null !");
    return NULL;
    // Initialization
    variantt varConnectionSucceeded = variantt(false);
    variantt varGetAccountInfoSucceeded = variantt(false);
    variantt varAccountNumber = variantt(nativeAccountNumber);
    bstrt bstrLastPaymentDate = bstrt();
    bstrt bstrLastErrorMessage = bstrt();
    bstrt bstrLastErrorNumber = bstrt();
    jlong jTotalDue = NULL;
    jlong jEstablishedDueDay = NULL;
    jlong jLastPaymentAmount = NULL;
    jstring jLastPaymentDate = NULL;
    jstring jLastErrorMessage = NULL;
    jstring jLastErrorNumber = NULL;
    jthrowable jException = NULL;
    const char *chLastPaymentDate = NULL;
    const char *chLastErrorMessage = NULL;
    const char *chLastErrorNumber = NULL;
    long long totalDue;
    long long lastPaymentAmount;
    long establishedDueDateDay;
    //Convert string from Java string to C string to VB string
    const char *nativeIniFileName = NULL;
    if (iniFileName != NULL)
    nativeIniFileName = env->GetStringUTFChars(iniFileName, &isCopy);
    else
    jclass newExcCls;
    env->ExceptionDescribe();
    env->ExceptionClear();
    newExcCls = env->FindClass("java/lang/IllegalArgumentException");
    env->ThrowNew(newExcCls, "iniFileName passed in was null");
    return NULL;
    bstrIniFileName = comutil::ConvertStringToBSTR(nativeIniFileName);
    CoInitialize(NULL);
    // Create an instance of the COClass with the interface over it
    hr = CoCreateInstance(__uuidof(clsAccount), NULL, CLSCTX_INPROC_SERVER, __uuidof(_clsAccount), (void **)&pClsAccount);
    if (hr == S_OK)
    varConnectionSucceeded.boolVal = pClsAccount->OpenConnection(&bstrIniFileName);
    &#12288;
    if (varConnectionSucceeded.boolVal == -1)
    varGetAccountInfoSucceeded.boolVal = pClsAccount->GetAccountPaymentInformation(&(varAccountNumber.GetVARIANT()));
    env->ReleaseStringUTFChars(accountNumber, nativeAccountNumber);
    // Extract all available account information from the ClsAccount object
    if (varGetAccountInfoSucceeded.boolVal == -1)
    totalDue = pClsAccount->TotalDue.int64;
    establishedDueDateDay = pClsAccount->EstablishedDueDateDay;
    lastPaymentAmount = pClsAccount->LastPaymentAmount.int64;
    bstrLastPaymentDate = pClsAccount->LastPaymentDate;
    chLastPaymentDate = comutil::ConvertBSTRToString(bstrLastPaymentDate.GetBSTR());
    jTotalDue = (jlong)totalDue;
    jEstablishedDueDay = (jlong)establishedDueDateDay;
    jLastPaymentAmount = (jlong)lastPaymentAmount;
    jLastPaymentDate = env->NewStringUTF(chLastPaymentDate);
    delete[] chLastPaymentDate;
    pClsAccount->CloseConnection();
    // Populate error fields if any errors occur
    bstrLastErrorMessage = pClsAccount->LastErrMessage;
    chLastErrorMessage = comutil::ConvertBSTRToString(bstrLastErrorMessage.GetBSTR());
    bstrLastErrorNumber = pClsAccount->LastErrNumber;
    chLastErrorNumber = comutil::ConvertBSTRToString(bstrLastErrorNumber.GetBSTR());
    jLastErrorMessage = env->NewStringUTF(chLastErrorMessage);
    jLastErrorNumber = env->NewStringUTF(chLastErrorNumber);
    delete[] chLastErrorMessage;
    delete[] chLastErrorNumber;
    const char* clsName = "com/nuance/merchantsmutual/businessentities/CustomerAccountInfo";
    // Find the Java class and the ID of its constructor
    accountInfoCls = env->FindClass(clsName);
    ctorID = env->GetMethodID(accountInfoCls, "<init>", "(JJJLjava/lang/String;Ljava/lang/String;Ljava/lang/String;)V");
    jException = env->ExceptionOccurred();
    if (jException != NULL)
    env->ExceptionDescribe();
    env->ExceptionClear();
    //Release all resources associated with the ClsAccount instance
    pClsAccount->Release();
    //Instantiate the class with the given parameters
    accountInfoObj = env->NewObject(accountInfoCls, ctorID, jTotalDue, jEstablishedDueDay, jLastPaymentAmount, jLastPaymentDate, jLastErrorMessage, jLastErrorNumber);
    jException = env->ExceptionOccurred();
    if (jException != NULL)
    env->ExceptionDescribe();
    env->ExceptionClear();
    else if (hr == REGDB_E_CLASSNOTREG)
    cout << "COM class not registered" << endl;
    else if ( hr == CLASS_E_NOAGGREGATION)
    cout << "COM class can't be aggregated" << endl;
    else if (hr == E_NOINTERFACE)
    cout << "No interface for COM class clsAccount" << endl;
    else if (hr == E_POINTER)
    cout << "*ppv pointer was NULL !" << endl;
    else
    cout << "Error occurred while creating COM object. HR is [" << hr << "]" << endl;
    // Free the BSTR because a new one was returned with a call to comutil::ConvertStringToBSTR
    SysFreeString(bstrIniFileName);
    // Release the string when it's no longer needed. MUST call if string won't be used
    // anymore or else a memory leak will occur
    env->ReleaseStringUTFChars(iniFileName, nativeIniFileName);
    CoUninitialize();
    &#12288;
    catch (_com_error &e)
    cout << "Encountered an exception in GetCustomerAccountInfo: Error was " << e.ErrorMessage();
    pClsAccount->Release();
    catch (...)
    pClsAccount->Release();
    return accountInfoObj;
    Edited by: Cthulhu76 on Jan 5, 2010 9:18 AM

    0x49202400 JavaThread "ContainerBackgroundProcessor[StandardEngine[Catalina]]" daemon [_thread_blocked, id=5340, stack(0x49bf0000,0x49c40000)]
    0x48a7e800 JavaThread "Thread-1" [_thread_in_native, id=5976, stack(0x48f00000,0x48f50000)]
    0x48a0dc00 JavaThread "Low Memory Detector" daemon [_thread_blocked, id=3072, stack(0x48c60000,0x48cb0000)]
    0x48a09000 JavaThread "CompilerThread0" daemon [_thread_blocked, id=4988, stack(0x48c10000,0x48c60000)]
    0x48a07c00 JavaThread "Attach Listener" daemon [_thread_blocked, id=3124, stack(0x48bc0000,0x48c10000)]
    0x48a07000 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=2572, stack(0x48b70000,0x48bc0000)]
    0x489f5c00 JavaThread "Finalizer" daemon [_thread_blocked, id=5752, stack(0x48b20000,0x48b70000)]
    0x489f4c00 JavaThread "Reference Handler" daemon [_thread_blocked, id=2596, stack(0x48ad0000,0x48b20000)]
    0x003c6000 JavaThread "main" [_thread_in_native, id=4252, stack(0x00820000,0x00870000)]
    Other Threads:
    0x489f0400 VMThread [stack: 0x48a80000,0x48ad0000] [id=5624]
    0x48a18800 WatcherThread [stack: 0x48cb0000,0x48d00000] [id=1192]
    VM state:not at safepoint (normal execution)
    VM Mutex/Monitor currently owned by a thread: None
    Heap
    def new generation total 36288K, used 12762K [0x02940000, 0x050a0000, 0x07800000)
    eden space 32256K, 34% used [0x02940000, 0x0343af58, 0x048c0000)
    from space 4032K, 37% used [0x04cb0000, 0x04e2ba28, 0x050a0000)
    to space 4032K, 0% used [0x048c0000, 0x048c0000, 0x04cb0000)
    tenured generation total 483968K, used 7518K [0x07800000, 0x250a0000, 0x42940000)
    the space 483968K, 1% used [0x07800000, 0x07f57958, 0x07f57a00, 0x250a0000)
    compacting perm gen total 14080K, used 14016K [0x42940000, 0x43700000, 0x46940000)
    the space 14080K, 99% used [0x42940000, 0x436f0320, 0x436f0400, 0x43700000)
    No shared spaces configured.
    Dynamic libraries:
    0x00400000 - 0x0040f000      C:\Program Files\Apache Software Foundation\Tomcat 5.5\bin\tomcat5.exe
    0x7c800000 - 0x7c8c0000      C:\WINDOWS\system32\ntdll.dll
    0x77e40000 - 0x77f42000      C:\WINDOWS\system32\kernel32.dll
    0x77380000 - 0x77411000      C:\WINDOWS\system32\USER32.dll
    0x77c00000 - 0x77c48000      C:\WINDOWS\system32\GDI32.dll
    0x77f50000 - 0x77feb000      C:\WINDOWS\system32\ADVAPI32.dll
    0x77c50000 - 0x77cef000      C:\WINDOWS\system32\RPCRT4.dll
    0x76f50000 - 0x76f63000      C:\WINDOWS\system32\Secur32.dll
    0x77ba0000 - 0x77bfa000      C:\WINDOWS\system32\MSVCRT.dll
    0x7c8d0000 - 0x7d0cf000      C:\WINDOWS\system32\SHELL32.dll
    0x77da0000 - 0x77df2000      C:\WINDOWS\system32\SHLWAPI.dll
    0x76290000 - 0x762ad000      C:\WINDOWS\system32\IMM32.DLL
    0x77420000 - 0x77523000      C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.3790.3959_x-ww_D8713E55\comctl32.dll
    0x6d7c0000 - 0x6da10000      C:\Program Files\Java\jre1.6.0_07\bin\client\jvm.dll
    0x76aa0000 - 0x76acd000      C:\WINDOWS\system32\WINMM.dll
    0x7c340000 - 0x7c396000      C:\WINDOWS\system32\MSVCR71.dll
    0x6d270000 - 0x6d278000      C:\Program Files\Java\jre1.6.0_07\bin\hpi.dll
    0x76b70000 - 0x76b7b000      C:\WINDOWS\system32\PSAPI.DLL
    0x6d770000 - 0x6d77c000      C:\Program Files\Java\jre1.6.0_07\bin\verify.dll
    0x6d310000 - 0x6d32f000      C:\Program Files\Java\jre1.6.0_07\bin\java.dll
    0x6d7b0000 - 0x6d7bf000      C:\Program Files\Java\jre1.6.0_07\bin\zip.dll
    0x6d570000 - 0x6d583000      C:\Program Files\Java\jre1.6.0_07\bin\net.dll
    0x71c00000 - 0x71c17000      C:\WINDOWS\system32\WS2_32.dll
    0x71bf0000 - 0x71bf8000      C:\WINDOWS\system32\WS2HELP.dll
    0x71b20000 - 0x71b61000      C:\WINDOWS\system32\mswsock.dll
    0x5f270000 - 0x5f2ca000      C:\WINDOWS\system32\hnetcfg.dll
    0x71ae0000 - 0x71ae8000      C:\WINDOWS\System32\wshtcpip.dll
    0x76ed0000 - 0x76efa000      C:\WINDOWS\system32\DNSAPI.dll
    0x76f70000 - 0x76f77000      C:\WINDOWS\System32\winrnr.dll
    0x76f10000 - 0x76f3e000      C:\WINDOWS\system32\WLDAP32.dll
    0x76f80000 - 0x76f85000      C:\WINDOWS\system32\rasadhlp.dll
    0x4a6a0000 - 0x4a6ac000      C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\MMI\WEB-INF\lib\CustomerInfoProxy.dll
    0x77670000 - 0x777a9000      C:\WINDOWS\system32\ole32.dll
    0x77d00000 - 0x77d8b000      C:\WINDOWS\system32\OLEAUT32.dll
    0x7c420000 - 0x7c4a7000      C:\WINDOWS\WinSxS\x86_Microsoft.VC80.CRT_1fc8b3b9a1e18e3b_8.0.50727.4053_x-ww_E6967989\MSVCP80.dll
    0x78130000 - 0x781cb000      C:\WINDOWS\WinSxS\x86_Microsoft.VC80.CRT_1fc8b3b9a1e18e3b_8.0.50727.4053_x-ww_E6967989\MSVCR80.dll
    0x777b0000 - 0x77833000      C:\WINDOWS\system32\CLBCatQ.DLL
    0x77010000 - 0x770d6000      C:\WINDOWS\system32\COMRes.dll
    0x77b90000 - 0x77b98000      C:\WINDOWS\system32\VERSION.dll
    0x75da0000 - 0x75e5d000      C:\WINDOWS\system32\SXS.DLL
    0x75e60000 - 0x75e87000      C:\WINDOWS\system32\apphelp.dll
    0x4dc30000 - 0x4dc5e000      C:\WINDOWS\system32\msctfime.ime
    0x4b0d0000 - 0x4b395000      C:\WINDOWS\system32\xpsp2res.dll
    0x71bb0000 - 0x71bb9000      C:\WINDOWS\system32\WSOCK32.dll
    0x4bbe0000 - 0x4bbea000      C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\MMI\WEB-INF\lib\ClearTranProxy.dll
    0x745e0000 - 0x7489e000      C:\WINDOWS\system32\msi.dll
    0x71c40000 - 0x71c97000      C:\WINDOWS\system32\NETAPI32.dll
    0x4bc50000 - 0x4bc6c000      C:\WINDOWS\system32\DBNETLIB.DLL
    0x71f60000 - 0x71f64000      C:\WINDOWS\system32\security.dll
    0x76c90000 - 0x76cb7000      C:\WINDOWS\system32\msv1_0.dll
    0x76cf0000 - 0x76d0a000      C:\WINDOWS\system32\iphlpapi.dll
    0x761b0000 - 0x76243000      C:\WINDOWS\system32\crypt32.dll
    0x76190000 - 0x761a2000      C:\WINDOWS\system32\MSASN1.dll
    0x4bcf0000 - 0x4bcff000      C:\Program Files\Common Files\System\Ole DB\SQLOLEDB.RLL
    0x4a8a0000 - 0x4a8aa000      C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\MMI\WEB-INF\lib\MIGI.DLL
    0x73570000 - 0x736c2000      C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\MMI\WEB-INF\lib\MSVBVM60.DLL
    0x4a950000 - 0x4a9e2000      C:\Program Files\Common Files\System\ado\msado15.dll
    0x74a50000 - 0x74a6a000      C:\WINDOWS\system32\MSDART.DLL
    0x4c850000 - 0x4c8c9000      C:\Program Files\Common Files\System\Ole DB\oledb32.dll
    0x4dbb0000 - 0x4dbc1000      C:\Program Files\Common Files\System\Ole DB\OLEDB32R.DLL
    VM Arguments:
    jvm_args: -Dcatalina.home=C:\Program Files\Apache Software Foundation\Tomcat 5.5 -Dcatalina.base=C:\Program Files\Apache Software Foundation\Tomcat 5.5 -Djava.endorsed.dirs=C:\Program Files\Apache Software Foundation\Tomcat 5.5\common\endorsed -Djava.io.tmpdir=C:\Program Files\Apache Software Foundation\Tomcat 5.5\temp -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Djava.util.logging.config.file=C:\Program Files\Apache Software Foundation\Tomcat 5.5\conf\logging.properties -Djava.library.path=C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\MMI\WEB-INF\lib vfprintf -Xms512m -Xmx1024m
    java_command: <unknown>
    Launcher Type: generic
    Environment Variables:
    JAVA_HOME=C:\Program Files\Java\jdk1.6.0_07
    [error occurred during error reporting (printing environment variables), id 0xc0000005]
    --------------- S Y S T E M ---------------
    OS: Windows Server 2003 family Build 3790 Service Pack 2
    CPU:total 4 (4 cores per cpu, 1 threads per core) family 6 model 7 stepping 6, cmov, cx8, fxsr, mmx, sse, sse2, sse3, ssse3
    Memory: 4k page, physical 2097151k(2097151k free), swap 4194303k(4194303k free)
    vm_info: Java HotSpot(TM) Client VM (10.0-b23) for windows-x86 JRE (1.6.0_07-b06), built on Jun 10 2008 01:14:11 by "java_re" with MS VC++ 7.1
    time: Mon Dec 28 15:24:00 2009
    elapsed time: 600 seconds

  • JVM 1.4.2 crash "access violation" Tomcat

    Hi
    We're getting nasty crashes with JVM 1.4.2_03 (other versions not yet been able to test) and cannot seem to find any log file with more information. However, I do have a DrWatson log which states among other things "access violation".
    Situation: We're testing a webapplication on Tomcat (runs as a Windows service (Tomcat.exe) ). During testing the Tomcat-service suddenly ends, the Windows eventlog logs states something like: "...service ended unexpectedly..."
    Environment: Tomcat 4.1.29, JDK 1.4.2_03, Windows 2000ProSP4, bi-processor Xeon machine.
    While analyzing the DrWatson log file, I can always find the same important (I think) information in the same order:
    - function: NtReadFile
    - a bit further on: function: NtWaitForMultipleObjects
    - function: NtWaitForSingleObject
    - etc..
    Other snippets I can also find every time are texts like these, they appear in the so called "Stack Back Trace"-sections of the drwtsn32.log:
    !JVM_RegisterUnsafeMethods,
    !JVM_RegisterPerfMethods,
    ntdll!NtDelayExecution,
    kernel32!Sleep,
    !JVM_Sleep,
    msafd!WSPSetSockOpt,
    ws2_32!WSAAccept,
    ws2_32!accept,
    ws2_32!recv,
    !Java_java_net_SocketInputStream_socketRead0.
    If needed I can post the complete drwtsn32.log file, I only left it out because it's a bad practice to dump long texts. So if you want to take a look, please don't hesitate to ask !
    The problem only seems to occur when the servermachine is completely left alone (and not logged in or in locked state) Additionally, it usually occurs after between 30-60 minutes or so. When I keep monitoring (logged in) the machine while the tests are running the crash doesn't seem to occur ?! This makes me think it could be an issue with power-saving that kicks in, like e.g. with the network-adaptor ?
    If we don't use JNI, and "access violation"s are stated, does this mean it's a JVM-issue or ... ? Or is it more likely it's an issue of this Tomcat.exe ?
    On a sidenote, does anyone know why a logfile might not be produced, and if there is anything i could try to make the jvm produce some intelligable output upon crashing?
    Kind regards,
    David

    Hi again,
    First of all thanks for the valuable help so far !
    As I'm still searching an anwser for the problem, I noticed the drwtsn32.log file also (sometimes) mentions HotSpot, this is a line from my drwtsn32.log file:
    mov ecx,[gHotSpotVMLongConstantEntryValueOffset+0x13f48[/i]
    Now, I'm not an expert on HotSpot, but I too know there have been numerous problems reported before with this technology.
    Ramesh, it sure looks like your hypothesis about the runtime compilation corresponds to this problem a lot.
    Additionally, I must also mention the fact that the problem only seems to occur during stress-tests (concurrency-problem?) and is NOT reproducable reliably. All of this makes me think even more that it's a JVM problem of some kind, what is your (anyone) opinion about this ?
    Again, thanks for your support, it sure helps a lot !
    Kind regards,
    David

  • ACCESS VIOLATION calling SQLPEX - SQLLIBSHRA.EXE

    This is a problem for OpenVMS / Oracle Experts
    I have quit an old large legacy system to integrate - actually migrating away from a CORBA based communication backbone to a webservice AXIS2/Java based backbone using HP's WSIT e all, and yes - this legacy uses an old Oracle 7.3
    The OS is HP OpenVMS / Alpha V 7.3-n,
    When I link all my native code together the process launched through Java JNI is a "NETWORK" detached process which should do a DB_Connect via SQLPEX (ctx, sqlstm );
    The layers involved are like that; AXIS2/J webservice -> WSIT-javaBean ->
    JVM -> JNI -> SPg-Server.c (an wsit outer-wrapper) -> SPg-Legacy.c(my inner wrapper) -> SPS_WRAPPER.PAS (the inner-most wrapper / dispatcher) -> Business-logic-*.PAS -> DataBaseAccess.PAS
    (the database access code was generated by LNPROPAS from statements like EXEC SQL CONNECT .... etc.)
    When I exchange my SPS_WRAPPER.PAS WRAP() by a TestWrapper.PAS WRAP() which bypasses all business logic, SQLPEX(ctx, sqlstm); works perfectly and the database opens, in fact, a new detached second process is launched as ORA_nnnnn and my detached integrated web service process communicates nicely via MailBox Devices.
    However when I link in my original legacy code, LINK is fine, and all my business code runs fine when it gets called from the WRAP(), BUT I get an ACCESS VIOLATION as soon as SQLPEX() is called to connect to the Database.
    I can not debug because the code which does the access violation, for what ever reason, is in SQLLIBSHRA.EXE, and invoked when I call sqlpex( ctx, sqlstm )
    Maybe there is ONLY a resource problem, but why then an ACCESS VIOLAITION and yes, which resource to we have to make bigger. SYSGEN Parameters, autogen feedback did not help.
    I am not an Oracle Expert, so I do not know what and how I can make ORACLE tracing and logging and show me why I get this acess violation in a pice of code which runs nicely since 10 years in a CORBA environment, also runs nicely when my business logic is bypassed.
    And yes: ORA_ROOT:[000000.NETWORK.ADMIN]ORASRV_BEQ_A.COM
    is not hit / called when it comes to the access violation.
    Any hints are welcome before I have to jump into machine code debugging without a source listing.
    [email protected]

    This problem was caused by a user-stack-heap-code-collision
    PTHREAD applications may not do aoutomatic stack size expansions on a per thread basis and hence an access violation deep in long-time-running code is very likely to occure. (code which does not belong to YOU, for which you know it runs basically since 10 years, which migth not be supported any longer by the vendor)
    solution: WSIT (webservice integration toolkit) by default assignes 30000 bytes for each threads user-stack-size, can be adjusted in the .WSI deployment descriptor file; Now running at 60'000. WSIT V3.0 will allow for single threaded legacy server integration and have a automatic stack size expansion supported when running in this mode. (as per HP)
    [email protected]

  • AV when using JNI

    Hi,
    We have faced a problem that is very similar to the one reported in this thread:
    http://forums.bea.com/bea/message.jspa?messageID=200010160&tstart=0
    Has the problem been fixed in a later release?
    We are using BEA JRockit 5.0 R26.4.0-63 under Windows XP Professional 32-bit SP2 and still get Access Violations when using java.lang.Class.getDeclaredMethods() or java.lang.Class.getDeclaredFields(). The exception does not occur when we use the same module with Sun JVM and MS JVM.
    If the problem is supposed to be fixed, I can provide more details.
    Best regards,
    Alex
    ~~~~~~~~~~~~~~~~~~~~~

    Hello Staffan,
    Thanks for your reply. Here is a description of the first problem we have faced:
    When using JNI to call the java.lang.Class.getDeclaredMethods() or java.lang.Class.getDeclaredFields() method, we get the java.lang.NullPointerException exception in some cases. If we debug the java.exe process in Visual Studio 2005, we can see that the following exception occurs:
    First-chance exception at 0x7d612b73 in java.exe: 0xC0000005: Access violation reading location 0x00000010.
    Here is a part of the exception call stack:
    7d612b73()
    jvm.dll!_stubsCallC2JavaStub() + 0x24 bytes
    jvm.dll!_callC2Java() + 0x309 bytes
    jvm.dll!_jniCheckExceptionsForCall() + 0x12e bytes
    jvm.dll!_jniCallObjectMethodA@16() + 0x3b bytes
    jvm.dll!_jniGetVersion@4() + 0x993 bytes
    tcJavaHook.dll!JNIEnv_::CallObjectMethodA(_jobject * obj=0x34960204, _jmethodID * methodID=0x77b84b08, const jvalue * args=0x00000000)  Line 879 + 0x1f bytes C++
    We have done some investigations and found out that the problem occurs for the following classes:
    java.lang.Class, javax.swing.JPanel, javax.swing.JLayeredPane, javax.swing.JToolBar, javax.swing.AbstractButton, javax.swing.JLabel,
    javax.swing.JScrollPane, javax.swing.JViewport, javax.swing.JTable, javax.swing.CellRendererPane, javax.swing.JScrollBar, javax.swing.table.JTableHeader, javax.swing.JMenuBar, javax.swing.JComboBox, javax.swing.JSpinner, javax.swing.text.JTextComponent
    While the exception does not occur when calling methods of the following classes:
    javax.swing.JFrame, java.awt.Frame, javax.swing.JComponent, javax.swing.JRootPane, java.lang.Object, java.awt.Component, java.awt.Container, java.awt.Window, java.awt.Dialog, javax.swing.JDialog
    We were able to reproduce the problem with Eclipse 3.1.2 launched in the following way:
    I:\Java\jrockit-R26.4.0-jdk1.5.0_06\jre\bin\java.exe -Xms40m -Xmx256m -jar D:\Eclipse\startup.jar -os win32 -ws win32 -arch x86 -launcher D:\Eclipse\eclipse.exe -name Eclipse -showsplash 600 -exitdata 14a8_60 -vm I:\Java\jrockit-R26.4.0-jdk1.5.0_06\jre\bin\java.exe -vmargs -Xms40m -Xmx256m -jar D:\Eclipse\startup.jar
    I:\Java\jrockit-R26.4.0-jdk1.5.0_06\ - the installation folder of JRockit JDK
    D:\Eclipse\ - the root folder of Eclipse
    In this case, even trying to get information about the java.lang.Object class fields and methods causes the problem.
    Can you say anything based on the above call stack?
    Please let me know if you need any details about the problem.
    Best regards,
    Alex
    ~~~~~~~~~~~~~~~~~~~~~

  • Need help to access a web page using midlet to retrieve some informations

    Hi everyone i'm trying to access a web page using midlet to retrieve some informations in text format, the web page is [http://daviddurand.info/D228/?villes|http://daviddurand.info/D228/?villes] for my project.
    the problem is that i always get error 10049 in socket::open meaning no adresse could be found i tried IP adresse and still the same.
    i managed to recreate the same web page to test it on local and the surprise that it works fine but when accessing it online i have this error.
    i tried also to get the page i created on a webserver i own to try it saying that there might be security issues but the same error appears again. so help plz
    here is my code :
    package mobileapplication5;
    import java.io.*;
    import javax.microedition.io.*;
    import javax.microedition.lcdui.*;
    import javax.microedition.midlet.*;
    public class GetMidlet extends MIDlet {
    private Display display;
    String url = "http://dayaati.com/villes/index.php?villes";
    public GetMidlet() {
    display = Display.getDisplay(this);
    public void startApp() {
    try {
    getBirthdayFromNameUsingGet(url);
    } catch (IOException e) {
    System.out.println("IOException " + e);
    e.printStackTrace();
    public void pauseApp() {   }
    public void destroyApp(boolean unconditional) {  }
    public void getBirthdayFromNameUsingGet(String url) throws IOException {
              HttpConnection httpConn = null;
              InputStream is = null;
              OutputStream os = null;
              try {
    httpConn = (HttpConnection)Connector.open(url);
    httpConn.setRequestProperty("User-Agent", "Profile/MIDP-2.1 Configuration/CLDC-1.1");
    httpConn.setRequestProperty("Content-Language", "en-US" );
    httpConn.setRequestProperty("Content-Type", "text/html; charset=iso-8859-1");
    httpConn.setRequestProperty( "Connection", "keep-alive" );
    httpConn.setRequestProperty("Content-Length","51200");
              getConnectionInformation(httpConn);
              int respCode = httpConn.getResponseCode();
              if (respCode == httpConn.HTTP_OK) {
                   StringBuffer sb = new StringBuffer();
                   os = httpConn.openOutputStream();
                   is = httpConn.openDataInputStream();
                   int chr;
                   while ((chr = is.read()) != -1)
                   sb.append((char) chr);
                   // Web Server just returns the birthday in mm/dd/yy format.
                   System.out.println(sb.toString());
              else {
                   System.out.println("Error in opening HTTP Connection. Error#" + respCode);
              } finally {
                   if(is!= null)
                   is.close();
                   if(os != null)
                        os.close();
              if(httpConn != null)
                        httpConn.close();
    void getConnectionInformation(HttpConnection hc) {
    System.out.println("Request Method for this connection is " + hc.getRequestMethod());
    System.out.println("URL in this connection is " + hc.getURL());
    System.out.println("Protocol for this connection is " + hc.getProtocol());
    System.out.println("This object is connected to " + hc.getHost() + " host");
    System.out.println("HTTP Port in use is " + hc.getPort());
    System.out.println("Query parameter in this request are " + hc.getQuery());
    **Heeeeeeelp Please**

    [http://java.sun.com/javase/6/webnotes/trouble/TSG-VM/html/crashes.html]
    SIGSEGV (0xb)Most common cause of that is JNI code used directly or indirectly through a 3rd party library.
    64-Bit Server VM (11.2-b01 mixed mode linux-amd64)Conversely that VM gets less traffic than others so you might have hit a bug in it.

  • How can I repair "an access violation has occurred"

    I found this message after you install the update of an audio software (Pro Tools 8.0.5) and after trying to listen to an audio recording "an access violation has occurred." In a later appeared to me the message "/ System / Library / Extensions / CDSDAAudioCaptureSupport.Kext". I removed the software completely reinstalled all audio and I havethe previous version but to no avail. I also reinstalled operating system from OS 10.6.2 Leopard up to 10.6.8 but still nothing. The message reappears when I use the audio software is not allowing me to listen to the audio (only with ProTools, while iTunes feature regularly. I do not know what to do yet.

    Linc Davis wrote:
    It's the PACE DRM rootkit that's installed along with the Pro Tools application. Its purpose is to cripple your computer so that you can only do what the developer chooses to let you do. If you have a problem with that, you'll have to take it up with DigiDesign, or get rid of their product.
    Most absurd response to a question I have ever read...
    DRM protects composers life myself from theft. I just hate it when people steal my stuff. Don't you?
    I've  been a PT professional user for well over a decade. My computer is in no way "crippled". I can do what I want with it and what I want with that software. I run PT with iTunes open all day long with no issue. I can import audio from my iTunes library into PT with no issue. If the audio you are trying to import is protected (from being stolen and remixed etc.) than no, you can't import it into PT. I'm pretty sure that most law abiding citizens would agree that having thier own personal livelyhood protected under law would be a good thing. But for some reason, this society thinks that musicians and other creative professionals don't deserve the same level of protection and don't need to feed thier families...

  • Deploying a WAR file containing .jsp and servlets (also uses JNI)

    Deploying a WAR file containing .jsp and servlets (also uses JNI) on Windows 2000
    We had problems making it initially work on Sun ONE Web Server 6.0 Service Pack 1 because of lack of good iPlanet Web
    Server documentation on deploying such files.
    This is how we went about it:
    1) Make one of the servlet and JSP (must call another Java Class) web application (.war) examples work with iPlanet Web
    Server.
    C:\iPlanet\Servers\plugins\servlets\examples\web-apps\HelloWorld\HelloWorld.war
    and
    C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    a) Go to your Web Server Administration to deploy the application using GUI Web Application Deploy.
    (We usually use command line, we experienced some issues with the GUI version, but maybe it is fixed in the new Web Server
    service packs)
    From browser, open http://yourserver:8888/
    Click on Select a Server:Manage
    Click on Virtual Server Class
    Click on https-yourserver
    Click on the Web Applications Tab
    Then, click on Deploy Web Application
    Enter the following -
    WAR File On: Local
    WAR File Path: C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    Application URI: /jakarta
    Installation Directory: c:\iPlanet\examples\jakarta-examples
    By clicking on OK it deployed the application.
    I can verify that it is deployed by selecting "Edit Web Applications" and I see the following entry:
    Edit     /jakarta     c:/iPlanet/examples/jakarta-examples
    Also, c:/iPlanet/examples/jakarta-examples should have the similar following directory structure ..
    - [images]
    - [jsp]
    - index.html
    - [servlets]
    - [META-INF]
    - [WEB-INF]
    - [classes]
    - [tlds]
    - web.xml
    - index.html
    I restarted the server and accessed it using the following URL from my IE browser:
    http://yourserver/jakarta/index.html
    Then I clicked on the JSP Examples and tried some JSP examples.
    b) Alternatively, you can also deploy the same example from the command-line.
    Make sure C:\iPlanet\Servers\bin\https\httpadmin\bin\ is in your path
    wdeploy deploy      -u /jakarta
              -i yourserver
              -v https-yourserver
              -d c:\iplanet\examples\jakarta-examples
              C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    Restart the web server (I don't think you have to restart, but .. might as well).
    2)Deploy your web-application
    My Foo.war has the following structure.
    You can use jar tf Foo.war to look at the file contents from command line (assuming you have JDK installed and the bin is
    in your PATH)
    Foo.war
    - [META-INF]
    - [WEB-INF]
    - web.xml
    - [classes]
    - Bar.class
    - MoServlet.class
    - [lib]
    - ThirdParty.jar
    - [natlib]
    - extlib.dll
    - foo.jsp
    Here is our application scenario:
    foo.jsp uses a class call Bar (it is not in any package). The Bar java class uses classes from ThirdParty.jar. The
    ThirdParty.jar in turn uses JNI to load library extlib.dll. foo.jsp also calls /servlet/Mo as well.
    Now to deploy it, do the following:
    (a) Make sure that within foo.jsp, you import the Bar class ( I don't know why you have to do it, but if you don't you get
    JSP compile error).
    <%@page language="java" import="Bar" contentType="text/html"%>
    (b) Check web.xml (for Servlets)
    Within web.xml, make sure you have the following mappings:
    <servlet>
    <servlet-name> MoLink </servlet-name>
    <servlet-class> MoServlet </servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name> MoLink </servlet-name>
    <url-pattern> /servlet/Mo </url-pattern>
    </servlet-mapping>
    (c) Deploy the application
    Using command line:
    wdeploy deploy      -u /foo
              -i yourserver
              -v https-yourserver
              -d c:\iplanet\examples\foo-dir
              Foo.war
    (d) Change web-apps.xml file (for picking up ThirdParty.jar)
    It is located in
    C:\iPlanet\Servers\https-yourserver\config
    You should see something similar to following after successful deployment.
    <web-app uri="/foo" dir="C:\iPlanet\examples\foo-dir" enable="true"/>
    Change it to look like following to pick up the ThirdParty.jar
    <web-app uri="/foo" dir="C:\iPlanet\examples\foo-dir" enable="true">
    <class-loader reload-interval="300"
              classpath="C:/iPlanet/examples/foo-dir/WEB-INF/lib/ThirdParty.jar"
              delegate="false"/>
    </web-app>
    (e) Change jvm12.conf file (for JNI)
    It is located in
    C:\iPlanet\Servers\https-yourserver\config
    Add or uncomment the following lines:
    #optional - just helps with instrumenting the jsp and servlet code
    jvm.include.CLASSPATH=1
    jvm.enableDebug=1
    nes.jsp.enabledebug=1
    jvm.trace=7
    jvm.verboseMode=1
    #required for JNI
    java.compiler=NONE
    jvm.classpath=.;C:\JDK1.3.1\lib\tools.jar;C:/iPlanet/Servers/plugins/servlets/examples/legacy/beans.10/SDKBeans10.jar;
    jvm.option=-Xrs
    jvm.option=-Xnoagent
    # not sure if this is needed for iPlanet web server
    jvm.option=-Djava.library.path=C:/iPlanet/examples/foo-dir/natlib/ -Djava.compiler=NONE
    (f) Change magnus.conf file (for JNI)
    We HAD to change this file in order for ThirdParty.jar file to pick up the native C++ code using JNI. Apparently, the
    iPlanet Web Server doesn't pick the Environment Variable Path. Because when we had the directory containing the DLL just
    in Path, it didn't work.
    Change Extrapath directive:
    ExtraPath C:/iPlanet/Servers/bin/https/bin;${NSES_JRE_RUNTIME_LIBPATH}
    to
    ExtraPath c:/iPlanet/examples/foo-dir/natlib;C:/iPlanet/Servers/bin/https/bin;${NSES_JRE_RUNTIME_LIBPATH}
    (g) Apply changes from the Web Server Administration Console and Restart the web server.
    You should be able to see the behaviour that you want from your application.
    http://yourserver/foo/foo.jsp
    Hope this was helpful!!!
    Sonu

    Deploying a WAR file containing .jsp and servlets (also uses JNI) on Windows 2000
    We had problems making it initially work on Sun ONE Web Server 6.0 Service Pack 1 because of lack of good iPlanet Web
    Server documentation on deploying such files.
    This is how we went about it:
    1) Make one of the servlet and JSP (must call another Java Class) web application (.war) examples work with iPlanet Web
    Server.
    C:\iPlanet\Servers\plugins\servlets\examples\web-apps\HelloWorld\HelloWorld.war
    and
    C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    a) Go to your Web Server Administration to deploy the application using GUI Web Application Deploy.
    (We usually use command line, we experienced some issues with the GUI version, but maybe it is fixed in the new Web Server
    service packs)
    From browser, open http://yourserver:8888/
    Click on Select a Server:Manage
    Click on Virtual Server Class
    Click on https-yourserver
    Click on the Web Applications Tab
    Then, click on Deploy Web Application
    Enter the following -
    WAR File On: Local
    WAR File Path: C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    Application URI: /jakarta
    Installation Directory: c:\iPlanet\examples\jakarta-examples
    By clicking on OK it deployed the application.
    I can verify that it is deployed by selecting "Edit Web Applications" and I see the following entry:
    Edit     /jakarta     c:/iPlanet/examples/jakarta-examples
    Also, c:/iPlanet/examples/jakarta-examples should have the similar following directory structure ..
    - [images]
    - [jsp]
    - index.html
    - [servlets]
    - [META-INF]
    - [WEB-INF]
    - [classes]
    - [tlds]
    - web.xml
    - index.html
    I restarted the server and accessed it using the following URL from my IE browser:
    http://yourserver/jakarta/index.html
    Then I clicked on the JSP Examples and tried some JSP examples.
    b) Alternatively, you can also deploy the same example from the command-line.
    Make sure C:\iPlanet\Servers\bin\https\httpadmin\bin\ is in your path
    wdeploy deploy      -u /jakarta
              -i yourserver
              -v https-yourserver
              -d c:\iplanet\examples\jakarta-examples
              C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    Restart the web server (I don't think you have to restart, but .. might as well).
    2)Deploy your web-application
    My Foo.war has the following structure.
    You can use jar tf Foo.war to look at the file contents from command line (assuming you have JDK installed and the bin is
    in your PATH)
    Foo.war
    - [META-INF]
    - [WEB-INF]
    - web.xml
    - [classes]
    - Bar.class
    - MoServlet.class
    - [lib]
    - ThirdParty.jar
    - [natlib]
    - extlib.dll
    - foo.jsp
    Here is our application scenario:
    foo.jsp uses a class call Bar (it is not in any package). The Bar java class uses classes from ThirdParty.jar. The
    ThirdParty.jar in turn uses JNI to load library extlib.dll. foo.jsp also calls /servlet/Mo as well.
    Now to deploy it, do the following:
    (a) Make sure that within foo.jsp, you import the Bar class ( I don't know why you have to do it, but if you don't you get
    JSP compile error).
    <%@page language="java" import="Bar" contentType="text/html"%>
    (b) Check web.xml (for Servlets)
    Within web.xml, make sure you have the following mappings:
    <servlet>
    <servlet-name> MoLink </servlet-name>
    <servlet-class> MoServlet </servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name> MoLink </servlet-name>
    <url-pattern> /servlet/Mo </url-pattern>
    </servlet-mapping>
    (c) Deploy the application
    Using command line:
    wdeploy deploy      -u /foo
              -i yourserver
              -v https-yourserver
              -d c:\iplanet\examples\foo-dir
              Foo.war
    (d) Change web-apps.xml file (for picking up ThirdParty.jar)
    It is located in
    C:\iPlanet\Servers\https-yourserver\config
    You should see something similar to following after successful deployment.
    <web-app uri="/foo" dir="C:\iPlanet\examples\foo-dir" enable="true"/>
    Change it to look like following to pick up the ThirdParty.jar
    <web-app uri="/foo" dir="C:\iPlanet\examples\foo-dir" enable="true">
    <class-loader reload-interval="300"
              classpath="C:/iPlanet/examples/foo-dir/WEB-INF/lib/ThirdParty.jar"
              delegate="false"/>
    </web-app>
    (e) Change jvm12.conf file (for JNI)
    It is located in
    C:\iPlanet\Servers\https-yourserver\config
    Add or uncomment the following lines:
    #optional - just helps with instrumenting the jsp and servlet code
    jvm.include.CLASSPATH=1
    jvm.enableDebug=1
    nes.jsp.enabledebug=1
    jvm.trace=7
    jvm.verboseMode=1
    #required for JNI
    java.compiler=NONE
    jvm.classpath=.;C:\JDK1.3.1\lib\tools.jar;C:/iPlanet/Servers/plugins/servlets/examples/legacy/beans.10/SDKBeans10.jar;
    jvm.option=-Xrs
    jvm.option=-Xnoagent
    # not sure if this is needed for iPlanet web server
    jvm.option=-Djava.library.path=C:/iPlanet/examples/foo-dir/natlib/ -Djava.compiler=NONE
    (f) Change magnus.conf file (for JNI)
    We HAD to change this file in order for ThirdParty.jar file to pick up the native C++ code using JNI. Apparently, the
    iPlanet Web Server doesn't pick the Environment Variable Path. Because when we had the directory containing the DLL just
    in Path, it didn't work.
    Change Extrapath directive:
    ExtraPath C:/iPlanet/Servers/bin/https/bin;${NSES_JRE_RUNTIME_LIBPATH}
    to
    ExtraPath c:/iPlanet/examples/foo-dir/natlib;C:/iPlanet/Servers/bin/https/bin;${NSES_JRE_RUNTIME_LIBPATH}
    (g) Apply changes from the Web Server Administration Console and Restart the web server.
    You should be able to see the behaviour that you want from your application.
    http://yourserver/foo/foo.jsp
    Hope this was helpful!!!
    Sonu

  • Error Occuring While Processing Data With DIAdem 8.1Excepti​on EAccessVio​lation in module ntdll.dll at 000111DE. Access violation at address 7C9111DE in module 'ntdll.dll​". Read address 37363430

    Hello,
    We are having an issue running Diadem 8.1 on a new HP XW 9400 with Windows XP SP2. 3 errors have been occuring with frequent crashes, they are:
    1) "1Exception EAccessViolation in module ntdll.dll at 000111DE. Access violation at address 7C9111DE in module 'ntdll.dll". Read address 37363430.
    2) The instruction at "0x7c9111de" referenced memory at "0x352e302d". The memory could not be "read".
     3) ---Error---   DIAdem
    Error in Autosequence - processing in line: 74 (IARV_VAR_GET)
    Runtime Error while executing command "Iarv2Txt$ := FR(T9,L1)"
    Error type: ACCESS VIOLATION
    Error address: 000101DE
    Module name:ntdll.dll
    We are using the same scripts and version 8.1 on a variety of Dell desktop computers (W2K and XP SP2) without any issue, looking for suggestions as this affects no other software on the HP XW 9400 other than DIAdem. Appreciate any suggestions.
    Message Edited by swillh on 06-25-2007 08:55 AM

    Christian,
    I will answer your questions in the text below. Thanks for your help.
    Hi swillh,
    I also would like to help you.
    Unfortunately, The reported access violation in the central Windows ntdll.dll is very unspecific.
    May be the following questions will help you to provide me more info.
    1. You mentioned that the aut's and - I think - also the accessed text file reside on a server.
    Is there a stable network connection?
    The server can sometimes be a little slow but the connection is good. This computer is using the same connection that the prior computer utilized without issue.
    Are the files accessed by multiple clients simultaneously?
    It is possible that more than one computer can be accessing the same file, but again, this has never been an issue. We are reading the files only, not writing to them.
    The processing routines we are running have used for over 5 years without any issues until adding this computer.
    Is the text file read by one client while another client is writing the same file?
    No, files are "read only"
    2. Have you already tested opening the file with the FileOpen command before calling FR?
    Yes
    Do you see any chance to convert the aut to a vbs file? This gives you more alternatives in accessing text files.
    3. What do you mean with "processing ATD's with 30 or more channels of data"? Where is the relation between ATD files and data channels?
    Processing Crash Dummy data with file sets low in channel count (15 channels) result in successful processing without any crashes or access errors.  When processing dummies with more than 20 channels we sometimes encounter these issues. The higher channel count may be the only common factor I can find in these faults.
    Steve
    Message Edited by swillh on 07-09-2007 08:44 AM

  • Error while executing "" command Error type ACCESS VIOLATION Error Address: 0006898E Module name:gfsdesk.DLL

    Hi All,
    I'm using diadem from .net Program. While on the run I'm getting the following error.
    Error While executing "" Command
    Error type ACCESS VIOLATION
    Error Address: 0006898E
    Module name:gfsdesk.DLL
    Anyone have any idea why this is happening?
    regards,
    Swaroop

    Hi Swaroop,
    It would be helpful to better understand what your code really does. The information that you called DIAdem from your enviroenment is not yet sufficient to understand what the problem might be.
    Andreas

Maybe you are looking for