Psexec fails to display a notepad GUI on the remote session for me. So, I am trying to get the session id as below:
c:\\Users\\Amitra\\Downloads\\PSTools>
If you are just trying to run notepad on the remote machine do the following:
psexec \\135.20.230.160 -u administrator -p force C:\notepad.exe
More info on psexec
Also I am assuming your password is "force" and as a side note you should not put your password online...
If you want to see notepad.exe open on the machine you are connecting to, for example if you are remote connected into that machine while using psexec from another you would use the following
psexec \\135.20.230.160 -u administrator -p force -i 1 C:\notepad.exe
The 1
after the -i
is the session number which needs to correspond to the session which you are logged in as.
To find out what session you are currently logged in as open any program and in console type TaskList
and find your program and look at the session number.