Where is psexec exe located
Improve this question. Anthony Anthony 1 1 silver badge 6 6 bronze badges. What does procmon on the server show when you try to fire off the command? Is it because this script is run against a bunch of servers and you don't necessarily know the OS on the server? Looking for the exe? Add a comment. Active Oldest Votes. I so love sysinternals. Improve this answer. Shial Shial 1, 1 1 gold badge 9 9 silver badges 14 14 bronze badges. However, in what way is the path "messed up"? When you type in the command windows tries to look at each entry in the filepath for the executable.
I'm guessing it saw the " and began appending that to filepaths plus your executable — Shial. I normally exclude out most background processes and whatever else isn't needed to narrow it down faster. Shial, when I say "cmd worked fine" I mean that cmd can find nant on the path. My guess is the latter. Might try: -i Run the program so that it interacts with the desktop of the specified session on the remote system.
Let me know, -Mathew. MathewC MathewC 6, 8 8 gold badges 37 37 silver badges 53 53 bronze badges. I emailed Mark the author. The little keypad that come with it was nice I wanted to light the hall at night when I got up.
Then a couple years ago in Winter I was thinking how nice it would be to come home to lights and was looking for away to just use a computer as a clock to turn them on.
I just went from there. There is still nothing fancy here I just turn on a few lights from work or my phone during the months it gets dark early. I had ideas similar to yours but ended up moving my office to my home about 3 years ago and never really got much done. I have used a couple of the modules to turn lamps on and off while on vacation a few times, but never much beyond that. I always wanted to hard wire the house with every outlet and switch controllable, but never got there.
Now we are preparing to move to a new state so it will probably be a few years before I get around to messing with it again. Also I understand many of the dynamic services can take up to a day to get propagated.
My method leaves me down at most 2 hours plus a few minutes. I was able to follow your directions and added PsExec. The example PsExec. Or, if the test program is already installed on the remote computer the following example statement was given:. However, when I put either of these statements into my VB. Note slight difference. But Michael may be correct and there is no space so if one fails try the other.
I agree it is an excellent VB. NET forum. Actually Rob I wish it attracted more VB. NET questions. Thank you both for your help. Thanks for providing the specific statements — my first attempts failed to execute anything on the remote computer. I found it trying to solve the IP issue for my ftp site. NET is the hardest for me to remember all of the commands, etc. I just downloaded it and will give this a try.
That is the only drawback to my current system. Rob, what I imagine most services like this do is have you install an app that sends an HTTP Request to their server or some other server and now they have your out facing IP of course some sort of polling mechanism is employed such that this repeats in a timely manner. This is pretty much what I do with my own application that I coded and have been using for a couple of years.
John Warner. The only real advantages to these services are that you get a sub domain instead of an IP to talk to which may not matter and with the ones that a router can talk to , you no longer have to use an app running on a machine to do it, but can offload that work to your router. EXE only as a test program on the remote computer at this point. The first of the two example commands you posted is almost right. The problem is that there are spaces in the remote command.
The Shell function passes its single argument to the local command processor, which then invokes psexec and passes it four arguments:. The simplest way to do that is take advantage of the fact that Visual Basic will treat a pair of double-quote characters as an escape sequence, representing a single character a double-quote in the string:. I tried the following with no success no error message , nothing happens on the remote computer?
I tried the following statement and it worked! You may need to pass it a usernname and password unless your user is setup on the remote pc and has enough permissions or its c: drive is shared. If you omit a username the remote process runs in the same account from which you execute PsExec, but because the remote process is impersonating it will not have access to network resources on the remote system.
When you specify a username the remote process executes in the account specified, and will have access to any network resources the account has access to. Note that the password is transmitted in clear text to the remote system. Usage usage: psexec computer [-u username [-p password]] [-s] [-c [-f]] [-d] program [arguments] -u Specifies optional user name for login to remote computer.
If you omit this you will be prompted to enter a hidden password. Only use this option for non-interactive applications. Input is only passed to the remote system when you press the enter key, and typing Ctrl-C terminates the remote process. Thanks for your help in formatting folders with spaces in the names.
This will be relevant for my final application. Neither of these works no error messages, but nothing happens on the remote computers either.
So it seems that the problem is in accessing the remote computers, not the folder name space problem? The c: Drives on both of the other two computers on my home LAN are shared. I can get to notepad.
Forget VB for a moment and bring up a command window and literally work out the exact command sequence require by PsExec to run notepad on the target computer. If we can get it working we can always wrap this in a simple cmd or bat file. Since I can access the notepad. Not a very good assumption-could be a firewall rule that allows that access, but this thread seems to have a lot of assumptions in it.
The command you just quoted to me will open Notepad on the computer the command is issued on. I think you left something out. Actually try using this switch: -s Run remote process in the System account. Is this the problem? PsExec's most powerful uses include launching interactive command-prompts on remote systems and remote-enabling tools like IpConfig that otherwise do not have the ability to show information about remote systems.
Note: some anti-virus scanners report that one or more of the tools are infected with a "remote admin" virus. None of the PsTools contain viruses, but they have been used by viruses, which is why they trigger virus notifications. Input is only passed to the remote system when you press the Enter key. Typing Ctrl-C terminates the remote process. If you omit a user name, the process will run in the context of your account on the remote system, but will not have access to network resources because it is impersonating.
Note that the password and command are encrypted in transit to the remote system. This article I wrote describes how PsExec works and gives tips on how to use it:. This command copies the program test.
Specify the full path to a program that is already installed on a remote system if its not on the system's path:. PsExec is part of a growing kit of Sysinternals command-line tools that aid in the administration of local and remote systems named PsTools. Feedback will be sent to Microsoft: By pressing the submit button, your feedback will be used to improve Microsoft products and services. Privacy policy.
0コメント