Shared memory and ABAP

Dear developers,
I have some documentation on ABAP SHARED OBJECTS and I wonder how I could define shared memory objects at run time ( so I would need something like an API ) instead of using the SHMA transaction.
I actually also wonder what would happen if 2 users of the same shared object would call on one of its methods ? Can we have concurrent access ? How does the whole locking thing works ? Is it possible to implement waiting calls/locks ?
If you have any serious/technical documentation on semaphores/locks in SAP/ABAP I'd also be very interested.
Sincerely,
Olivier MATT

Hi matt,
            This is vijay here.
                                      if you r working on frequntly changed data then you must use this locking technique.
well jus go to se11 and make a lock object by starting initial......EZ....
EX: EZENMARA.
then u can fix the lock as shared or (exclusive,cumulative) or( exclusive, not cumulative)
you can also fix the lock parameters like  specific fields.then jus save and activate.
and when you will make a program jus call the function module enqueue_ezenmara for locking and dequeue_ezenmara for unlocking and u can get rest in my program.
regards
vijay
rewards if answer is helpfull.
TABLES: MARA.
PARAMETER: MATNR LIKE MARA-MATNR.
CALL FUNCTION 'ENQUEUE_EZENMARA'
EXPORTING
   MODE_MARA            = 'S'
   MANDT                = SY-MANDT
  MATNR                =
   X_MATNR              = 'MATNR'
  _SCOPE               = '2'
  _WAIT                = ' '
  _COLLECT             = ' '
EXCEPTIONS
  FOREIGN_LOCK         = 1
  SYSTEM_FAILURE       = 2
  OTHERS               = 3
IF SY-SUBRC = 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
        WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
WRITE: 'TABLE IS LOCKED'.
ELSE.
SELECT * FROM MARA WHERE MATNR = MATNR.
WRITE:/ MARA-MATNR,MARA-ERNAM,MARA-MTART.
ENDSELECT.
ENDIF.

