1627564 - SAPOSCOL: Clearing Shared Memory and Updating Saposcol

Symptom

  • You need to clear the shared memory for SAPOSCOL
  • You need to update your SAPOSCOL to the latest patch version
  • SAPOSCOL is not able to (re)start, errors regarding SHM are present in the logfile

Environment

  • SAP ECC

Reproducing the Issue

In transaction ST06 or OS07N there are issues which require resolution by clearing the shared memory and/or updating SAPOSCOL.

Cause

Shared memory issues and obsolete versions of SAPOSCOL can cause statistics not to be collected correctly for the transactions ST06 / OS07N

Resolution

1.  Updating SAPOSCOL:

  • As described in note 2180367, saposcol is a part of the SAPHostAgent package.  Installing or upgrading saposcol is done by installing or upgrading the SAPHostAgent package (note 1031096).  Saposcol is kernel independent.

1031096 - Installing Package SAPHOSTAGENT
2180367 - How to run saposcol OS collector correctly
2067546 - ST06/OS07N: Overview note

2.  Clearing SAPOSCOL Shared Memory Segment:

  • Use the following procedure to delete the shared memory for SAPOSCOL:

saposcol -d            (start in dialog mode)
Collector > clean
Collector > quit
saposcol -k            (stops saposcol)
saposcol -d            (before restarting)
Collector > leave   (should get a message Shared memory deleted)
Collector > quit
cd /usr/sap/tmp
mv coll.put coll.old (rename the file; this stores the saposcol history data)
cd
saposcol                (start saposcol again)

  • If you cannot delete the shared memory segment with the above procedure then:
    • On Unix systems:
      • You can use 'cleanipc 99 remove' on O/S level (this will remove all the ipc objects for the system number 99, also for the SAPCCMSR agent)
      • You could alternatively use 'ipcrm -M 0x00004dbe', which will delete saposcol’s SHM, but not anything related to host agent
    • On Windows:
      • You can use Microsoft Process Explorer to check the shared memory handle of saposcol and then try to find if another process holds it.  You should see that some disp+work has the handle.  Kill this and then you should be able to stop saposcol and clean the memory.
      • If you cannot delete the shared memory segment manually as above, then a sure method to delete the existing shared memory segment is a restart of the Windows OS.  If you are using CCMS patch collection 2011/3, a Windows restart should no longer be required.
        .
  • After restarting SAPOSCOL again you can check the dev_coll file to see if the actual SAPOSCOL process also created the shared memory segment:

10:51:18 01.07.2011   LOG: Shared Memory Size: 532786.
10:51:18 01.07.2011   LOG: Shared Memory was created by process:5708   <<<<<<
10:51:21 01.07.2011   LOG: Collector daemon started
10:51:21 01.07.2011   LOG: read coll.put Fri Jul 01 10:47:12 2011
10:51:21 01.07.2011   LOG: Collector PID: 5708                                                  <<<<<<

  • On UNIX systems you can use the SAP OS command ‘showipc 99’ to report the defined IPC objects for the system area 99.
    You can also use the UNIX command ‘ipcs –a’ to report some more detailed information, like owner and permissions about the defined IPC objects.

Keywords

saposcol, st06, st06n, os07, os07n

请使用浏览器的分享功能分享到微信等