cancel
Showing results for 
Search instead for 
Did you mean: 

OS commands in FTP adapter

Former Member
0 Kudos

Hi Experts,

we are trying to use the OS command in the sender FTP adapter to compress the huge text files(approx 2 GB) before we pick the file to avoid the server issues.

for which we are using the OS command,

ssh -n -l user targetserver "cd /tagetdirectory; compress ExportFile.xml;mv ExportFile.xml.Z ExportFile.xml"

The above is a single command supplied by the Basis team.

the above command makes the connection to the target server with the user ( password not required)and then compresses the file.

I used the command in the sender FTP adapter as is.

But the message processing made the XI server unavailable and the process got failed due to HTTP_TRANSMISSION_ERROR

Please suggest on the OS command, Is it a right command ? or do I need to add anything to it, to make it work.

Please note that for the File Adapter transport protocol "FTP", the operating system command is NOT 
executed on the FTP server, but on the server hosting the Adapter Engine ( please refer to 
SAP note: 841704).

Thanks,

MK

Accepted Solutions (0)

Answers (1)

Answers (1)

MichalKrawczyk
Active Contributor
0 Kudos

Hi,

>>>Please note that for the File Adapter transport protocol "FTP", the operating system command is NOT

executed on the FTP server

as you probably noticed OS commands do not work on FTP

I'd suggest creating a script that woudl compress the file (it can be scheduled) and

the script should then copy the file to FTP folder from which XI can pick compressed file

Regards,

michal

Former Member
0 Kudos

Thanks Michal,

For "FTP" the command will be executed on the but on the server hosting the Adapter Engine, right?

ssh -n -l user targetserver "cd /targetdirectory; compress ExportFile.xml;mv ExportFile.xml.Z ExportFile.xml"

the command above is opening a secure channel from the XI host to the FTP host. We have a trusted relationship set up between the xiadm and ftpadm users which will allow this to occur without a password. and then it compress the file.

Please suggest further to resolve the issue.

I really appreciate you help.

Thanks,

MK