Skip to main content

Command to obtain complete details of a process running in windows

Just wanted to share a command in Windows, to obtain complete details of the processes running in windows.

In Unix/Linux we use the below command to obtain all the java processes running on particular server:
ps -ef|grep java

which shows the PID, command line and other details.

The same can be obtained in windows OS.

Using Task Manager to show the command line option, the display value is so long that the CLASSPATH setting gets cut off and complete details are not obtained.

To show the entire command line including switches/options is to use the WMIC command:
C:\> WMIC process where caption="java.exe"

Open an windows CMD prompt, execute the following "Windows Management Instrumentation Command-line" (WMIC):
To obtain processid and commandline provide the arguments as get

C:\> WMIC process where caption="java.exe" get processid,commandline

Note: You can pipe the result out to a file like below: (Open cmd prompt as Run as Administrator)
C:\> WMIC process where caption="java.exe" get processid,commandline > C:\TEMP\OUTPUT.TXT                                  
There are different other fields like :

PageFaults, PageFileUsage, ParentProcessId, PeakPageFileUsage, PeakVirtualSize, PeakWorkingSetSize, Priority, PrivatePageCount, ProcessId, QuotaNonPagedPoolUsage, QuotaPagedPoolUsage, QuotaPeakNonPagedPoolUsage, QuotaPeakPagedPoolUsage, ReadOperationCount, ReadTransferCount, SessionId, Status, TerminationDate, ThreadCount, UserModeTime, VirtualSize, WindowsVersion, WorkingSetSize, WriteOperationCount, WriteTransferCount


Popular posts from this blog

Steps to Analyze AWR Report in Oracle

Steps to Analyze AWR Report in Oracle
AWR -Automaticworkload repository is a collection of persistentsystem performancestatisticsowned by SYS. It resides in SYSAUXtablespace. Bydefault snapshot are generated once every 60 min and maintained for 7 days. Each snapshot has a unique ID know as "snap_id". Snapshot detail can be found in "dba_hist_snapshot" view.
If we have Database performance issue and not the Database machine, then AWR Report is the place to look at. AWR is not used for real-time performance monitoring like the v$ tables. It is used for historical analysis of performance. AWR complements, but doesnot replace real-time monitoring.
Once AWR Report is generated in Oracle, the next task is to analyze it. By going through the AWR Report we can easily solve issues like slow database, high wait events, slow query and many more issues. Even though the report is lengthy, Analyzing or Reading relevant part of AWR Report can help to troubleshoot issues in easy and …

Using SQL Developer to create and view Tablespaces

Below are the steps Create and View Table Spaces settings using SQL Developer.
Required SQL developer version is version 3.0
To Create TableSpace :
Click on Menu View/DBA - DBA navigator window will appear.
In the DBA window add a new connection to the DB, and click connect. Then under storage option right click on Tablespaces and choose New Tablespace to create new one. Fill the Details as shown below:

To View the created table spaces: Under Storage, Select Data Files:
It will display the below: