PsExec is not recognized as an internal or external command
I have a job that needs to run a script on a remote machine. I do this using psexec via the "Execute windows batch" command:
C:\PsExec.exe \\computername -u username -p password -accepteula c:\xxx.exe
When I run the job, I get the following error:
c:\PsExec.exe is not recognized as an internal or external command
** PsExec.exe
is underc:\
Any ideas?
source to share
One possible explanation is the version PsExec.exe
: 32 bit or 64 bit.
If you have 32 computers on a 64-bit machine, this command will not be recognized. PsExec64.exe
will be.
source to share
I can see the age of this question and my answer may not be relevant to this topic as I was technically trying to solve a different problem, but maybe it will help other people who are stuck.
c: \ PsExec.exe is not recognized as an internal or external command
I tried to disable the Service Configurator using PSExec (my problem is infinite service error) and kept running with the same error as OP BUT I got PSexec64 to execute this command:
C: \ PsExec64.exe -s schtasks / change / tn> "\ Microsoft \ Windows \ TaskScheduler \ Service Configurator" / DISABLE
By checking the "Run this program as administrator" checkbox under "Compatibility Options" for PsExec64.exe
Not sure if that solved my problem, but I think the OP would be able to start his process if he did. Dear OP, have you ever solved this?
source to share
First, define the path to psexec.exe in your PATH environment variable or put the psexec.exe file in C: \ Windows \ System32 \
And download the Psexec.exe file https://download.sysinternals.com/files/PSTools.zip
source to share