SIGSEGV in multithreaded app with OCI( on Linux

I have got a SIGSEGV in OCI9. Application is multithreaded.
OS Linux. Distribution SLES8. Libc version 2.2.5.
Oracle 9.2.0.5
Application is heavy multithreaded. SIGSEGV occures very rarely. But always in the same place.
Connect code:
static void oracle_init() {
ILock l(m_env);
if (counter++ <= 0)
(void)OCIInitialize(OCI_DEFAULT, 0, NULL, NULL, NULL);
ctor {
oracle_init();
(void)OCIEnvInit(&env, OCI_DEFAULT, 0, NULL);
(void)OCIHandleAlloc(env, (void **)&err, OCI_HTYPE_ERROR, 0, NULL);
connect {
checkerr(err, OCILogon(env, err, &ctx, (text *)const_cast<char *>(user.c_str()), user.len(), (text *)const_cast<char *>(password.c_str()), pass
word.len(), (text *)const_cast<char *>(db.c_str()), db.len()));
/u/app/oracle/product/9.2.0/lib/libclntsh.so.9.0(nlolgobj+0x50f) [0x4044a22d]
/u/app/oracle/product/9.2.0/lib/libclntsh.so.9.0(nnfun2a+0x243) [0x403bc7e3]
/u/app/oracle/product/9.2.0/lib/libclntsh.so.9.0(nnfsn2a+0x66) [0x403bc310]
/u/app/oracle/product/9.2.0/lib/libclntsh.so.9.0(niqname+0x18a) [0x40365a1a]
/u/app/oracle/product/9.2.0/lib/libclntsh.so.9.0(kwfnran+0x11f) [0x402d5df7]
/u/app/oracle/product/9.2.0/lib/libclntsh.so.9.0(kwfcinit+0x177) [0x402a9155]
/u/app/oracle/product/9.2.0/lib/libclntsh.so.9.0(kpuatch+0x834) [0x4014f7d2]
/u/app/oracle/product/9.2.0/lib/libclntsh.so.9.0(kpulon+0x1bc) [0x4015009e]
/u/app/oracle/product/9.2.0/lib/libclntsh.so.9.0(OCILogon+0xd1) [0x401e2167]
Any ideas? Maybe I should initialise OCI with other flags?

OCIInitialize should be called with mode OCI_THREADED instead of OCI_DEFAULT.

Similar Messages

  • How can I build multithread appliccations with forms?

    good afternoon.
    I wish to know how I can build multithread apps with forms. Is it possible? ...
    thanks forward...

    Hi Craig:
    thank you very much. To solve the mystery : ) :
    I want to drive a stepper motor with a specific frequency. To get the current degree value of the motor I would like to measure the current time (from the beginning of the move on). (With a formula I get the degree value out of the time)
    Concurrently I would like to get data from a torque sensor and from a pressure sensor. That's why I asked you about the time and the table. The measurement should start with the movement of the motor. How can I do that? Right now I have different block diagrams (different while loops) (see attachment) and I would like to put them in one.
    I haven't done the block diagram for the pressure sensor yet, so there is only the one for the torque sensor and the one for the motor.
    I also would like to set a mark in the table when the voltage value of an analog input gets under a specific threshold value. Is that possible?
    I'm sorry, I'm a novice in LabVIEW. But maybe you can help me.
    Thank you very much!
    Steffi
    Attachments:
    motor.vi ‏238 KB
    sensor.vi ‏59 KB

  • Multithreaded OCI under linux

    Has anyone used multithreaded OCI under linux? If so could you please tell me how you got this to work. What libraries and settings etc. as this does not seem to be working for me.
    Aaron

    What doesn't work (compile, link, etc)? What errors do you see?

  • Waits with OCI calls

    I have a C++ app which access Oracle DB 10.1.0.4 via OCI from Linux redhat.
    I have extensive waits between the app and the database.
    How can I torubleshoot this problems?
    Etherial show waits on the DB before to send it back to the app. but the execution time for the quesries do not cover the waiting time - like wait 1/2 sec, query runs for 22 millisec.
    How can I figure out what is waiting and why?
    Thanks,mj

    Hi,
    The whole problem is, I don't have access to the code which uses OCI. I cannot modify the code to set CURSOR_SHARING=FORCE, as it is third party code.
    Is it possible to achieve the same with some setting in some configuration file?
    E.g. if you have a glogin.sql file in $ORACLE_HOME/sqlplus/admin, every time you run sqlplus, after you login, this glogin.sql file will be executed automatically
    Is any such thing possible with OCI programs? i.e. when a program using OCI starts running using certain client installation, we want to run some commands.
    If that can be achieved, my problem is sorted.

  • Transactions in Multithreaded app

    Is it safe to use the same java.sql.Connection instance all over multithreaded app? Is transaction session associated with a thread? Or one Connection keeps just one transaction session for all threads?
    Any help's appreciated.

    Is it safe to use the same java.sql.Connection
    instance all over multithreaded app?Yes, providing your access/uses is thread safe, i.e. syncronised.
    Is transaction
    session associated with a thread?No a connection.
    Or one Connection
    keeps just one transaction session for all threads?Yes.
    A transactions should be autonomous, if all threads use the same transaction, it would be pointless using transactions in the first place.
    Any help's appreciated.Checkout these link, your should
    http://developer.java.sun.com/developer/onlineTraining/Programming/JDCBook/bmp.html
    http://developer.java.sun.com/developer/onlineTraining/Programming/JDCBook/jdbc.html
    http://developer.java.sun.com/developer/technicalArticles/xml/metadata/

  • Multithread App !

    Hi Friends,
    I have a multithreaded app that refers stock price and suggest end user upon the availability, as of now it was running as a Swing app. we are thinking of porting it on web. So how can a end user access this Stock price screener using webservices ?
    Here are my challenges :
    1. I cannot deploy it in J2ee Webserver as they are managed environment.
    2. We have not yet migrated to jdk1.6 ( WE WILL DO THAT NEXT YR DEPENDING HOW THE PRODUCT IS PERFORMING)
    So how can this be acheived in a strict(ideal) j2ee environment.
    My boss is strict about J2ee standard, I donot know how to implement this in budget n time ??
    I am really scratching my head about the same for an hour n so I have not find a decent answer on web also. Is it that violting the basic rule of j2ee is the only way out. ("don't sponge a thread in a managed environment" ). I know there are software that are running thread with in like log4j but they have special grant to run not my application.
    thks.s.das

    EJP wrote:
    I would have failed you in the interview for the garrulous verbosity of writing Boolean.TRUE.equals, which can be completely omitted, and Boolean.FALSE.equals, which can be replaced by !.Students learn what in the books, and lot of java books I see using the same style:
    http://books.google.com/books?id=DXYZZVlWOAkC&pg=PA286&dq=Boolean.TRUE.equals%28&hl=en&sa=X&ei=i31sT8jdJonh0QH01-jyBg&ved=0CDIQ6AEwAA#v=onepage&q=Boolean.TRUE.equals%28&f=false
    http://books.google.com/books?id=ppNBCdxxW5AC&pg=PA439&dq=Boolean.TRUE.equals%28&hl=en&sa=X&ei=i31sT8jdJonh0QH01-jyBg&ved=0CD8Q6AEwAg#v=onepage&q=Boolean.TRUE.equals%28&f=false
    Here is more serious mistakes, looks like the book author doesn't understand the difference between Boolean and boolean, Integer and int:
    http://books.google.com/books?id=FPxif81mgYoC&pg=PA219&dq=Boolean.TRUE.equals%28&hl=en&sa=X&ei=i31sT8jdJonh0QH01-jyBg&ved=0CDgQ6AEwAQ#v=onepage&q=Boolean.TRUE.equals%28&f=false
    When you code wrong, you make something wrong for your application, When you teach wrong, you make lot of wrongs .... :D

  • Running OCCI 12.1 with OCI 11.2

    Hi there.
    A quick newbie question: can I compile and link my apps with OCCI 12.1 (oraocci12.dll) and have it run on top of OCI 11.2 (oci.dll) ?
    I'm not using any advanced OCI features.
    Thanks in advance!

    4f2b8813-c251-4b48-8f2b-242dc36d4904 wrote:
    A quick newbie question: can I compile and link my apps with OCCI 12.1 (oraocci12.dll) and have it run on top of OCI 11.2 (oci.dll) ?
    I'm not using any advanced OCI features.
    Not sure what you mean... oraocci12.dll depends on oci.dll, so you are implicitly using OCI when you use OCCI.
    But I was told by Oracle (a few years back, about 11gR1 at the time) that you cannot mix OCCI with OCI, despite having accessors to the raw OCI handles from OCCI. OCCI sometimes lag in its support of feature that first come out first for OCI, like it used to for 64-bit LOB sizes, or XMLTYPE support, etc... Since those limitations of OCCI made us invest in the lower-level OCI, I haven't followed up on OCCI much.
    Another drawback of OCCI versus OCI is that since OCCI is C++, you must always wait (sometimes for months) for Oracle to provide you with a version compiled with the latest Visual Studio, whereas OCI as a C library can be used with any VS versions.
    But otherwise OCCI is great, much simpler that OCI. By all means use OCCI if it covers all the features (and VS versions) you want to use. --DD

  • GCC compatibility with  OCI

    OCI states that it supports 4.1 and I am using GCC 4.5 . Any idea if the two are compatible if not ?? What should i do any help would be appreciated...

    Hi Mac,
    I am also using OCI with C.
    Can you please post or email me your makefile , I am getting ORA-6521 : error mapping function. So there seems to be a problem with the way I am generating custagg.so file. Can you please post your makefile. So that I can generate my shared library properly.
    This is how I am generating my shared library:
    I am compiling my C program with OCI using the following command :
    g++ -Wall -c custagg.c -o custagg.o -I$ORACLE_HOME/rdbms/public -I/usr/lib
    I am linking to get a shared library custagg.so file with following command :
    ld -shared -o custagg.so custagg.o $ORACLE_HOME/lib/l*.so ../../usr/lib/libstdc++.s*
    I am not getting any errors during these two phases.
    And when i am calling the extproc custagg(Mindistance) which i implemented using ODCI(oracle data catridge interface) ...I am getting the error undefined symbol : ODCIAggregateInitialize
    If, in case you what shared libraries are required to access the ODCI services and also am I compiling and linking it the right way or am I missing any libraries.
    I have the oci.h & odci.h and several other header files in my :
    $ORACLE_HOME/rdbms/public
    And while linking i am using : $ORACLE_HOME/lib/*.so files.
    So I don't know whether my directory is missing some shared files related to ODCI :
    can you please let me know which files or shared libraries I am missing :
    These are the errors which i am getting :
    ERROR at line 1:
    ORA-06521: PL/SQL: Error mapping function
    ORA-06522: /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/lib/custagg.so:
    undefined symbol: ODCIAggregateInitialize

  • OCI for linux

    I'm trying to get OCI for linux, basically so I can get this program that I'm porting to compile. Couldn't find it explicitly anywhere, so I've downloaded the entire oracle8161SE_tar.gz, assuming it's in there somewhere. Apon trying to install it, I've realized it needs X for the installer. Now it appears I'll have to install X, to install Oracle, to get a couple headers and some libs.....is there an easier way to do this?
    Thanks

    robert krueger (guest) wrote:
    : Hi,
    : I read that some people are using the JDBC OCI driver with
    Oracle
    : 8 on linux. I can only find the OCI Drivers for NT and Solaris
    on
    : the download pages. Can anyone give me a hint where to download
    : the native Linux driver?
    : btw. I am running the early adopters release on linux
    : thanks,
    : robert
    JDBC (thin & OCI) drivers were not shipped with Early Adopter
    Release of Oracle8 on Linux. They are shipped with Oracle8
    Production Release.
    Get Technical!
    http://technet.oracle.com
    null

  • How do I use iTunes shar to share apps with in my household

    I heard that sharing apps with in a household is ok. So I wanna co it but not sure how to do it with I tunes share. Help please

    The apps that you share will be associated with your Apple ID, even if you share them with family members. So if an app needs to be updated, then you shall have to sign into your Apple ID on the computers or iOS devices which have the apps installed in order to update them.
    Probably the easiest way to share the apps is to copy them from your computer to the other computers in your family and then authorize those computers with your Apple ID. You can authorize up to five (5) computers, including your own, to use your iTunes stuff. On a Mac the apps are stored at this location; ~/Music/iTunes/iTunes Media/Mobile Applications/ (I have no idea where they are on a Windows box!) Drag & drop the apps that you wish to share from that location onto the iTunes app on the other Macs or PCs over your LAN or other direct connection. Or copy them from that location onto a USB stick and then drag & drop them onto iTunes on the other computers. After you authorize those computers for your iTunes stuff, the apps can be synced to iOS devices. You authorize the computer to use your iTunes stuff in the computer's iTunes app's Store menu.
    There are other more complicated methods of moving the apps around to share.

  • How to debug web app with weblogic?

    I wrote a web app that includes jsp files and some javabeans, then I put the jsp files to directory
    mydomain\applications\DefaultWebApp
    then I complied javabeans and put those classes to
    mydomain\applications\DefaultWebApp\WEB-INF\classes
    Then I start the weblogic,it runs very well.
    I modified some javabean, complie them and put classes override the old classes,
    but the web app can not find the new classes.
    Any one know How to debug web app(with javabeans) in weblogic?
    thanks!

    how to config the hot deploy?
    thxSorry, for this delay in responding. I had set notify me with email option in Watch This topic; but I never did get any email notification.
    I use wls6.1; I think the process may be very similar to this in wls8.x. In wls6.1 (sp5), this is done via the -
    Dweblogic.ProductionModeEnabled=False or
    Dweblogic.ProductionModeEnabled=True
    in the startup cmd/sh script. Out of the box, wls6.1 is set to Dweblogic.ProductionModeEnabled=False which automatically enables hot deploys.

  • How to stop syncing apps with itunes without deleting them from iphone?

    Basically I don't want to sync my apps with itunes, because it takes up too much memory in my macbook. However every tome I uncheck the "sync apps" box it threatens me that all my apps will be deleted of my iphone!!!

    Try this:
    https://discussions.apple.com/thread/3555070

  • I bought the wrong app, I should exchange Photoshop app with AI app

    I should cancel Photoshop and should buy AI app.

    Thank you a lot...^^
    2015. 3. 19. 오후 10:23에 "Sheena Kaul" <[email protected]>님이 작성:
        today i bought wrong app, i should exchange Photoshop app with AI app
    created by Sheena Kaul <https://forums.adobe.com/people/Sheena+Kaul> in *Creative
    Cloud Download & Install* - View the full discussion
    <https://forums.adobe.com/message/7315839#7315839>

  • Unable to sync some apps with my ipod

    I am unable to sync some apps with my ipod touch

    See:
    Identifying iPod models
    The iPod touch (3rd generation) can be distinguished from iPod touch (2nd generation) by looking at the back of the device. In the text below the engraving, look for the model number. iPod touch (2nd generation) is model A1288, and iPod touch (3rd generation) is model A1318.

  • Remote app with Apple TV

    I use the Remote app with both an iPad and iPhone to control my first gen Apple TV. This works fine except for one thing. When I select "Apple TV" as the library, using an iPhone I have access to all my library including Podcasts. When I run the same app on my Ipad, still selecting "Apple TV" as the library, no Podcasts come up on the iPad to select - the category is completely missing.
    Has anyone else seen this issue ? Are they still there but hidden somewhere else ? Bear in mind I keep no content on the Apple TV - it is effectively just acting as a wireless device to get the signal to my TV.

    Literally nothing happens. I click the done button and hear a beep. Over and over again.
    On the phone, the passcode is still displayed.
    Thank you for your help.

Maybe you are looking for