1616401 - understanding parallelism during the upgrades, ehps and support packages implementations

5

Click here to load reader

Upload: polo-sap

Post on 27-Dec-2015

244 views

Category:

Documents


5 download

TRANSCRIPT

Page 1: 1616401 - Understanding Parallelism During the Upgrades, EhPs and Support Packages Implementations

SAP Knowledge Base Article

Symptom

This article is intended to explain the parallel import mechanisms how it works in phases like DDIC_UPG, SHADOW_IMPORT*, PARCONV and TABIM_UPG during upgrades and EhPs and phases like DDIC IMPORT and MAIN IMPORT during import of support packages.

Here, "parallelism" means the import of more than one package or more than one object of a package at the same time by the transport tools (tp and R3trans).

Environment

l SAP Netweaver 7.00 (and higher) l SAPup/SAPehpi/SolmanUp/SUM l SAINT/SPAM

Cause

Importing more than one package and object at same time during the main import phases can be performed by the transport tools since SAP_BASIS release 700, according SAP note #1127194 "R3trans import with parallel processes", or higher.

These are the phases that make use of tp/R3trans parallelism.

Depending of the upgrade strategy, the phases can be run during the uptime or in downtime portion:

Parallelism can also be achieved in phases where thetp execute SQL commands directly on the database (command 'tpmvntab'), like PARMVNT_SHD, PARMVNT_XCNV, PMVNTAB_VIEW, PARMVNT_DROPVIEW, PARCONV_UPG and PMVNTAB_UPG. All major databases support it (Oracle,MSSQL,DB2,MaxDB). If your database is IBM's DB2 (alsorefered to DB4 or DB6, depending on which operating system it is running on), please refer to note #1711300, on this particular information:

< D024156 JAN/13/2011>

Optional: For the parallel processing of changes to tables in the update

phase PARCONV_UPG, an improvement is available in the database IBM DB2

for i. This improvement allows a higher number of parallel processes,

which reduces the runtime of this phase. You can set the number of the

parallel processes for the phase PARCONV_UPG during the configuration

phase of the update. You should set this value to at least 8 parallel processes.

For systems with a high CPU load and a high I/O performance,

you can increase the number of parallel processes to 16. This

improvement is available with the following IBM DB2 for i PTF group

levels:

o IBM i 6.1 SF99601: 610 DB2 for IBM i Level 17

o IBM i 7.1 SF99701: 710 DB2 for IBM i Level 4

Install the PTF group levels mentioned above before you start the procedure.

1616401 - Understanding parallelism during the Upgrades, EhPs and Support Packages implementations

Version 8 Validity: 14.10.2013 - active Language English

PHASES DOWNTIME-MINIMIZED RESOURCE-MINIMIZED

SHADOW_IMPORT_UPG1uptime downtime

DDIC_UPG uptime downtime

SHADOW_IMPORT_UPG2uptime downtime

SHADOW_IMPORT_INC uptime downtime

TABIM_UPG downtime downtime

Page 2: 1616401 - Understanding Parallelism During the Upgrades, EhPs and Support Packages Implementations

Please refer to the following White Paper from IBM for more information on this: IBM Techdocs White Paper: SAP on IBM i ABAP Upgrade Performance

On this case, parallelism is defined by the number of DDLs (Data Definition Language, SQL statements that are used to define the data structure in a database).

During the configuration step (phase INITSUBST) it is possible to customize the maximum number of parallel processes to be used for uptime and downtime phases. See below:

IMPORTANT: since the introduction of the Software Update Manager (SUM), the parallelism feature is now handled differently by each tool! See below:

Resolution

- R3trans Parallelism in old SAPup and SAPehpi tools:

This is the mechanism used by SAPup releases 7.00, 7.01, 7.10, lmt_001 and lmt_002, SAPehpi all releases and SPAM/SAINT (all versions).

The value of parameter mainimp_proc is fixed by the SAPup/SAPehpi tools with a value of 2 and cannot be customized by the user. It determines the maximum number of TP processes running in parallel. That is, a maximum of 2 packages will be imported in parallel between the SYNCMARKs entries of the buffer file.

SYNCMARK: present on the system buffer, these are the entries that divide the number of packages that can be imported at same time by the upgrade/update tools. These entries are only needed when TP is allowed to import several transport requests (or packages) in parallel, and it's used to avoid that two transport requests that contain the same object are imported in parallel. So only the group of transport request not separated by a "SYNCMARK" will be imported in parallel. For example: a TP process starts new parallel R3trans jobs for every transport request in the buffer up to a SYNCMARK entry; at this point, TP will wait until the last of the started R3trans jobs has finished before starting the next R3trans (for a transport request after the current SYNCMARK).

