Python psutil memory does not match linux command -


i want know why psutil's virtual memory used or active not match value linux command 'free -m' want know physical system memory used.

virtual_memory().total / 1024 / 1024 = 29741 virtual_memory().used / 1024 / 1024 = 7967 virtual_memory().active / 1024 / 1024 = 2259                total        used        free      shared  buff/cache   available mem:          29741        1148       21773          16        6819       28322 swap:             0           0           0 

i'm guessing virtual_memory().used returns physical mem + shared mem + cached mem still, active memory should match 1148.


Comments

Popular posts from this blog

Java 3D LWJGL collision -

spring - SubProtocolWebSocketHandler - No handlers -

methods - python can't use function in submodule -