AnsweredAssumed Answered

How to create/delete a file in HEADER.* and TRAILER.* in V10?

Question asked by Jean-FrancoisAnctil606475 on May 16, 2014
Latest reply on Jul 2, 2014 by Jennifer_Jinhong_34
Hi,
   I would like to create a file on the system where an agents runs and I would like to do it with the HEADER.* and TRAILER.* objects. Is it possible to do that?

   Here is what I tried... In client 0, I've created the include objetc HEADER.UNIX.USER.HEAD and I put a line in it (for example: :data touch /tmp/my_file). Than, in another client, I've created a unix job that calls a unix script. If I put the call of the shell script in the pre-process tab, it works (the file is created). But if I put the execution of the script in the Unix tab, it doesn't work (the file is not created).

   I've also created the include object TRAILER.UNIX.USER.END in client 0 and in the process tab, I put this line: :data rm -f /tmp/my_file. So, when I execute my unix job, the file is deleted, but the job will always end normally, even if the bash script has an exit 1 at then end...

   Hope I didn't confuse you  :-)

J-F

 

Outcomes