cancel
Showing results for 
Search instead for 
Did you mean: 

SFTP - Run Operating System Command - shell script

Former Member
0 Kudos

Hi,

Am working on SAP PO 7.5 and in the receiver SFTP folder - able to place the files but need to call the shell script as well.

SAP PO is on Windows Server operating system and Shell script is available in the receiver SFTP location.

1. Does the command line for 'Run Operaitng System Command After Message Processing' expects the script path on SFTP folders or expecting the script path on NFS directory?

2. If expects path on SFTP folder, how do i execute a shell script stored on SFTP location from SAP PO receiver SFTP channel (Windows Environment)?

While trying to call shell script stored on SFTP location from SAP PO receiver SFTP channel - getting below error.

Error while executing OS command: ./tmp/TEST_SAPPO/test.sh

Thanks in advance.

Thanks,

Sandeep B.

Accepted Solutions (0)

Answers (1)

Answers (1)

Harish
Active Contributor
0 Kudos

Hi Sandeep,

Please refer the below wiki

SAP XI File Adapter OS Command Line Feature - Process Integration - SCN Wiki

1. Does the command line for 'Run Operaitng System Command After Message Processing' expects the script path on SFTP folders or expecting the script path on NFS directory?

-->> The script should be in SFTP folder and create a batch file to call the above script file and upload to PI.

2. If expects path on SFTP folder, how do i execute a shell script stored on SFTP location from SAP PO receiver SFTP channel (Windows Environment)?

--> You are assigned the role SAP_XI_CONFIG_FILE_OS_CMD_J2EE to authorize you to define operating system commands. and have raed/write permission to SFTP folder to execture the script.

refer the help page - https://help.sap.com/saphelp_nw-secure-connect102/helpdata/en/b6/883e46939c42298f55fecdcd618d6e/cont...

regards,

Harish

Former Member
0 Kudos

Thanks for the response. wanted to elaborate your response and confirm.

1. Does the command line for 'Run Operaitng System Command After Message Processing' expects the script path on SFTP folders or expecting the script path on NFS directory?

-->> The script should be in SFTP folder and create a batch file to call the above script file and upload to PI.

Q: It sounds like O.S command expects the script path only on the NFS directory even for STP channel?

     Meanwhile my testing activity should get the results.