What You'll Learn

In this codelab you will learn

What You'll need

Guest operation system (Guest OS)

This is the OS of the virtual machine. This will be Microsoft Windows.

Administators privileges

By default, administrator privileges are required on the Host OS to install additional software. Make sure that you have the required permissions.

For the Guest OS, you will create and manage your own users. These users will therefore be different from the Host's user administration.

What You will learn:

You can use one of the following commands to find some information about the physical CPUs (pCPU) including all cores on Windows:

Description

The tool msinfo32 is a built-in system profiler for Microsoft Windows which collects and displays system information about the the Operating systems, hard- and software.

Sample code

To launch msinfo32, simple press the Win+R keys, type msinfo32 and click the OK-button.

Windows Registry

Details about the CPU can be found in the System Summary section at the Processor value in the right pane.

Description

The command-line tools systeminfo displays detailed configuration information about a computer and its operating system, including system configuration, security information, product details, and hardware properties.

Sample code

systeminfo
--More--
Processor(s):              1 Processor(s) Installed.
                           [01]: Intel64 Family 6 Model 60 Stepping 3 GenuineIntel ~3093 Mhz
--More--

Description

WMI (Windows Management Instrumentation) is a programming interface that can be used to capture many aspects of Windows operating systems. This ranges from hardware, operating system settings, performance data to installed applications. WMI allows to read and changed values. It also allows the execution of methods and functions.

WMIC stands for WMI Command.

Sample code

wmic cpu get caption,deviceid,name,numberofcores,maxclockspeed,status

### Sample output

Caption                               DeviceID  MaxClockSpeed  Name                                      NumberOfCores  Status
Intel64 Family 6 Model 60 Stepping 3  CPU0      3093           Intel(R) Core(TM) i3-4160T CPU @ 3.10GHz  2              OK

Description

The Windows Registry is a database of information, settings, options and other values for software and hardware. The registry is installed on all versions of Microsoft Windows operating systems. The Windows Registry helps the operating system to manage the computer, it helps programs to use the resources, and it provides a location for keeping custom settings you make in both Windows and your programs.

Sample code

What You will learn:

You can use one of the following application to monitor the CPU on your Windows Host.

Description

The Windows Task Manager (Taskmon) is a system tool found in all versions of Microsoft Windows platform's. It provides information about running applications, processes, and services, as well as computer performance, network activity, and memory information. There are two views for the Task Manager: Simplified and Advanced.

Sample code

To use Taskmon, open "Start", do a search for taskman, and confirm the result. Or do a right-click on the Windows Taskbar and select Task Manager from the menu.

Windows Task Manager (advanced view)

Microsoft improves the Task Manager between each version of Windows. Currently, Taskmon under Windows 11 has a redesigned look and some new features.Here is a list of running processes. Windows Task Manager (advanced view)

And here is a smart overview of the current performance. Windows Task Manager (advanced view)

Learn more about the Task Manager from Microsoft Learn or from LifeWire.

Description

The Windows Resource Monitor (Resmon) is a system application included in Windows Vista and later versions of Windows that allows users to look at the presence and allocation of resources on a computer.

The Windows Task Manager can best be described as a tool that runs on the surface. It lists processes and services, and general resource usage. In contrast, the Resource Monitor gives you the option to look under the surface to get more information that the Task Manager does not provide.

The Windows Resource Monitor can be used to determine extensive and detailed information about the current performance and resource consumption in real time. The program is therefore also suitable for error analysis. The view is divided into the following sections:

Sample code

To use Resmon, open Start, do a search for resmon, and confirm the result.

htop

Description

On Microsoft Windows, IT Administrators can use Windows Performance Monitor to analyze data, such as processor, hard drive, memory, and network usage.

Sample code

To use Perfmon, open Start, do a search for perfmon, and confirm the result.

Windows Performance Monitor

When you open the tool, the main page will show up with a brief overview, a system summary with real-time data about Memory, Network Interface, Physical Disk, and Processor Information. On the keft side, you will find the navigation pane with access to Monitoring Tools, Data Collector Sets, and Reports.

When you switch to the Performance Monitor, you will see a screen with a single counter. This is typically the Processor Time counter, which displays the processor load.

Windows Performance Monitor

However, you can add a lot of other counters to monitor virtually anything on your computer. To add new counters to monitor applications and hardware performance on your computer, do the following steps:

What you will learn:

In this codelab, you will learn

What you will need:

In this codelab, you will need the following tools:

Scenario

In this codelab, the target is a virtual Machine with 2 CPU Cores and 8 GB RAM. The operating system is based on Windows 10 Educatuinm Version 10,0,19042 Build 19042. The VM is installed and running on the Linux-based Hypervisor VirtualBox, Version 6,1.16 r140961 (QT 5.11.3). THe HostOS is based on Debian with Linux Kernel version 4.19.0-17-amd64. The Host hardware is HP Prodesk 400 G1 DN with a Intel Core i3-4160T CPU@3.10GHz, 16GB RAM, and an Intenso SATA III Top 512GB.

Test Run

To add Perfmon counters to monitor CPU Utilization please execute the following steps.

The data set (i.e. Task Set) should now appear in the right hand pane.

Next, you will see something like the following in the Added counters window: Windows Performance Monitor

Congrats, you have created the basic dataset. But we're not done yet.

The next steps are:

Clean Up

This is the end of the hands-on.