Professional Documents
Culture Documents
NETREY POWDWAL
26.04.2010
Contents
1 Document Control.........................................................................................................................3 2 Security Classification...................................................................................................................3 3 Target Audience............................................................................................................................3 4 Introduction:..................................................................................................................................5 5 Configuration:................................................................................................................................6 5.1 Global path for archiving files:.................................................................................................7 5.2 Assignment of physical path to logical path:...........................................................................7 5.3 Logical file name definition: cross client..................................................................................8 5.4 Archiving object-specific customizing:.....................................................................................8 5.5 Activation of archive infostructure: SAP_BC_XMB..................................................................9 5.6 Interfaces for archiving:...........................................................................................................9 5.7 Rentention periods:...............................................................................................................10 5.7.1 Asynchronous messages:..............................................................................................10 5.7.2 Synchronous messages:................................................................................................10 5.7.3 History Entries:...............................................................................................................10 5.8 Archive Job Scheduling:.......................................................................................................11 5.8.1 Viewing archived messages:..........................................................................................12 5.9 Delete Job Scheduling:.........................................................................................................13 5.10 Housekeeping Job ZBC_XMB_REFRESH_ADAPTER_STATUS:......................................14 6 Conclusion:.................................................................................................................................14 7 References:.................................................................................................................................14
3 (15)
1 Document Control
This document explains the concept of archiving and deleting XML messages in SAP PI system. The documentation covers the archiving and deleting procedure only at Integration Engine level (ABAP Stack).
Document Attributes Project name Document ID Area of Validity Responsible Storage Location SAP Process Integration Netrey Powdwal SAP AIMS
Document Control, revision history Date issued 26 Apr 2010 Version 1.0 Author ini. Netrey Powdwal Control ini. Approval ini. Reason for change Initial Version
2 Security Classification
TCS Internal.
3 Target Audience
SAP PI and BASIS consultants.
TCS Internal
NA
TCS Internal
5 (15)
4 Introduction:
Problem statement: Tables that store the XML messages in PI are rapidly growing and you are running out of disk space. As a temporary measure, you increased the table space, but this is afterall a temporary solution. The disk space is limited and if you go on increasing the disk space like this then you will run out of the entire disk space soon and it will affect the performance of the system badly. It might also bring the entire PI system down and all message transfers will come to halt. The growing table space is a serious threat to the system and you need to quickly find a solution to clear the XML messages and reduce the disk space usage. Preparations: Before we start the configuration, its a good idea to note down the current status of the system. i.e. current table space comsumption so that we can compare the results after archiving and deleting to see the reduction in table space. For this, go to transaction SARA, enter the archiving object BC_XMB and click on Database Tables button. Select All Tables radio button and click on Space Statistics button to see the table space statistics. Note: As mentioed earlier, this document deals with messages at Integration Engine level only. It does not involve handling of messages at Java stack (Adapter Engine). The main tables that grow rapidly with growing traffic in PI are, SXMSPMAST: Integration Engine: Message Queue (Master) SXMSCLUR: XMB Resources Cluster SXMSCLUP: XMB Property Cluster
Go to transaction SE11 and open these tables and check the Number of Entries in each of these.
Program RSXMB_DEL_TO_ARCH: This is a very useful program. There are mainly 2 types of messages in PI; messages that are marked for archiving and those marked for deletion. By default, the message will be marked for deletion. We need to explicitly confiture interfaces so that those messages will be marked for archiving. This configuration needs to be done even before sending the very first message in PI. If this configuration is not done already then all messages in PI will be marked for deletion. We can use the program RSXMB_DEL_TO_ARCH to change the deletion flag of these message to archiving flag. Note that this action is irreversible. Field ITFACTION of the table SXMSPMAST stores the flag. We can check this table after executing the program to see if the flag has been updated properly. This program takes a great amount of time to execute depending on the amount of messages that are read as per input criteria. It is recommended to run this program in background. Also, enter the maximum
TCS Internal
6 (15) possible value in Maximum Runtime (s) parameter (E.g. 86,400 seconds). Do not forget to remove the Test Mode checkbox before executing.
5 Configuration:
Now we come to the actual configuration part. Follow the given path to reach the following screen. SPRO > SAP Reference IMG > Cross Applicaton Components > General Application Functions > Mass Data Archiving > Cross-Archiving Object Customizing Check if all the settings are as per shown in the screen below. Cross-Object Customizing Data Archiving: Details
TCS Internal
7 (15)
TCS Internal
8 (15)
TCS Internal
9 (15)
TCS Internal
10 (15)
XML Messages Without Errors Awaiting Deletion: (1 Day) Messages which are older than a day and are maked for deletion will be deleted forever from the database tables. This will not affect the messages which are marked for archive. XML Messages Without Errors Awaiting Archiving: (30 Days) Messages which are older than 30 days and are marked for archive will be archived to a file and deleted from the database tables.
Synchronous messages:
5.7.2
XML Messages Without Errors Awaiting Deletion: (1 Day) Messages which are older than a day and are maked for deletion will be deleted forever from the database tables. XML Messages Without Errors Awaiting Archiving: (0 Days) Synchronouse messages which are successful will be deleted immediately.
History Entries:
5.7.3
History Entries for Deleted XML Messages: (30 Days) History entries are required for QoS Exactly Once. It is recommended to keep history entries at least for 7 days.
TCS Internal
11 (15)
Maintain Start Date and Spool Parameter and click on Schedule Archiving. Once the job is scheduled, click on Job Overview to see the job.
TCS Internal
12 (15)
5.8.1 Viewing archived messages:
Go to transaction SXMB_MONI and select Archived XML Messages (Seach Using Archive)
Select the archive file and press Enter. Note that if the File Status is shown as Delete Completed then archiving was done successfully.
TCS Internal
13 (15)
TCS Internal
14 (15)
6 Conclusion:
Congratulations! You have successfully configured PI system to archive and delete messages. Now the next step is to verify the configuration. In the beginnig we had noted down the system status before archiving. Now same steps need to be performed to check the system status after archiving i.e. we will check the number of table entries of all critical tables mentioned above. This will ensure that the messages were actually archived and deleted and the setup was successful.
7 References:
http://sdn.sap.com/ http://service.sap.com/ http://wiki.sdn.sap.com/wiki/display/XI/PI+Archiving+Conceptual+Overview http://www.saptechnical.com/Tutorials/XI/Archiving/Index.htm http://help.sap.com/saphelp_nw04/helpdata/en/0e/80553b4d53273de10000000a114084/content.htm http://help.sap.com/saphelp_nwpi71/helpdata/EN/8d/3e4c11462a11d189000000e8323d3a/frameset.htm
TCS Internal
15 (15) SAP Notes: 1. 872388 Section 5 k 2. 2. 872388 Section 5 k 1. 3. 1042379 4. 789352 5. 1239882 6. 842187 7. 862423
TCS Internal