See in the example above, the first 11 packages (TR1 to TR11) belong to disjoint Syncmark sets. The first 6 packages (TR1 to TR6) belong to the same Syncmark set, this means two packages will be imported in parallel each time at the most (because mainimp_proc is set to '2'). After TR1 and TR2 are imported, TP starts the import of TR3 and TR4, the TR5 and TR6. Only then TP proceeds to the next group of 2 packages (TR7 and TR8). For TRs9, 10 and 11, they'll be imported alone, one at a time.

The value of parameter parallel is calculated as the below table shows. It determine the maximum number of R3trans processes forked for each package, based on the number of objects of the package:

Uptime Downtime

"MAXIMUM UPTIME PROCESSES" divided by mainimp_proc

"R3TRANS PROCESSES" divided by mainimp_proc

Page 3: 1616401 - Understanding Parallelism During the Upgrades, EhPs and Support Packages Implementations

On this example, it means that up to 4 objects of each package will be handled at the same time on the Uptime phases, and up to 6 objects will be handled at the same time on the Downtime phases.

For DB2 systems there is an additional parameter MaxR3transParallel in SAPup.par config file. If the parameter parallel becomes higher than the value of MaxR3transParallel, the calculation is reversed to:

- New R3trans parallelism for SUM tool:

This is the mechanism used by SUM all releases.

Mainimp_proc is dynamic, calculated based on the number of packages between the SYNCMARKs. Optimizing the usage of hardware resources, more than 2 packages can be imported in parallel. The parallel parameter is still calculated the same way as before, dividing the number of R3TRANS PROCESSES (Uptime or Downtime) by mainimp_proc (round down). The values of mainimp_proc and parallel are recalculated for every block of packages separated by the SYNCMARK entries, optimizing the procedure. Taking the example above:

This is an example how the import looks like during TABIM_UPG phase:

>> 2013/04/22 18:29:13 START OF PHASE MAIN_NEWBAS/TABIM_UPG Running /usr/sap/SAP/T95/exe/tp pf=/usr/sap/T95/SUM/abap/var/DEFAULT.TPP checkimpdp T90 Importing for group 1/44: Setting stop mark at 'SAPK-701DRINSAPBASIS'. Running /usr/sap/SAP/T95/exe/tp pf=/usr/sap/T95/SUM/abap/var/TABIMUPG.TPP put T90 -Dmainimp_proc=1 -Dparallel=8 Importing for group 2/44: Setting stop mark at 'SAPK-701DFINPIBASIS'. Running /usr/sap/SAP/T95/exe/tp pf=/usr/sap/T95/SUM/abap/var/TABIMUPG.TPP put T90 -Dmainimp_proc=2 -Dparallel=4 Importing for group 3/44: Setting stop mark at 'SAPKITLRD5'. Running /usr/sap/SAP/T95/exe/tp pf=/usr/sap/T95/SUM/abap/var/TABIMUPG.TPP put T90 -Dmainimp_proc=3 -Dparallel=3 Importing for group 4/44: Setting stop mark at 'SAPK-701DRINSAPBW'. Running /usr/sap/SAP/T95/exe/tp pf=/usr/sap/T95/SUM/abap/var/TABIMUPG.TPP put T90 -Dmainimp_proc=1 -Dparallel=8

parallel = 8 / 2 = 4 parallel = 12 / 2 = 6

Uptime Downtime

"MAXIMUM UPTIME PROCESSES" (suppose set to 50) divided by MaxR3transParallel (suppose set to 8)

"R3TRANS PROCESSES" (suppose set to 60) divided by MaxR3transParallel(suppose set to 8)

mainimp_proc = 50 / 8 = 6 parallel = 8 mainimp_proc = 60 / 8 = 7 parallel = 8

Page 4: 1616401 - Understanding Parallelism During the Upgrades, EhPs and Support Packages Implementations

