LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-06-2006, 02:46 AM   #1
3saul
Member
 
Registered: Aug 2004
Location: Brisbane, Australia
Distribution: Ubuntu/Fedora
Posts: 86

Rep: Reputation: 15
Adding values on command line..


I have the following command

ps -e -o pcpu | sed '/0.0/d' | grep -v CPU

this outputs the cpu usage of all processes that are using the cpu - how can I add these all together? Alternatively - how can I get the current CPU usage from the command-line? All of the commands I've seen so far provide it for the last 5 mins etc but not for the present time.
 
Old 03-06-2006, 03:01 AM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
cat /proc/loadavg
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
adding files through command line browser Linux - General 6 05-21-2005 06:53 PM
Adding users via command Line AmdMhz Linux - Software 4 10-31-2004 01:29 PM
Streaming in values without defined command line arguments liguorir Linux - Software 1 05-07-2004 02:40 AM
adding a user in the command line Daredevil Linux - Newbie 5 02-27-2004 12:56 PM
adding command line to starting coltranefawz Linux - Software 1 07-02-2003 11:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:35 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration