Hey Mohit,
What is the absolute path to the sshpass command in the second environment('whereis sshpass' .. or 'which sshpass') should reveal this.
I would imagine it is likely in the $PATH env variable set by root(or global) profile, however the agent may not inherit all these. If you could do the following test real quick in the second/non-working environment:
1. Create another process with a run command line action
2. set the command to run as: echo $PATH
If you compare the output from both agents do you get different results(one with sshpass in the environment PATH var)?
Let me know if you have any questions, thanks.
Jeremy