none
Error Occurred when running batch (that calls powershell scripts) from TWS (Tivoli Workload Scheduler) RRS feed

  • Question

  • Hi, 

    Im currently in a project that need to run batch file (that calls a powershell script) from TWS (Tivoli Workload Scheduler).

    (TWS -> Batch File -> Powershell Script)

    I have overall 30 of this and only 2 scripts failed showing the following error message:

     The OS handle's position is not what FileStream expected. Do not use a handle simultaneously in one FileStream and in Win32 code or another FileStream. This may cause data loss.

    This error is displayed around the end of my processes, meaning that the process has been successful until near the end of the script.

    I have checked some other forums/discussions mentioning that its a redirection problem or because the scheduler is x32bit and the powershell is x32bit.

    (http://connect.microsoft.com/PowerShell/feedback/details/587165/powershell-double-redirection-problem)

    However, the script executed successfully if i run it from Task Scheduler (Therefore I am suspecting the problem to be coming from TWS running the batch file)

    I was wondering, Have anyone experienced this kind of problem with TWS before?

    If this is really the problem for this case, which, TWS, Batch or Script should i modify to?

    Thanks in advanced

    Cindy


    Tuesday, December 24, 2013 10:02 AM