File Adapter OS command to unzip files

Hi all,
I need an OS command or a script which unzips a file in the XI folder.
Appreciate your response
-Keerthi

cmd /C "jar cvfM
10.11.128.28\sapmnt\put\TEST\test.zip -C
10.11.128.28\sapmnt\put\TEST\zip ."
This will create a zip folder named test.zip in directory
10.11.128.28\sapmnt\put\TEST\ . The contents of the zipped file will be taken from
10.11.128.28\sapmnt\put\TEST\zip
regards
Ninad

Similar Messages

  • File adapter OS command line - Calling a command remotely ??

    Hi,
    We have a scenario where in which receiver file adapter after putting a file on the FTP  , a subsequent XML loader needs to be called which would load data into the client legacy ERP system.
    There seems to be some idea about doing it through file adapter OS command line.
    The problem is the how to call this loader command remotely from our file adapter OS command line.
    Any help would be appreciated ???

    >> The problem is the how to call this loader command remotely from our file adapter OS command line.
    The below link might be helpful ...
    http://wiki.sdn.sap.com/wiki/display/XI/SAPXIFileAdapterOSCommandLine+Feature

  • Sender file adapter is not polling the file.

    Dear all,
       Sender file adapter is not polling the file.(But Receiver file adapter is getting the file)
    we have installed SP15.
    It was worked fine for previous SP14.
    I have cheked in Adapter monioring also.
    Can you help me out of this problem
    Regards
    Dhanabal

    Hi Dhanabal,
    Is the XI system running on a unix machine ?
    If yes, from the OS level for the folder you are using in the file comm. channel, execute the command
    <b>chmod 777 <folder_name></b>
    The reason for the file to show up in receiver side and not get deleted might be that the xi user mighht be having only read access to the folder...
    Thanks,
    Renjith.

  • Need Help-SOA 11g File Adapter unable to delete input file and its crashing

    Hi All
    Please find the details below:
    1. We have created a simple SOA composite to Read file from an input directory, archive the file in an archive directory using Inbound File Adapter Read
    and then use Outbound File Adapter Write to move the file to a output directory.
    2. File Adapter needs to delete the file after successful read/retrieval.
    3. We are using the "Use Trigger File" for invoking the file adapter. This is a new feature in SOA 11g
    4. Also we are using the option of reading the file as an attachment as we are not doing any transformation in the composite
    Issue Details_
    1. When the trigger file is put in the input directory for the first time, the File Adapter reads the file, archives it and moves it to the output directory
    2. However it does not delete the input file from the input directory and raises Fatal Exception mentioned below:
    [*2011-01-12T16:55:48.639+05:30] [soa_server1] [WARNING] [] [oracle.soa.adapter] [tid: weblogic.work.j2ee.J2EEWorkManager$WorkWithListener@19c243d]*
    [userId: <anonymous>] [ecid: 0000IptyLrL9_aY5TrL6ic1DBOS_000009,0] [APP: soa-infra] File Adapter FileAdapterTriggerFilePOC PostProcessor::
    Delete failed, the operation will be retried for max of [0] times
    [2011-01-12T16:55:48.639+05:30] [soa_server1] [WARNING] [] [oracle.soa.adapter] [tid: weblogic.work.j2ee.J2EEWorkManager$WorkWithListener@19c243d]
    [userId: <anonymous>] [ecid: 0000IptyLrL9_aY5TrL6ic1DBOS_000009,0] [APP: soa-infra] File Adapter FileAdapterTriggerFilePOC [[
    BINDING.JCA-11042
    File deletion failed.
    File deletion failed.
    File : C:\Dibya\AttachmentTest\InputDir\TestFile3.txt could not be deleted.
    Delete the file and restart server. Contact oracle support if error is not fixable.
    If any one has faced similar issues, kindly provide pointers on how to resolve it.
    Regards,
    Dibya

    Hi,
    Using the file adapter, you can poll from multilple locations...
    Keep the following property in your .jca file
    <property name="DirectorySeparator" value="," />
    While giving the path in File Adapter configuration, keep comma and give the next location....then the file will be picked up from the locations you gave....
    Hope this helps...
    Thanks,
    N

  • File adapter should pick a single file at a time

    Hi,
        I have File to RFC scenario.. in my source directory  I'm getting bunch of files with  the same name.  at a time.. but  i want to pick the one by one only. that means.. my file adapater poll interval is 30 seconds.. every 30 seconds it will pick the one file.. even though there are multiple files.. but my file adapter should pick a single file ata time..
    but at present my file adapater was picking all the files ata time..  but i want to make my file adapter should pick single file ata time..
    for this.. any special  configuration we need to do..  or  any  ideas or suggestion  .. will be.. appriciated..
    regards
    Babu

    >>any special configuration we need to do..
    there is no default configuration to achieve this functionality.
    I speculate that any of this should work.
    1. Post the files to a intermediate directory and use a SCRIPT/Batch program to move only one file at a time frame to the source directory.
    2. Uncheck the option Process Read only files in the sender CC to prevent the file adapter to pick the read only files. Use a script that changes the permission of one file at a time so that the file adapter will pick that file alone.
    In both the cases the script needs to be scheduled at the OS level to run every 30 seconds.
    Thanks
    SaNv....

  • Error in reciever file adapter , where i am getting file name dynamically

    hi all,
    error in reciever file adapter , where i am getting file name dynamically, please help me in this isssue , i am trying for a long time
    MP: Exception caught with cause com.sap.aii.af.ra.ms.api.RecoverableException: Exception in XML Parser (format problem?):'java.lang.Exception: Message processing failed in XML parser: 'Conversion configuration error: Unknown structure 'ns0:MT_eINVOICE_RECV' found in document', probably configuration error in file adapter (XML parser error)': java.lang.Exception: Exception in XML Parser (format problem?):'java.lang.Exception: Message processing failed in XML parser: 'Conversion configuration error: Unknown structure 'ns0:MT_eINVOICE_RECV' found in document', probably configuration error in file adapter (XML parser error)'

    i am getting new error
    MP: Exception caught with cause com.sap.aii.af.ra.ms.api.RecoverableException: Channel has not been correctly initialized and cannot process messages
    this is my strcuture
    and i have changed my structure
    <HEADER>
    <ADDRESS1/>
    <ADDRESS2/>
    <ADDRESS3/>
    <ADDRESS4/>
    </HEADER>
    <HEADER_GST>
    <TAX1/>
    <TAX2/>
    <TAX3/>
    </HEADER_GST>
    <LINE>
    <QTY/>
    <UOM/>
    <UNIT_AMT/>
    <CHARGE_TO_DT/>
    </LINE>
    <FILENAME>
         <FILENAME/>
    </FILENAME>
    i have given the recordset structure as
    HEADER,HEADER_GST,LINE,FILE

  • Sener file adapter has read/pick the files first in first out method.

    HI
    In my Interface I am Using Sender as File adapter. As per my requirement Sender file adapter has to read the file from file directory. This directory having 1000u2019s of files with some files are same name (time stamp is different) and some files are different name here file adapter has to pick the file with mentioned name   in File sender adapter like ZMPSMSGSTATUSMST-.xml .
    But source file name is like <TABLENAME>-<TIME_STAMP>.XML (ZMPSWRKFLOWHIST-20090527-150522-628) in file directory.
    The file adapter in XI will poll to this directory and picks the file in first- in first-out by sorting according to timestamp.
    To do this configuration what I have to do in sender file adapter please give me your valuable inputs.

    HI Abhi,
    Thank you for your spot replay.
    I tested now but i am geting below error.
    Putting message into send queue failed, due to: com.sap.aii.af.ra.ms.api.DuplicateMessageException: Message ID f4ca4f86-9c5d-4bdd-1fb1-a6bd7cda99a8(OUTBOUND) already exists in database: com.sap.sql.DuplicateKeyException: [NWMss][SQLServer JDBC Driver][SQLServer]Violation of PRIMARY KEY constraint 'PK__XI_AF_MSG__491A1D0B'. Cannot insert duplicate key in object 'dbo.XI_AF_MSG'..
    Could not archive file 'E:\file\in\ZMPSMSGSTATUSMST-20090527-150522-628.xml' after processing
    but i am able to see this file in Archive foleder. once file is archivied sucessfully the same file is delted from source directory?
    I given processing parametes queue name is TEST.
    Thanks
    srinivas
    Edited by: srinivasreddy p on May 28, 2009 8:43 AM
    Edited by: srinivasreddy p on May 28, 2009 8:52 AM

  • File Adapter and reading all XML files from direcotry

    Problem occurs on PI 7.1
    I defined sender file adapter. File name mask is: "*.xml" to read all XML messages from directory.
    Quality of service is: Exactly One.
    Poll Interval: 30
    Retry interval: 30
    Processing mode: Archive with option "Add Timestamp".
    Processing sequence: by name.
    I though that with above configuration my File Adapter will be reading folder for all coming XML files. But  somehow it is reading XMLs only when I'm activating it in Integration Builder.
    Any idea what can cause such strange problem?

    Hi Tomasz,
    As per my understanding, you need to activate the file adapter for reading the XML files on your directory. Right?
    If that is the case, then the issue might be with the Cache.
    1. Clear the cache from the Integration Builder.
    2. Check in SXI_CACHE whether there are any issues. Click on Delta Cache refresh to find out if there are any cache related issues.
    Thanks,

  • PI Sender File Adapter OS Commands not working

    Hi Guys,
    I have very simple scenario. we are using PI 7.1 with EHP1 on HP hardware with JDK 1.5.2*.
    We are processing XML files through Sender File Adapter(NFS) to Idocs. We also need to move some pdf documents to target folders on the same box (basically Sender and Receiver files/foders are mounted to PI OS hence I am using NFS)
    I am trying to put a simple OS command copy and mov command.
    in the Before Message Processing: cp /tmp/*.pdf /tmp/out/
    And in the After Message Processing: mv /tmp/*.pdf /tmp/archive/
    In the Adapter Audit logs says these commands are executed but I don't see any effect and there is no error/Traces available even in the Server logs also.
    I have been using these OS commands since XI 3.0 I never had any issue.
    I have gone through SDN but no luck, Please share your experiences.
    Thanks,
    Laxman
    Edited by: Laxman  Molugu on Feb 3, 2010 11:58 AM
    Edited by: Laxman  Molugu on Feb 3, 2010 11:59 AM

    hi ,
    As i understand your requirement you just want to take the pdf file from one folder of XI server and put it to another..
    for this u do not need a OS command..
    This requirement is simple ..infact u do not need any IR components as well..
    u just have to develop the ID part and wherever it asks for namespace or message interface u can give a dummy one..
    this would jst take the pdf file from one folder and send it to another

  • Execution of remote script in File Adapter OS Command

    Hello.
    I'm having issues with a remote script placed on a file adapter which fails to execute in a clustered PI (Version 7.1), running on Windows 2008.
    Our current setup is as follows.
    - Machine A and Machine B make up a SAP PI Cluster node.
    - Machine C is our network file share, used as a sandbox for receiving and sending files.
    One given scenario would be having the Cluster picking up a file from a FTP folder (Machine D) and copying it over to a given location in Machine C. This is working without problems in the cluster environment.
    Now, a very specific scenario requires that after copying the file (to folder INPUT), a given script shall be executed over the received file and decide which folder should that file be archived, TO_PROCESS or NO_PROCESS folders.
    So, Outbound Channel is reading from the FTP, Inbound Channel stores in Machine C and has to run a script after message processing.
    The problem here is that the script is stored also in Machine C, so placing the OS Command should refer to a shared path:
    Example:
    sap-machine-c.gca.ad.root\InboundFiles\INPUT
    sap-machine-c.gca.ad.root\InboundFiles\TO_PROCESS
    sap-machine-c.gca.ad.root\InboundFiles\NO_PROCESS
    sap-machine-c.gca.ad.root\Scripts\procFile.bat
    If I give the command of "
    sap-machine-c.gca.ad.root\Scripts\procFile.bat %F" on the receiver channel, checking RWB, Communication channel says the command was executed with success but the file doesn't leave the INPUT folder.
    The script is know to execute with success from both instances, I have logged into each one of them and executed with RFCUSER in SE38 w/transaction RSBDCOS0.
    I have tried to replicate this issue, reducing even the procFile.bat script to just do an "echo" command but still doesn't work (RWB PI says it does).
    It seems to me that executing scripts from remote shares is a no go? Does anyone have a previous experience dealing with these cases?
    Thanks,
    Romeu

    Hi all.
    After taking some hints from this thread, we have found out that the problem lied some where in the installation part of PI.
    We've set up a basic script, local and not remote, and still the system would not execute that command.
    The RWB logs showed successful processing but the Application Server logs were full of errors and stack traces regarding the execution of any command. A support note was raised with SAP support in order to trace these errors.
    I'm therefore closing this question as the original question is not related with remote scripting.
    Thanks all for your help.
    Best regards,
    Romeu

  • Sender File adapter is not picking up file

    Hi,
    I am usning the sender file adapter to process a file through FTP. Adapter does not pick up the file, however it recognise the file, as it appears in the error message. Below is the text of the error message:
    <i>Could not process file '<b>filename</b>': com.sap.aii.adapter.file.ftp.FTPEx: 550 toSAP: No such file or directory.</i>
    I am not sure yet whether this file is <b>read only</b>. Can read only file not be processed in FTP ?
    Thanks

    Hi, I have the same problem. In advance, we can see in FTP Server log that CWD command it is called twice, for example :
    00:00:59 10.15.64.187 [4669]USER MDM 331 0
    00:00:59 10.15.64.187 [4669]PASS - 230 0
    00:00:59 10.15.64.187 [4669]CWD MDM_55600_MATERIAL_STD\Outbound\ESN_800\_MATMAS05\Ready 250 0
    00:00:59 10.15.64.187 [4669]CWD MDM_55600_MATERIAL_STD\Outbound\ESN_800\_MATMAS05\Ready 550 3
    00:01:59 10.15.64.187 [4669]QUIT - 550 0
    If we create a directory MDM_55600_MATERIAL_STD\Outbound\ESN_800\_MATMAS05\Ready into the first directory Ready where it is positioned with first cwd , its works !!
    First CWD is called for read file an seccond for processing, somebody knows because this behavior ?
    Best Regards
    Claudio Maino

  • How file adapter has to pick .stub file???

    Hi guys,
    Sap system is generating a .stub file.if that file exist then only adapter will send the data to pi.
    Can we have some settings in Sender File Adapter where in we can Put check condition for .STUB file.
    I mean, If .STUB file is present in ECC directory only than PI will Pick the File.
    If .STUB file exist, we need to pick some other file.
    If we want to go with unix script, From were we need to get that unix script file. and were we need to use .in file adapetr or some were else??
    --> Do you have any example script? If yes, please share.
    --> is there advance function in Sender File Adapter to pick that file?
    please advice
    Regards,
    Naren
    Edited by: Narendra Surepalli on Oct 17, 2011 8:20 AM

    Naren
    with "Run operating system command before message processing" you can call a script on your server.
    The script can check if there is a file .STUB exist on server or not.
    You can serch for unix commands for check if file exist.
    One example:
    test -e $file_name && echo "file exists"
    from http://www.unix.com/unix-dummies-questions-answers/5361-how-check-if-file-exist-not.html
    You can check others as well.
    Regards
    Raj

  • File Adapter. How to set file creation mode (ex. 666)?

    Hi All
    I'm using Outbound File Adapter to write files.
    Adapter creates the files whit access mode 622 (rw-r--r--).
    My requirement is to have files in 666 access mode.
    How can i achieve that?
    Thanks,
    Oleg.

    Hi,
    This can be done by user via umask command...
    Have a look at this...
    http://www.avajava.com/tutorials/lessons/how-do-i-set-the-default-file-and-directory-permissions.html
    Cheers,
    Vlad

  • File Adapter - how to get the file count from a folder

    Hi All,
    I have a requirement that have to poll a directory when the file count is reached to number N (ex:number of files avilable in folder is 5) otherwise it should wait and not pick any of the files. Is it possible to get the file count from a folder using file adapter ?? otherwise please suggest me an approach to achieve this requirement.
    Thanks,
    JJ

    Hi Sarath,
    Thank you for your reply.
    Go with the list files operation of file adapter it will gives you the number of files in the specified folder as you given. . - this step is already done.
    When the number of files reaches your count startup your webservice that which can polls the files. . . - how can i acheive this?? Have to poll the directory and process the number files - please let me know, what could be added to the webservice which is being invoked after cheking file count from parent process.
    The reason for the above question is - we cannot use ReadFile operation in second webservice because it will be automatically triggered when the file is avilable. Also SyncRead operation supports reading one file in b/w bpel process. Kindly explain me the implementation steps.
    Thanks,
    JJ

  • File Adapter: Different lines in one file

    Hi,
    I receive a flat file where I have to do content conversion.
    In this file, I have different structures which could appear unsteady.
    Means, every could structure appear in a non continuous way:
    File:
    struc1
    struc2
    struc3
    struc3
    struc3
    struc1
    struc1
    struc2
    struc3
    How to handle this in file adapter?
    Regards
    Chris

    Hi,
    do you mean like this:
    /people/jeyakumar.muthu2/blog/2005/11/29/file-content-conversion-for-unequal-number-of-columns
    How to identify the different structures? Every structure got different fields and different
    amount of fields.
    Every struc1 to struc3 should be a single message.
    And how to specifiy line break in file adapter?
    thanks
    chris

Maybe you are looking for

  • When a site asks for a client certificate, not all certificates are presented.

    At www.pkiuniversity.com/sandbox/index.php, I am asked for a client certificate. I get to choose from a list of the certificates issued by startcom but not my own. The extended key usage does mark it for client authentication. The root certificate co

  • How do I backup my iPhoto database?

    I have about 2,500 photos in iPhoto. Although I use Time Machine to backup my entire Mac to an external drive, I'd also like to backup my photos to a DVD just to have a super safe archive copy. When I go to the Picture folder, I see the iPhoto librar

  • Extra Selection mask in HCM Reporting WebDynpro

    Hi SAP Experts, we integrate a new SAP Standard Report in our Report Scenario in Portal.But when we select a organizational unit in step 2 this selection seems to be ignored by the system. In the next step we get the standard sap report selection mas

  • Launching programs from adobe reader on linux/unix

    I am hoping someone has solved this problem before: We use pdf for our product manuals and have a large set of examples that we want to allow the user to open by clicking a button. In past releases (pre 8.0 et al) we have not had a problem opening th

  • Opening 16bit TIFF files in the Photoshop RAW dialog

    Quite recently I've found that doing my final adjustments in Camera RAW on renders from 3D programs, particularly Vue 6 Infinite images saved as 16 bit TIFFs, yields superior results very quickly. So far I've found that I can access Camera RAW only f