9 Replies Latest reply on Oct 1, 2015 8:18 PM by Yanick Girouard

    IO errors handling during nsh scripts

    Petr Liška


      i am running nsh scripts against servers, but sometimes happens that one of nexecs fails with IO error and i am trying to find some solution how to check if all commands completed successfully.

      i have tried to use variable $? after nexec commands, but it returns 0 each time.

      do you have some solution for this ?


      example :

      nexec -ncq ${SERVER}  cmd /c "date /T"

      echo $?

      nexec -ncq ${SERVER} cmd /c "time /T"

      echo $?



      output :

      Thu 24. 09. 2015


      I/O Error Server...



      br Petr