ODM and JNI - Aix

This is a discussion on ODM and JNI - Aix ; I am trying to access the system configuration database via the ODM C functions called from JNI. My standalone program works fine, but when I try the same code under JNI, it instantly crashes at the fist ODM function call. ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: ODM and JNI

  1. ODM and JNI

    I am trying to access the system configuration database via the ODM C
    functions called from JNI. My standalone program works fine, but when
    I try the same code under JNI, it instantly crashes at the fist ODM
    function call. It seems to be dieing on the call, not in the function
    which leads me to believe that maybe -lodm isn't compiled
    appropriately to be be called from JNI? The stack traces look like
    this:

    (dbx) where
    pthread_kill(??, ??) at 0xd0128470
    _p_raise(??) at 0xd0127f08
    raise.raise(??) at 0xd0315740
    abort.abort() at 0xd0344ca8
    j9dump_create() at 0xd2439cfc
    doSystemDump() at 0xd2461528
    protectedDumpFunction() at 0xd2461b20
    j9sig_protect() at 0xd24381cc
    runDumpFunction() at 0xd2462f7c
    triggerDumpAgents_30_26() at 0xd246b768
    dumpCrashData() at 0xd23e71dc
    j9sig_protect() at 0xd24381cc
    structuredSignalHandler() at 0xd23e74cc
    masterSynchSignalHandler() at 0xd2438420
    ..() at 0x0
    CpuInfoAIX.CpuInfoInitializeCacheFunction(), line 75 in "CpuInfoAIX.c"

    Where that line is: path=odm_set_path("/etc/objrepos");

    the code is properly encased in a pthread mutex, and I have lots of
    other JNI code that is work. I'm using the _r variants of the xlc
    compilers, and I have these env vars set:

    AIXTHREAD_SCOPE=S
    AIXTHREAD_MUTEX_DEBUG=OFF
    AIXTHREAD_RWLOCK_DEBUG=OFF
    AIXTHREAD_COND_DEBUG=OFF
    export AIXTHREAD_SCOPE AIXTHREAD_MUTEX_DEBUG AIXTHREAD_RWLOCK_DEBUG
    AIXTHREAD_CO
    ND_DEBUG

    Any ideas?

    Evan


  2. Re: ODM and JNI

    On May 26, 12:45 pm, ejb...@yahoo.com wrote:
    > I am trying to access the system configuration database via the ODM C
    > functions called from JNI. My standalone program works fine, but when
    > I try the same code under JNI, it instantly crashes at the fist ODM
    > function call. It seems to be dieing on the call, not in the function
    > which leads me to believe that maybe -lodm isn't compiled
    > appropriately to be be called from JNI? The stack traces look like
    > this:
    >
    > (dbx) where
    > pthread_kill(??, ??) at 0xd0128470
    > _p_raise(??) at 0xd0127f08
    > raise.raise(??) at 0xd0315740
    > abort.abort() at 0xd0344ca8
    > j9dump_create() at 0xd2439cfc
    > doSystemDump() at 0xd2461528
    > protectedDumpFunction() at 0xd2461b20
    > j9sig_protect() at 0xd24381cc
    > runDumpFunction() at 0xd2462f7c
    > triggerDumpAgents_30_26() at 0xd246b768
    > dumpCrashData() at 0xd23e71dc
    > j9sig_protect() at 0xd24381cc
    > structuredSignalHandler() at 0xd23e74cc
    > masterSynchSignalHandler() at 0xd2438420
    > .() at 0x0
    > CpuInfoAIX.CpuInfoInitializeCacheFunction(), line 75 in "CpuInfoAIX.c"
    >
    > Where that line is: path=odm_set_path("/etc/objrepos");
    >
    > the code is properly encased in a pthread mutex, and I have lots of
    > other JNI code that is work. I'm using the _r variants of the xlc
    > compilers, and I have these env vars set:
    >
    > AIXTHREAD_SCOPE=S
    > AIXTHREAD_MUTEX_DEBUG=OFF
    > AIXTHREAD_RWLOCK_DEBUG=OFF
    > AIXTHREAD_COND_DEBUG=OFF
    > export AIXTHREAD_SCOPE AIXTHREAD_MUTEX_DEBUG AIXTHREAD_RWLOCK_DEBUG
    > AIXTHREAD_CO
    > ND_DEBUG
    >
    > Any ideas?
    >
    > Evan


    What if you export the env var ODMDIR= and then run the same
    using the getenv( ) or equivalent in
    JNI??



+ Reply to Thread