I have created a batch file using PsExec to run batch files on different PCs. This 'master' batch runs PsExec on 14 remote PCs. However, for some reason, it doesn't always work on a few PCs. Sometimes it does, and sometimes it does not. I have tried to debug by making changes in my anti-virus firewall settings, and that seems to have fixed the problem in one such PC, but not the other one. This issue only appears to be for these PCs. The code is the same for all the PCs:
psexec -i 1 -h -d \\(pc name) -u (username) -p (password) "(batch name).BAT"
There is also a code in the beginning which asks if the user is sure they want to run the batchfile, but I don't think that is the reason for this issue.
SET /P AREYOUSURE=Are you sure (Y/[N])?
IF /I "%AREYOUSURE%" NEQ "Y" GOTO END