Solved

PsExec could not start

Posted on 2010-11-18
13
4,663 Views
Last Modified: 2012-05-10
I am trying to use PSEXEC to execute a file on a local machine... I have the file placed in the c:\ of the computer that I am running psexec on... When I type in the command I get the following message....

D:\>dir d:\t.cmd
 Volume in drive D is DATA
 Volume Serial Number is 3897-F764

 Directory of d:\

11/18/2010  03:46p                   6 t.cmd
               1 File(s)              6 bytes
               0 Dir(s)   9,518,014,464 bytes free

D:\>psexec.exe D:\t.cmd

PsExec v1.42 - execute processes remotely
Copyright (C) 2001-2003 Mark Russinovich
www.sysinternals.com


PsExec could not start D:\t.cmd on DBMS-PHK1:
The system cannot find the file specified.

I've verified the file name is correct ... however it says that it can't be found? any help would be greatly appreciated!!
0
Comment
Question by:Itai_Argoetti
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
  • 2
  • +2
13 Comments
 
LVL 13

Accepted Solution

by:
NarendraG earned 500 total points
ID: 34170658

This tool only designed to execute process remotely

or try using network path

\\localpc\d\t.cmd

Good Luck
0
 
LVL 2

Expert Comment

by:SacTechGroup
ID: 34170689
shouldnt that be \\localhost

Anyhow psexec WILL execute on a local machine when no computer name is provided

It is stated that the file to be executed is on C:\ but that path is never called.  If i had an executeable at say 'c:\myexe.exe' then my psexec command would look like [psexec c:\myexe.exe]

http://technet.microsoft.com/en-us/sysinternals/bb897553.aspx
0
 
LVL 78

Expert Comment

by:arnold
ID: 34170694
Why not execute the file d:\t.cmd?
I think the example above might have to reference d as an administrative share
\\DBMS-PHK1\d$\t.cmd  The issue could be that the t.cmd file is trying to executes something else that is not found based on the settings available in psexec.
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:Itai_Argoetti
ID: 34170700
Some remarks:
1. This command run already for several months with no problem. Few days ago it stopped working.
2. I tried to resetart the server. Didn't help
0
 
LVL 78

Expert Comment

by:arnold
ID: 34170736
Check the DEP settings on the system, it appears that one of the MS updates changes it from Turn on DEP for essential windows programs and services only. to Turn on DEP  for all programs and services except those I select.
properties of my computer\advanced\performance settings\Data Execution Prevention


The question remains why not simply execute the d:\t.cmd.
use schtasks to schedule the running of this command if needed c:\windows\tasks.
0
 
LVL 2

Expert Comment

by:SacTechGroup
ID: 34170787
In the description it statest the the file is in c:\ and that execution is taking place on the local machine.  Based on the example it seems there is a path issue.. Is it in c:\ or D:\  if it cant find it it wont run.

Ok it has been running?  by whom?  Looking at the dir output I see that t.cmd is 6 bytes.  What could possibly be in there that is only 6 bytes??  Can you edit the command and copy/paste its contents to this thread?  I have a feeling your command was corrupted.
0
 

Author Comment

by:Itai_Argoetti
ID: 34171010
Arnold, I don't have this DEP option in my server. It's a W2000 server.
0
 

Author Comment

by:Itai_Argoetti
ID: 34171019
In the description, by mistake I wrote that I'm placing the file on C:\ drive, but, as you can see in the rest of the description that it's on D:\...
0
 
LVL 78

Expert Comment

by:arnold
ID: 34175797
What about SacTechGroup's comment dealing with the contents of the t.cmd file being corrupted?
0
 

Author Comment

by:Itai_Argoetti
ID: 34178570
Arnold, the "t.cmd" is a test file demonstrate the problem. I have the problem with any other files.
0
 
LVL 78

Expert Comment

by:arnold
ID: 34191913
What a are the commands that you are trying to execute?  YOu have to make sure that these commands are preceeded with the full path and can not assume that because you can run the command locally as written in t.cmd, that the command will be found when executed through psexec.
This deals with the %PATH% variable.
set the t.cmd with the following command:

echo "IT works"

and see if you have a different response.
0
 
LVL 7

Expert Comment

by:YarnoSG
ID: 34208187
if you use the -c switch on psexec, it will copy the script to the target before trying to execute it.



Using the "D:\" in your command line is risky - the remote client might not have a D: drive.

try this:
psexec.exe  \\targetcomputer -c t.cmd
(from your d: drive) - it will copy your "t.cmd" script and then execute it.

0
 

Author Closing Comment

by:Itai_Argoetti
ID: 34731866
a
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
windows 7 system recovery 5 70
Restricting Domain Admin Accounts 4 59
Installing OS on Poweredge 2800 Raid 1 97 69
How to creare arabic email address and mx record 4 61
The way I use Experts Exchange to assist me in analyzing and diagnosing a problem is I first enter a Verbose Question at Experts Exchange like: Office 2007 will hang when opening and saving files I then launch WordPad (any text editor will do) an…
The password reset disk is often mentioned as the best solution to deal with the lost Windows password problem. In Windows 2008, 7, Vista and XP, a password reset disk can be easily created. But besides Windows 7/Vista/XP, Windows Server 2008 and ot…
This video Micro Tutorial explains how to clone a hard drive using a commercial software product for Windows systems called Casper from Future Systems Solutions (FSS). Cloning makes an exact, complete copy of one hard disk drive (HDD) onto another d…
Windows 8 came with a dramatically different user interface known as Metro. Notably missing from that interface was a Start button and Start Menu. Microsoft responded to negative user feedback of the Metro interface, bringing back the Start button a…

740 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question