Solved

PsExec usage

Posted on 2013-06-23
4
1,039 Views
Last Modified: 2013-06-25
Hi All,

I want to use PsExec to remotely manage services. But while doing so, I found this issue: PsExec failing
How do I pass on yes/no etc through this?
0
Comment
Question by:bubaibhatta
[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
4 Comments
 
LVL 6

Assisted Solution

by:Vijay Pratap Singh
Vijay Pratap Singh earned 0 total points
ID: 39270393
The following is from http://blogs.technet.com/b/systemcenteressentials/archive/2009/09/01/using-psexec-to-open-a-remote-command-window.aspx

With psExec installed you can open a remote command prompt by calling it as follows:

psExec \\computer cmd

If you have psExec installed on your computer with the Essentials console you can create a task in Essentials to open a remote command window from within Essentials.

To create this task:

    Go to the Authoring workspace
    In the navigation pane on the left hand side, expand Management Pack Objects and select Tasks
    From the Tasks pane, select Create a New Task
    Select Command Line from the Console Tasks folder and click Next
    In the Task Name field, type "Remote Command Window"
    In the Description type "Use the SysInternals PsExec tool to open a remote command window for the selected computer. PsExec must be installed on the computer with the Essentials console."
    In the Task Target, click Select and then choose Windows Computer and click OK
    Click Next
    In the Application field, type the full path the psexec.exe on the Essentials console (e.g. C:\pstools\psexec.exe). If you have the console on multiple computers you will need psExec installed in the same location on each of them.
    Enter \\ then Click the arrow at the end of the Parameters field and select Net BIOS Computer Name, then add a space and enter cmd
    Uncheck the Display output when this task is run box
    Click Create
(Edit - Attribution added - Modulus_Twelve)
0
 
LVL 85

Accepted Solution

by:
oBdA earned 350 total points
ID: 39270409
You can either add "/y" to your command line, which will stop all dependent services without confirmation:
net stop IMAService /y

Open in new window

or stop the dependent services before you stop the IMA service
net stop "Citrix WMI Service"
net stop "Citrix SMA Service"
net stop "IMAService"

Open in new window

The latter is the better solution if you want to retain control over the order in which the services are stopped (which, in this case, doesn't really matter).
0
 

Author Comment

by:bubaibhatta
ID: 39270524
Thanks for the quick reply. It solved my problem..
0

Featured Post

Get 15 Days FREE Full-Featured Trial

Benefit from a mission critical IT monitoring with Monitis Premium or get it FREE for your entry level monitoring needs.
-Over 200,000 users
-More than 300,000 websites monitored
-Used in 197 countries
-Recommended by 98% of users

Question has a verified solution.

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

This article is a collection of issues that people face from time to time and possible solutions to those issues. I hope you enjoy reading it.
This article provides a convenient collection of links to Microsoft provided Security Patches for operating systems that have reached their End of Life support cycle. Included operating systems covered by this article are Windows XP,  Windows Server…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…

617 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