cancel
Showing results for 
Search instead for 
Did you mean: 

Calling unix scripts in File Adapter

Former Member
0 Kudos

All,

we have a script recindicator.sh in the root of the unix server. This script take 1 parameter.

In the File adapter - "Run Operatning System Command After Message Processing" - we put the following,

recindicator.sh %f

we see the adapter working, but we are not seeing the effects of the script which is supposed to create 2 different files.

Can we run scripts in the "Run Operatning System Command After Message Processing" ? If yes, what is wrong with our configuration?

When we run the script directly on the server, with the parameter - it is working. so no issue in the script.

Thanks,

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Change recindicator.sh %f to <b>recindicator.sh %F</b> and give a shot. Also you can run the script only when it is in XI server only.

Regards,

---Satish

Former Member
0 Kudos

Hi,

Yes, the script is in XI server. we tried with %F also, it is not working.

At what directory level is the command that we give in the configuration run? is it in the root? or some other SAP folder like - "/SAP/user/..."?

Thanks.

Former Member
0 Kudos

Hi,

Where ever you put on the xi server put the command PWD which gives the directory and put the same in XI communicaiton channel. It should work. Also please give the log from the adapter communication channel.

Regards,

---Satish

Former Member
0 Kudos

Try calling the script with the following syntax from the file adapter

<b>sh recindicator.sh %f</b>

Also make sure that script has sufficient permissions to be called from XI's internal unix user from file adapter.

Former Member
0 Kudos

Hi - what is XI's internal user id in unix? where can we find it?

thanks.

Former Member
0 Kudos

check for any file created by the XI file adapter at unix level using command ls-ltr and it will display the user who created the file. This will be the user which will be used for exceuting the shell script from file adapter. This user should have permissions to execute the script. You can try executing the script from the file adapter by giving full permissions to execute the shell script (777).

Answers (1)

Answers (1)

Former Member
0 Kudos

Make sure you give the full path. Since you said its a unix system also check the path, whether it uses the backslash/forward slash.

Thanks,

ravi