Home > Tips, tools > How to get the CPU utilization of remote machine from command prompt

How to get the CPU utilization of remote machine from command prompt

Use below command if you want to get the CPU utilization of remote machine from command prompt. It’s very useful if you don’t want to spend time in logging on to the server to verify the stats. Needless to say, replace RemoteMachine with your remote machine name in below command.

typeperf “\RemoteMachineprocessor(_Total)% Processor Time”

Refer to my old article to know more about typeperf

Happy Learning…,
Sitaram Pamarthi

No related content found.

Categories: Tips, tools
  1. iresha
    September 30, 2009 at 3:53 pm | #1

    You can also very easily build your own performance monitor in C++

    Windows C++ Get CPU and Memory Utilisation With Performance Counters

  2. Ramesh Kumar
    November 16, 2009 at 12:30 pm | #2

    Hi,
    Using the command provided, it is possible to get data from Local machine only.

    But when tried with remote machine, it returns following error:
    Error: No valid counters.

    Command used:
    typeperf “\Process(*)% Processor Time” -sc 1

    Please help me out in this issue.

    • admin
      November 21, 2009 at 10:52 pm | #3

      Hey Ramesh,

      Let’s isolate the problem this way. Execute this command on the remote machine locally and see if it returns any thing. If the comman works fine locally, then we have some thing to troubleshoot with remote connection.

      Make you sure that you are having admin rights on remote machine while running this command. A domain admin is preferred for ideal results.

  3. June 20, 2010 at 2:33 pm | #4

    Seems like that you’ve put lots of hard work into your article and I require much more of these on the net these days. I sincerely got a kick from your post. I don’t really have significantly to express in response, I only wanted to comment to reply amazing work.

  4. Mark
    September 14, 2011 at 7:38 pm | #5

    Is there a way to run these queries using SQL XP command shell to remotley collect data within SQL server Queries? And is there an easy way to pass alternative credentials to be used?

    • Sitaram Pamarthi
      September 16, 2011 at 1:09 pm | #6

      Mark, If you are running SQL 2008, then you can use a powershell script instead of XP Command shell. I guess whatever the logging you are using through XP shell can be converted into powershell code. Alternative is, to write a VB script that can query remote WMI to get current CPU utilization.

      I recently wrote a PowerShell script that queries CPU utilization using WMI (http://techibee.com/powershell/get-cpu-utilization-of-a-computer-using-powershell/996). You can convert into VBScript.

      Let me know if you need any help here.

  1. No trackbacks yet.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>