SAP Integration Experts – DataXstream

Command Line Driven Transporting Using the ‘tp’ Command

STMS is a very powerful transaction in the BASIS world.  The whole transport system in SAP is paramount to it’s functionality.  99% of the time, you will use STMS for your transport needs.  What of that last 1%?  Sometimes it becomes more efficient, or just safer, to have a little more manual control.

It is possible to add transport requests to the buffer, and even import them via the CLI (Command Line Interface).  Keep in mind, whenever working on an instance at the OS level, you should be logged in as [sid]adm.

To add transports to the buffer: tp addtobuffer [transport number] [SID] Client=[client number] pf=/usr/sap/trans/bin/TP_DOMAIN_[DOMAIN_SID].PFL

If I wanted to add transport number DV1K907046 to the buffer for Q01 client 400 and the transport domain controller was DV1 the string would look like this: tp addtobuffer DV1K907046 Q01 Client=400 pf=/usr/sap/trans/bin/TP_DOMAIN_DV1.PFL

To import transports via CLI: tp pf=/usr/sap/trans/bin/TP_DOMAIN_[DOMAIN_SID].PFL import [transport number] [SID] U128 client=400

Since I’ve added DV1K907046 to the buffer, I can now import it with this string: tp pf=/usr/sap/trans/bin/TP_DOMAIN_DV1.PFL import DV1K907046 Q01 U128 client=400

It is also possible to create shell or batch scripts from these commands to do multiple transports at one time. I’ve found that this is when CLI tp management is most effective. Using your favorite text editor, simply “stack” the commands ontop of each other: tp addtobuffer DV1K907046 Q01 Client=400 pf=/usr/sap/trans/bin/TP_DOMAIN_DV1.PFL tp addtobuffer DV1K907047 Q01 Client=400 pf=/usr/sap/trans/bin/TP_DOMAIN_DV1.PFL tp addtobuffer DV1K907048 Q01 Client=400 pf=/usr/sap/trans/bin/TP_DOMAIN_DV1.PFL .... Then save as either a .sh for Unix or .bat for Windows.

The batching approach works for both adding to the buffer and for actual import. It’s best to seperate each task (addtobuffer in one script, import in another).

Q2Q3Y6XJM37U

Share
  • Digg
  • Facebook
  • Google Bookmarks
  • LinkedIn
  • Twitter
  • del.icio.us
  • StumbleUpon
  • Blogosphere News
  • Reddit
  • RSS
  • Slashdot
  • Technorati

Speak Your Mind

Tell us what you're thinking...
and oh, if you want a pic to show with your comment, go get a gravatar!

SAP Integration Experts – DataXstream