Comments (4)
original python psutil returns cpu-total-sum if percpu is false. And gopsutil also returns cpu-total-sum if percpu is false. if you find a bug, please let me know with what architecture you use.
Thank you.
from gopsutil.
@shirou Thank you for your reply i use it in ubuntu14.4 with golang
Through your code I understand it is that you get the first piece of CPU state when the parameter is the value false instead of all or a combination of all of the CPU and CPU state I'm not sure whether you do it for all the CPU state reaction
from gopsutil.
/proc/stat
on Linux is like this.
cpu 8396257 168024 2066813 4683926935 373796 2084 106614 182508 0 0
cpu0 2093478 128915 943679 2343735446 323843 545 8658 97828 0 0
cpu1 6302778 39108 1123134 2340191488 49953 1539 97956 84679 0 0
The first line is a total of all cpu times. So, if percpu
is False, we need only first line, I think.
from gopsutil.
@shirou I get it . I was wrong to thank you very much
from gopsutil.
Related Issues (20)
- When I call process.Percent,memory increase slowly
- proc.openfiles() crash HOT 1
- Monitor specific ports for network HOT 1
- v4 release plan HOT 1
- Is it possible to obtain the power of the whole machine? HOT 2
- Standart interfaces for services HOT 1
- Using host.HostID() on the Windows platform The uuid obtained is different from the cmd `wmic csproduct get uuid` HOT 2
- can't use the "disk" package
- cpu.parseStatLine bug HOT 5
- Process createTime calculation for linux lxc guest is incorrect HOT 4
- Non-root user can't get process information HOT 1
- Report a bare-meteral machine as KVM at host.Info HOT 1
- The host.Info() function is unable to correctly identify CentOS Stream 8. HOT 1
- Missing FQDN/hostname option for windows HOT 2
- stat.Rdev (variable of type uint32) as uint64 HOT 4
- Adopt a hierarchy for getting distro name/version on Linux
- Mac OS Apple M1 get cpu info failed "no such file or directory" HOT 3
- Using the gopsutil package causes the goland debugger to not work properly (random jumps)
- ProcTotal Inaccurate in `MiscStats` HOT 4
- : Optimization Request: Reducing the Number of windows.OpenProcess Calls When Gathering Name, CreateTime, and PPID HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gopsutil.