LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Determine Memory Usage

Solved!
Go to solution

Does LabVIEW have the tools available to write a small little script to just run in the background and watch a few applications and processes and report on their memory usage over time?

0 Kudos
Message 1 of 8
(3,128 Views)

Here is an example that shows how to get the total processor use.

You can change the InstanceName input to match the application you want to monitor.

 

Edit: I found this other example that actually gives you an interface to plot multiple instances. Though, the instances load as "1", "2", "3", etc. I'm not sure if this is the only way to refer to the instances, maybe someone else on here can give more insight in to this behavior.

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


Message 2 of 8
(3,110 Views)

Inital trials are producing errors and I'm guessing because my initialization is incorrect in more than one way.  These descriptors (CategoryName, CounterName, InstanceName) aren't exaclty telling... at least to someone who's not a .net guy or even a true programmer at that.

 

Capture.JPG

0 Kudos
Message 3 of 8
(3,080 Views)

I edited my response earlier. See the second link I put in there. Try using "1", "2", etc as the Instance names, though I'm not sure how to link those to specific applications.

See below.

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


0 Kudos
Message 4 of 8
(3,076 Views)
Solution
Accepted by topic author DailyDose

Got it! Use "Process" instead of "Processor", "% Processor Time", and "chrome". Should work fine.

 

The first example I linked to is utilizing the Processor category, which just shows CPU usage by the processor cores. The second example I linked to is great because it shows all of the different categories/counters/instances in an easy user interface. Tinker with that to get the exact instance names you want, etc.

 

For you, and those who find this thread in the future, here is all of the information in one post.

Monitor total CPU Usage or cores.

UI to browse for all Categories, Counters, and Instances.

Chrome CPU Usage snippet:

CPU Usage LV821_BD.png

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


Message 5 of 8
(3,064 Views)

Appreicate the help.  It looks like there may be a couple bugs in the Performance Monitor.vi  It's possible it's a version bug, not sure yet.  But I get the idea.  Anyways, this should be plenty to kick off with.  Thanks!

0 Kudos
Message 6 of 8
(3,020 Views)

Curious, though.  What about on a Linux system?

0 Kudos
Message 7 of 8
(2,999 Views)

That, I do not know. 

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


0 Kudos
Message 8 of 8
(2,978 Views)