Similar Messages

  • SHARED MEMORY AND DATABASE MEMORY giving problem.

    Hello Friends,
    I am facing problem with EXPORT MEMORY and IMPORT MEMORY.
    I have developed one program which will EXPORT the internal table and some variables to the memory.This program will call another program via background job. IMPORT memory used in another program to get the first program data.
    This IMPORT command is working perfect in foreground. But  it is not working in background.
    So, I have reviewed couple of forums and I tried both SHARED MEMORY AND DATABASE MEMORY.  But no use. Still background is giving problem.
    When I remove VIA JOB  parameter in the SUBMIT statement it is working. But i need to execute this program in background via background job. Please help me . what should I do?
    pls find the below code of mine.
    option1
    EXPORT TAB = ITAB
           TO DATABASE indx(Z1)
                FROM   w_indx
                CLIENT sy-mandt
                ID     'XYZ'.
    option2
    EXPORT ITAB   FROM ITAB
      TO SHARED MEMORY indx(Z1)
      FROM w_indx
      CLIENT sy-mandt
      ID 'XYZ'.
       SUBMIT   ZPROG2   TO SAP-SPOOL
                      SPOOL PARAMETERS print_parameters
                       WITHOUT SPOOL DYNPRO
          *_VIA JOB name NUMBER number*_
                       AND RETURN.
    ===
    Hope every bidy understood the problem.
    my sincere request is ... pls post only relavent answer. do not post dummy answer for points.
    Thanks
    Raghu

    Hi.
    You can not exchange data between your programs using ABAP memory, because this memory is shared between objects within the same internal session.
    When you call your report using VIA JOB, a new session is created.
    Instead of using EXPORT and IMPORT to memory, put both programs into the same Function Group, and use global data objects of the _TOP include to exchange data.
    Another option, is to use SPA/GPA parameters (SET PARAMETER ID / GET PARAMETER ID), because SAP memory it is available between all open sessions. Of course, it depends on wich type of data you want to export.
    Hope it was helpful,
    Kind regards.
    F.S.A.

  • Examples for SAP Memory and ABAP Memory

    Hi all,
        can u give me one example of sap memory and abap memory.
                                              Ranjith

    Hi,
    <b>SAP Memory</b>
    SAP memory is a memory area to which all main sessions within a SAPgui have access. You can use SAP memory either to pass data from one program to another within a session, or to pass data from one session to another. Application programs that use SAP memory must do so using SPA/GPA parameters (also known as SET/GET parameters). These parameters can be set either for a particular user or for a particular program at the time of logon using the SET PARAMETER statement. Other ABAP programs can then retrieve the set parameters using the GET PARAMETER statement. The most frequent use of SPA/GPA parameters is to fill input fields on screens .
    <b>example:</b>
    ABAP programs can access the parameters using the SET PARAMETER and GET PARAMETERstatements.
    To fill one, use:
    SET PARAMETER ID pid FIELD f
    This statement saves the contents of field f under the ID pid in the SAP memory. The ID pid can be up to 20 characters long. If there was already a value stored under pid, this statement overwrites it. If you double-click pid in the ABAP Editor, parameters that do not exist can be created as a Repository object.
    To read an SPA/GPA parameter, use:
    GET PARAMETER ID pid FIELD f.
    This statement places the value stored under the pid ID into the variable f. If the system does not find any value for pid in the SAP memory, sy-subrc is set to 4. Otherwise, it sets the value to 0.
    <b>ABAP Memory</b>
    ABAP memory is a memory area that all ABAP programs within the same internal session can access using the EXPORT and IMPORT statements. Data within this memory area remains throughout a sequence of program calls, with the exception of LEAVE TO TRANSACTION. To pass data to a program that you are calling, the data needs to be placed in ABAP memory before the call is made from the internal calling session using the EXPORT statement. The internal session of the called program then replaces that of the calling program. The program called can then read from the ABAP memory using the IMPORT statement. If control is then returned to the program that made the initial call, the same procedure operates in reverse.If a transaction is called using LEAVE TO TRANSACTION, the ABAP memory and the call stack are deleted. They cannot be used for data transfer.
    Since objects belonging to ABAP objects can only be accessed within an internal session, it does not make sense and is therefore forbidden (from a syntax point of view) to pass a reference to an object to a calling program through the ABAP memory.
    <b>Example:</b>
    Export hello to memory id 'Hello_world'.
    Import hello from memory id 'Hello_world'
    Regards
    Sudheer

  • Hi Friends ....Difference between SAP memory and ABAP memory

    Hi Friends,
    I faced a interview and they ask this question
    What is the difference between SAP Memory and ABAP memory..

    conti
    SAP Memory
    SAP memory is a memory area to which all main sessions within a SAPgui have access. You can use SAP memory either to pass data from one program to another within a session, or to pass data from one session to another. Application programs that use SAP memory must do so using SPA/GPA parameters (also known as SET/GET parameters). These parameters can be set either for a particular user or for a particular program using the SET PARAMETER statement.
    Other ABAP programs can then retrieve the set parameters using the GET PARAMETER statement. The most frequent use of SPA/GPA parameters is to fill input fields on screens.
    ABAP Memory
    ABAP memory is a memory area that all ABAP programs within the same internal session can access using the EXPORT and IMPORT statements. Data within this area remains intact during a whole sequence of program calls. To pass data to a program which you are calling, the data needs to be placed in ABAP memory before the call is made. The internal session of the called program then replaces that of the calling program. The program called can then read from the ABAP memory. If control is then returned to the program which made the initial call, the same process operates in reverse.
    A simple example of ABAP memory is using the EXPORT/IMPORT statements.
    Here in this program, I get the data, export it to memory,
    clear out the internal table in my progam, then reimport the data into it and write out the data.
    You probably wounldn't do this in a normal program,
    but this is how you can pass data from program a to program b when A Submits program B.
    report zxy_0002 .
    data: it001 type table of t001 with header line.
    select * into table it001 from t001.
    export it001 = it001 to memory id 'ZXY_TEST'.
    clear it001. refresh it001.
    import it001 = it001 from memory id 'ZXY_TEST'.
    loop at it001.
    write:/ it001-bukrs, it001-butxt.
    endloop.
    SAP Memory
    SAP memory is a memory area to which all main sessions within a SAPgui have access.
    You can use SAP memory either to pass data from one program to another within a session,
    or to pass data from one session to another.
    Application programs that use SAP memory must do so using SPA/GPA parameters (also known as SET/GET parameters).
    These parameters can be set either for a particular user
    or for a particular program using the SET PARAMETER statement.
    Other ABAP programs can then retrieve the set parameters using the GET PARAMETER statement.
    The most frequent use of SPA/GPA parameters is to fill input fields on screens
    ABAP/4 Memory
    ABAP memory is a memory area that all ABAP programs within the same internal session can access
    using the EXPORT and IMPORT statements.
    Data within this area remains intact during a whole sequence of program calls. To pass data
    to a program which you are calling,
    the data needs to be placed in ABAP memory before the call is made.
    The internal session of the called program then replaces that of the calling program.
    The program called can then read from the ABAP memory.
    If control is then returned to the program which made the initial call, the same process operates in reverse.
    SAP memory
    The SAP memory, otherwise known as the global memory,
    is available to a user during the entire duration of a terminal session.
    Its contents are retained across transaction boundaries as well as external and internal sessions.
    The SET PARAMETER and GET PARAMETER statements allow you to write to, or read from, the SAP memory.
    ABAP/4 memory
    The contents of the ABAP/4 memory are retained only during the lifetime of an external session
    (see also Organization of Modularization Units).
    You can retain or pass data across internal sessions.
    The EXPORT TO MEMORY and IMPORT FROM MEMORY statements allow you to write data to, or read data from, the ABAP memory.
    ABAP Memmory & SAP Memmory
    http://www.sap-img.com/abap/difference-between-sap-and-abap-memory.htm
    http://www.sap-img.com/abap/type-and-uses-of-lock-objects-in-sap.htm
    Set
    http://www.geocities.com/SiliconValley/Campus/6345/set_para.htm
    GET
    http://www.geocities.com/SiliconValley/Campus/6345/get_para.htm
    EXPORT
    http://www.geocities.com/SiliconValley/Campus/6345/export01.htm
    Other Imp Help
    http://www.geocities.com/SiliconValley/Campus/6345/abapindx.htm

  • Hi All,Can any provide an example for SAP MEMORY AND ABAP memory

    Hi All,
          Can any provide me an example for SAP MEMORY AND ABAP memory.
    thanks&regards.
    Bharat.

    HI Bharat
    A simple example of ABAP memory is using the EXPORT/IMPORT statements.
    Here in this program, I get the data, export it to memory,
    clear out the internal table in my progam, then reimport the data into it and write out the data.
    You probably wounldn't do this in a normal program,
    but this is how you can pass data from program a to program b when A Submits program B.
    report zxy_0002 .
    data: it001 type table of t001 with header line.
    select * into table it001 from t001.
    export it001 = it001 to memory id 'ZXY_TEST'.
    clear it001. refresh it001.
    import it001 = it001 from memory id 'ZXY_TEST'.
    loop at it001.
    write:/ it001-bukrs, it001-butxt.
    endloop.
    SAP Memory
    SAP memory is a memory area to which all main sessions within a SAPgui have access.
    You can use SAP memory either to pass data from one program to another within a session,
    or to pass data from one session to another.
    Application programs that use SAP memory must do so using SPA/GPA parameters (also known as SET/GET parameters).
    These parameters can be set either for a particular user
    or for a particular program using the SET PARAMETER statement.
    Other ABAP programs can then retrieve the set parameters using the GET PARAMETER statement.
    The most frequent use of SPA/GPA parameters is to fill input fields on screens
    ABAP/4 Memory
    ABAP memory is a memory area that all ABAP programs within the same internal session can access
    using the EXPORT and IMPORT statements.
    Data within this area remains intact during a whole sequence of program calls. To pass data
    to a program which you are calling,
    the data needs to be placed in ABAP memory before the call is made.
    The internal session of the called program then replaces that of the calling program.
    The program called can then read from the ABAP memory.
    If control is then returned to the program which made the initial call, the same process operates in reverse.
    SAP memory
    The SAP memory, otherwise known as the global memory,
    is available to a user during the entire duration of a terminal session.
    Its contents are retained across transaction boundaries as well as external and internal sessions.
    The SET PARAMETER and GET PARAMETER statements allow you to write to, or read from, the SAP memory.
    ABAP/4 memory
    The contents of the ABAP/4 memory are retained only during the lifetime of an external session
    (see also Organization of Modularization Units).
    You can retain or pass data across internal sessions.
    The EXPORT TO MEMORY and IMPORT FROM MEMORY statements allow you to write data to, or read data from, the ABAP memory.
    ABAP Memmory & SAP Memmory
    http://www.sap-img.com/abap/difference-between-sap-and-abap-memory.htm
    http://www.sap-img.com/abap/type-and-uses-of-lock-objects-in-sap.htm
    Set
    http://www.geocities.com/SiliconValley/Campus/6345/set_para.htm
    GET
    http://www.geocities.com/SiliconValley/Campus/6345/get_para.htm
    EXPORT
    http://www.geocities.com/SiliconValley/Campus/6345/export01.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb3bc4358411d1829f0000e829fbfe/frameset.htm
    Other Imp Help
    http://www.geocities.com/SiliconValley/Campus/6345/abapindx.htm
    Regards Rk

  • How do I set the shared memory and semaphore Parameters

    Hi, everyone:
    Could someone help me on this? The Oracle Installation Guide
    for Linux says these parameters need to be set, but does not say
    how. Thanks in advance.
    Jim
    null

    Lawrence Yeo (guest) wrote:
    : Hi,
    : Please refer to the Installation guide written by
    : [email protected] at http://jordan.fortwayne.com/oracle/.
    : I haven't successfully install oracle on my linux box, but I
    : think this installation guide is pretty good, it guide you
    step
    : by step throught experience. There is an instruction on how
    to
    : set the parameter, but that require kernel re-compile though.
    It seems this problem is getting discussed on a number of
    different threads. Here is a reply I just posted on one of
    those other threads:
    Ari Arantes (guest) wrote:: Hi,
    : I've installed Oracle on RedHat 5.2 (2.0.36) on a machine with
    : 512 mb memory.
    : First I've recompiled the kernel how Oracle says and basing in
    : some documents (like
    : http://jordan.fortwayne.com/oracle/oralinux.html). Of course
    I've
    : saved a copy of the old kernel. The linux was ok, the command
    : ipcs -l shows the new values of the kernel parameters, but
    Oracle
    : didn't start. I've restored the copy of the kernel, the ipcs -
    l
    : shows the old values and now Oracle is running, with a SGA of
    : almost 300 mb.
    : Is there some problem in that? Will the machine loose
    performance
    : because the miminum values of the kernel parameters?
    : Best regards,
    : Ari
    I have a setup similar to yours (384 MB instead of 512 MB),
    and I spent some time looking at the parameters.
    You CANNOT use the value for SHMMAX from the Oracle manual!
    As it says at http://jordan.fortwayne.com/oracle/oralinux.html
    "Should you decided to change these parameters, if you set
    the SHMMAX to what Oracle says, you are telling the system
    to allow a shared memory segment to grow as large as 4 Gigs.
    Many users have reported problems setting the value this
    high."
    Sounds like you are another one of those users, eh?
    If you read on down, the guy who wrote that web page never
    used over 128 MB for SHMMAX. I'd take a strong hint from that.
    =====
    Oracle wants you to use 4GB-1 as the SHMMAX value. That
    equates to (1<<32)-1. As we shall see, that is not allowed
    without "breaking the rules" for the i386 architecture.
    If you carefully read through the header file, you will find
    out that the **actual maximum value** for SHMMAX is 256 MB.
    You can tell this two ways. Take a look at the file at:
    /usr/src/linux/include/asm/shmparam.h
    Near the top of the file is:
    /* address range for shared memory attaches if
    no address passed to shmat() */
    #define SHM_RANGE_START 0x50000000
    #define SHM_RANGE_END 0x60000000
    Note that the above is 256 MB (0x10000000), or (1<<28). This
    is one potential source of trouble. I don't know if some other
    files someplace else in the kernel specify uses for address
    ranges adjacent to the above range, which I take to be the
    "practical maximum" without redefining that range. Personally,
    I wouldn't want to mess with the above unless I **really**
    knew what I was doing (and I'll be the first to admit I don't).
    =====
    Farther down you will see some more lines (not together)
    that look like this:
    #define SHMID_BITS 7
    #define SHMIDX_BITS 15
    * SHMID_BITS + SHMIDX_BITS must be <= 24 on the i386 and
    * SHMMAX <= (PAGE_SIZE << SHMIDX_BITS).
    #define SHMMAX 0x2000000 /* max shared seg
    size (bytes) */
    Now, 7 + 15 is 22, so you could go up a couple of bits if you
    had to. To avoid making the table any larger, I would suggest:
    #define SHMIDX_BITS 17
    But, 17 turns out to produce a result larger than the "practical
    maximum" (256 MB) above. To see why takes a little more
    explaining.
    If you don't change this at all, then the maximum possible
    value for SHMMAX is 4096 [the PAGE_SIZE) << 15 [_SHM_IDX_BITS],
    or rather (1<<27).
    Now, that is exactly half of the (1<<28) "practical maximum" I
    mentioned above.
    So, if you always want the maximum amount of shared memory,
    then change the definition of SHMMAX to the following:
    #define SHMMAX (PAGE_SIZE<<_SHM_IDX_BITS) /* max shared seg
    size (bytes) */
    That gives you 128 MB in and of itself (as compared with 32 MB
    as Red Hat 5.2 is delivered).
    If you want the full 256 MB that is allowed for in the memory
    map, then you need to also change:
    #define SHMIDX_BITS 16
    The above value is **exactly** what is recommended on the web
    page you were following (above).
    If you want to keep going up, you will need to change the
    memory space allocated for shared memory as defined by
    SHM_RANGE_START and SHM_RANGE_END, something I advise against.
    =====
    Even on a machine with 512 MB of "real" memory, I find it hard
    to believe that there would be any substantial benefit to
    having a maximum shared memory space greater than 256 MB. The
    reason is that Oracle can use multiple shared memory spaces.
    It requires a minimum of ten (10), according to the installation
    manual, but the Red Hat 5.2 distribution supplies SHMMNI (128)
    of them. That will allow each Oracle process to have a total
    of up to 32 GB of shared memory (128 times 256 MB) and all it
    asks for is 40 GB (10 times 4 GB), so it has plenty, IMHO.
    =====
    Let me say a few more words about the web page you were using
    for configuration advice. That person actually **reduced** the
    amount of shared memory segments by specifying **lower values**
    for SHMMNI and SHMSEG.
    I'd **STRONGLY** recommend **NOT CHANGING** those other values!
    Its my understanding that Oracle can make up for the smaller
    maximum shared memory segment size by using more shared memory
    segments. So, if you reduce those, you are essentially shooting
    yourself in the foot by taking away what you are giving with
    increasing the maximum segment size.
    =====
    Good luck, and may this farce be with you!
    null

  • Shared Memory and Memory Paging - VDI 3.2

    Hello
    What metrics have been identified in the performance and optimisation of these new features for VDI 3.2 ?
    We are looking for substantiated indicators with respect to builds for sites of various user-base sizes v's SunRays on desks.
    Regards
    Jeremy.

    good Question!
    Also I'm confused of how much memory is really used and what is shown where (top vs. Desktop provider Info in VDI Admin vs. what I see/assigned in the VDesktop)
    sometimes balooning works like a charm and I can overcommit lots of memory running several desktops. Other times running one single Win7 Desktop (1GB RAM assigned) on a SF4140 /w 8G Ram installed eats up 75% of my memory.
    Right now the Win7 VDesktop I'm using has
    1024 MB assigned by the VDI-Manager with 50% memory sharing
    The manager displays ~ 3,8 GB Used, as the Win7 VBox is the only one Running in an All-in-One configuration and takes roughly 2.2-2.5 GB w/o a running VM, I assume that 1.2 or 1.3 is accounting on the Win7 Wbox
    in top the VBoxHeadless process shows up with 1891MB memory usage
    Which one to trust? Somewhat hard to forecast.
    could someone shed some light on this?
    Regards,
    zoltan

  • I have more than 3 instances running on the Linux box? How can I determine which shared memory and semaphores are associated with which instance?

    Pleace help me
    Thanks

    ohh yeah,
    Please check again
    SQL>oradebug setmypid
    SQL>oradebug ipc
    SQL>oradebug tracfile_name
    Thank you

  • Shared memory between LV and a DLL

    Hello
    I am building a DLL in Visual .NET. It is called by LV in a .vi
    The DLL is counting some stuffs over a network, and I d'like to see the
    counter status in the vi, dynamically. This means that when the
    variable is changed is the DLL, the LabView variable changes too.
    I tryed to do this using shared memory, and passing a pointer to the
    DLL. Unfortunately, it seems that the value isn't updated while the DLL
    is running.
    Please tell me the way to do this. I read about global variable, but it isn't much better.
    Thanks versy much !
    Fabien
    PS: I am using LabView 7.1 and VisualStudio .NET 7.0.9500  in C language.
    Message Edité par faquin le 08-02-2005 07:45 AM

    Since you say the DLL does not finish executing, you will need some method where both programs can communicate.
    Here are a couple of suggestions (haven't tried any of them):
    You can try using TCP (search the example finder and this site for examples and tutorials).
    You can try opening a connection to the LV VI server from the DLL to set the value of the indicator.
    If the DLL is threadsafe, maybe you can have another DLL which will serve as a buffer - your DLL will call it to put the data in and LV will call it to extract the data (assuming LV can call 2 threadsafe DLL functions at the same time).
    Try to take over the world!

  • Semaphores and shared memory's classes

    Hi there,
    I looking for the classes used to deal with semaphores and shared memory. Does anyone know which are these classes?
    Thanks

    The file mapping capability added in 1.4 may result in shared memory but this is not guaranteed. You can use JNI to call some C code which allocates shared memory and then uses the NewDirectByteBuffer method to return a ByteBuffer representing that shared memory to the Java code.
    You would also need to use JNI to wrap system provided semaphore or mutex operations to provide cross process synchronization.
    However, do your communication needs really require performance in excess of that available using sockets? I can get at least 7MB/s between two processes on a rather modest machine.

  • Is XML Publisher causing shared memory problem..?

    Hi Experts,
    Since this week, many of the Requisition/PO are erroring out with the below errors or similar to these errors:
    - ORA-04031: unable to allocate 15504 bytes of shared memorny ("sharedpool","PO_REQAPPROVAL_INIT1APPS","PL/SQL MPCODE","BAMIMA: Bam Buffer")
    ORA-06508: PL/SQL: could not find program unit being called.
    -Error Name WFENG_COMMIT_INSIDE
    3146: Commit happened in activity/function
    'CREATE_AND_APPROVE_DOC:LAUNCH_PO_APPROVAL/PO_AUTOCREATE_DOC.LAUNCH_PO_APPROVAL'
    Process Error: ORA-06508: PL/SQL: could not find program unit being called
    Few days back we were getting heap memory error for one of the XML Publisher report.
    I heard that XML Publisher requires lot of memory for sources/features,So I want to know whether XML Publisher can be one of the cause for memory problem to occur or this shared memory is not related with XML Publisher sources at all.
    Please advice.
    Many thanks..
    Suman
    Edited by: suman.g on 25-Nov-2009 04:03

    Hi Robert,
    Thanks for your quick reply...
    Apps version: 11.5.10.2
    database version: 9.2.0.8.0
    As I am a beginner in this so dont know much about this.. Can you please guide me on this.
    DBAs has increased the shared memory and problem has resolved but here I am more concrened whether the XML Publisher was or can be one od the cause for shared memory problem. Is there any way to check that or this occurs randomly and we can not check this.
    Please advice something.

  • Multiple Users Accessing Shared Memory

    I created a shared memory enabled class, and it works great for a simple scenario.  But, it's currently not sufficient for my needs.  Here's an example of what I'm trying to accomplish, and the events happen in this order!
    User 1 writes data XXX to shared memory.
    User 2 writes data YYY to shared memory.
    User 1 reads from shared memory and I want him to get his data (XXX).
    User 2 reads from shared memory and I obviously want him to get his YYY.
    I do have a key I can use to differentiate my data but I don't know how to incorporate that in my process. 
    Is the solution to write a table, rather than my current simple structure, to my shared memory?  But if I do this how do I clean off the "used" row after it is read?
    Or is the solution to use some sort of instance of my class and reference the appropriate instance on each read?
    Here's my write:
      data: lo_shared_area type ref to z_cl_rdn_shared_area,
            lo_root        type ref to z_cl_rdn_memory.
    ****get a pointer to the Shared Area
      lo_shared_area = z_cl_rdn_shared_area=>attach_for_write( ).
    ****Create an instance of our root
      create object lo_root area handle lo_shared_area.
    ****Set the Initial value for our message
      lo_root->set_ptwy( ps_ptwy ).
    ****Set the root back into the Area
      lo_shared_area->set_root(  lo_root ).
    ****Commit and detatch
      lo_shared_area->detach_commit( ).
    Here's my read:
      data: lo_shared_area type ref to z_cl_rdn_shared_area,
            lo_root        type ref to z_cl_rdn_memory.
      lo_shared_area = z_cl_rdn_shared_area=>attach_for_read( ).
      lo_root        = lo_shared_area->root.
      try.
          ls_ptwy = lo_root->get_ptwy( ).
        catch cx_root.
          clear ls_ptwy.
      endtry.
      lo_shared_area->detach( ).
    Thanks,
    Mike

    Hello,
    Clearing shared memory will crash SAP   ie cleanipc.
    Need to increase memory parameters
    Check notes...
    146289    Parameter Recommendations for 64-Bit SAP Kernel   
    146528 "Configuration of R/3 on hosts with much RAM".                     
    regards,
    John Feely

  • Oracle 11g problem with creating shared memory segments

    Hi, i'm having some problems with the oracle listener, when i'm trying to start it or reload it I get the follow error massages:
    TNS-01114: LSNRCTL could not perform local OS authentication with the listener
    TNS-01115: OS error 28 creating shared memory segment of 129 bytes with key 2969090421
    My system is a: SunOS db1-oracle 5.10 Generic_144489-06 i86pc i386 i86pc (Total 64GB RAM)
    Current SGA is set to:
    Total System Global Area 5344731136 bytes
    Fixed Size 2233536 bytes
    Variable Size 2919238464 bytes
    Database Buffers 2399141888 bytes
    Redo Buffers 24117248 bytes
    prctl -n project.max-shm-memory -i process $$
    process: 21735: -bash
    NAME PRIVILEGE VALUE FLAG ACTION RECIPIENT
    project.max-shm-memory
    privileged 64.0GB - deny
    I've seen that a solution might be "Make sure that system resources like shared memory and heap memory are available for LSNRCTL tool to execute properly."
    I'm not exactly sure how to check that there is enough resources?
    I've also seen a solution stating:
    "Try adjusting the system-imposed limits such as the maximum number of allowed shared memory segments, or their maximum and minimum sizes. In other cases, resources need to be freed up first for the operation to succeed."
    I've tried to modify the "max-sem-ids" parameter and set it to recommended 256 without any success and i've kind of run out of options what the error can be?
    /Regards

    I see, I do have the max-shm-ids quite high already so it shouldn't be a problem?
    user.oracle:100::oracle::process.max-file-descriptor=(priv,4096,deny);
    process.max-stack-size=(priv,33554432,deny);
    project.max-shm-memory=(priv,68719476736,deny)

  • Solaris 10 shared memory config/ora 11g

    The ora 11 install guide for spark solaris 10 is very confusing wrt shared memory and my system does not seem to using memory correctly, lots of swapping on an 8GB real memory system.
    The doc says to set /etc/system to:
    shmsys:shminfo_shmmax project.max-shm-memory 4294967296
    but infers that this is not used.
    Then, the doc states to set a project shared mem value of 2GB:
    # projmod -sK "project.max-shm-memory=(privileged,2G,deny)" group.dba
    Why is this number different?
    By setting to to 2G as documented oracle did not work at all and so I found Note:429191.1
    on the solaris 10 memory which hints that these numbers should be big:
    % prctl -n project.max-shm-memory -r -v 24GB -i project oracle_dss
    % prctl -n project.max-shm-memory -i project oracle_dss
    project: 101: oracle_dss
    NAME PRIVILEGE VALUE FLAG ACTION RECIPIENT
    project.max-shm-memory
    privileged 24.0GB - deny -
    system 16.0EB max deny
    Is there some logic in how to get solaris 10/ora 11 to hold hands. The install doc does not seem to contain it.

    system does not seem to using memory correctly, lots of swapping on an 8GB real memory system.We could start (for example) with this question - How big is your SGA or how much of 8GB RAM takes your SGA?
    The doc says to set /etc/system to:
    shmsys:shminfo_shmmax project.max-shm-memory 4294967296
    but infers that this is not used.From documentation:
    In Solaris 10, you are not required to make changes to the /etc/system file to implement the System V IPC. Solaris 10 uses the resource control facility for its implementation. However, Oracle recommends that you set both resource control and /etc/system/ parameters. Operating system parameters not replaced by resource controls continue to affect performance and security on Solaris 10 systems.
    Then, the doc states to set a project shared mem value of 2GB:
    # projmod -sK "project.max-shm-memory=(privileged,2G,deny)" group.dba
    Why is this number different?It's an example how "To set the maximum shared memory size to 2 GB"
    By setting to to 2G as documented oracle did not work at all Docs says:
    On Solaris 10, verify that the kernel parameters shown in the following table are set to values greater than or equal to the recommended value shown.
    If your SGA was greater than 2G I'm nor wondering why "oracle did not work at all".
    So for 4GB SGA (for example) you need allow allocation of 4G of shared memory.
    Note: shmsys:shminfo_shmmax != project.max-shm-memory. "project.max-shm-memory" is replacement of "shmsys:shminfo_shmmax" but function of these parameters differs.
    "project.max-shm-memory resource control limits the total amount of shared memory of one project, whereas previously, the shmsys:shminfo_shmmax parameter limited the size of a single shared memory segment."
    Relevant link to Sun docs: http://docs.sun.com/app/docs/doc/819-2724/chapter1-33

  • "shared memory realm" error -- cross-posted in "installation"

    I've just installed 8.1.7 on a Solaris 8 workstation. The installation went fine up until the database creation assistant tried to create a database: it failed. But the software was all installed, so I did a "connect internal" and created a database myself. Once I start the database, I can connect as system/manager; but when the database is shutdown, connecting as system manager gives me an "Oracle not available" error (ORA-01034) followed by a "shared memory realm not available" error (ORA-27101) followed by a "no such file or directory" error (SVR4 Error: 2:).
    All of the shared memory and semaphore parameters are specified in the /etc/system file, and they show up when I execute a "sysdef -i" command.
    Any ideas why I'm getting these errors?
    I did a search and found a few posts on "shared memory realm," but none of them seemed to address the fact that I can connect when the database is started/mounted, but not when it's shutdown.
    Thanks in advance,
    Rich

    make sure the env var ORACLE_SID is set.
    check PROCESSES in your init.ora file. if you lower this number (to say, 15) and errors go away then you need to up the semiphores kernel parameter (or leave PROCESSES set to a low number). Also, it is correct to get an error when trying to connect to a database that is shutdown. the only way to not get an error is use svrmgrl or "sqlplus /nolog" and then connect / as sysdba (or connect internal).
    Andrew

Maybe you are looking for

  • ST02 Export / Import buffer and directory entries

    What would cause the number of (Export / Import) directory entries to steadily increase in ST02 until there were none left. I currently have the directory size set to 30,000 and over the course of about 7 days they are all used up and then I have ext

  • Report Text line width

    Is there a way to set the text line width on a report to 80 characters and then have it wrap to the next line. I'm getting very long cells that I have to scroll over with the arrow key to see the text past my screen size.

  • Swiss store: where is the direct link to the books in french?

    Hi, I just noticed that the direct link to the french books disappeared from the swiss store. How can i search books within the french books list only? I am connected fom my ipad Thanks!

  • Installing Final Cut Studio 3

    Hi I recently had to restore from back-up to a new laptop. I went to use Final Cut Pro from (Final Cut Studio 2)and was asked for a serial number. Unfortunately I have lost the discs without registering (monumentally stupid I know). Bottom line is I

  • Archlinux Won't Boot With Or Without Installation Disk

    At first my laptop started to turn on and off by itself. So I reseatted the ram to see if that was the problem. After a while, it started to tell me to put a disk or some "media device" inside of the computer to get it to run. I mounted my partitions