Importing for group 5/44: Setting stop mark at 'SAPKE60028'. Running /usr/sap/SAP/T95/exe/tp pf=/usr/sap/T95/SUM/abap/var/TABIMUPG.TPP put T90 -Dmainimp_proc=2 -Dparallel=4 Importing for group 6/44: Setting stop mark at 'SAPK-603DFINEAAPPL'. Running /usr/sap/SAP/T95/exe/tp pf=/usr/sap/T95/SUM/abap/var/TABIMUPG.TPP put T90 -Dmainimp_proc=1 -Dparallel=8 Importing for group 7/44: Setting stop mark at 'SAPKGPFD07'. Running /usr/sap/SAP/T95/exe/tp pf=/usr/sap/T95/SUM/abap/var/TABIMUPG.TPP put T90 -Dmainimp_proc=3 -Dparallel=3

- Additional consideration about SPAM and SAINT:

In some occasions parallelism might not work in SPAM and SAINT, even if the corresponding settings are correctly configured and the transport tools are up-to-date. On such cases please check of the ACC_IMPORT parameter is set in the transport profile. This parameter deactivates the parallelism for SPAM/SAINT imports!

The parameter ACC_IMPORT is useful for large number of small transports. In this mode, tp and R3trans process one import after another, using interprocess communication to avoid starting/stopping of processes. For large transports (like Support Packages), this parameter is counterproductive, because it forbids parallelism. Please refer to note #1223360 for more information about it.

- How many R3trans process are forked during the import?

Looking in the correspondent import log files, it is possible to identify how many R3trans processes were forked during the import. For this, search for the message for the phrase "child processes forked". If the message is not found, no palallelism was done.

For troubleshooting about parallelism, please refer to note #1597414: "SHADOW_IMPORT phases are not using R3trans parallelism"

- Tips & tricks:

In order to avoid the error message "===> HALT: creation of child process for parallel import failed. Please contact the SAP support." during the parallel import, make sure the UNIX system is set as unlimited and the parameter MAXUPROC (Maximum users processes) is large enough, it is normal during the parallelism the user <SID>adm starts a very high number of processes;

Before starting the upgrade, make sure the database is optimized, updating statistics and parameters. In additional use the latest version of TP and R3trans;

Avoid to use NFS in the upgrade directory, it should be a local filesystem, due the high I/O volume;

Determine the value of R3TRANS PROCESSES (Uptime and Downtime) based on the number of CPU's and memory available in the server where SL controller is running, it should previously tested in a mock run system (copy of production). The rule of thumb is one parallel process per each CPU (seen in transaction ST06).

See Also

#1223360: Composite SAP Note: Performance optimization during import #1597414: SHADOW_IMPORT phases are not using R3trans parallelism #1127194: R3trans import with parallel processes

Support Package Manager Settings (to configure parallelism for SPAM) Defining the Settings in Add-On Installation Tool (to configure parallelism for SAINT)

Keywords

R3trans, parallel, mainimp_proc, MaxMainImpProc, child process, SHADOW_IMPORT_UPG1, SHADOW_IMPORT, SHADOW IMPORT, DDIC_UPG, SHADOW_IMPORT_UPG2, SHADOW_IMPORT_INC, TABIM_UPG, TABIM, tpp, tp0, config file, speed up, hang, slow, forever, dump, error, stop, windows, upgrade, enhancement package, r3up, optimize, tune up, turbo, speed, mock, copy, alternate, alternative, parconv, virtual, machine

Header Data

…/abap/log/SAPHB70105.CPT

1 ETP153 DICTIONARY IMPORT

4 ETW000 > parallel 3 <-- calculated according the .TTP file

4 ETW000 3 child processes forked <--number of R3trans child executed in parallel

…/abap/log/SAPKB70105.CPT

1 ETP187 R3TRANS SHADOW IMPORT

4 ETW000 > parallel 3 <-- no parallelism done if there is no message “child processes forked”.

Page 5: 1616401 - Understanding Parallelism During the Upgrades, EhPs and Support Packages Implementations

Product

Released On 14.10.2013 13:55:33

Release Status Released to Customer

Component BC-UPG-TLS-TLA Upgrade tools for ABAP

BC-EHP-INS-TLA Enhancement Package Installer Tools ABAP

BC-UPG-OCS-SPA Support package tools for ABAP

Priority Normal

Category How To

Product Product Version

SAP ERP SAP ERP 6.0

mySAP ERP 2004

SAP NetWeaver SAP NetWeaver 2004

SAP NetWeaver 7.0

SAP NetWeaver 7.3

SAP NetWeaver 7.4

SAP enhancement package 1 for SAP NetWeaver 7.0

SAP enhancement package 1 for SAP NetWeaver 7.3

SAP enhancement package 2 for SAP NetWeaver 7.0

SAP enhancement package 3 for SAP NetWeaver 7.0

Other Components