Closed theldoria closed 9 years ago
please confirm that command wmic
is available in your Command Prompt.
(symon internally uses wmic path Win32_PageFileUsage get CurrentUsage
to fetch page file informations)
I've just tried running symon with emacs 24.4 on windows 8.1. I get a cpu trace, but MEM & BAT say N/A, and in between updates I get:
Error running timer 'symon--update': (void-function w32-memory-info)
wmic is available and "wmic path Win32_PageFileUsage get CurrentUsage" gives: CurrentUsage 871
thanks. I didn't know w32-memory-info
is not provided on some builds.
I just made a quick fix for the problem to avoid errors, but memory/battery statuses are still N/A.
Maybe these statuses can be fetched with wmic
or typeperf
, so I'll implement later.
looks like these would do: wmic os get freephysicalmemory wmic path Win32_Battery Get EstimatedChargeRemaining
also wmic ComputerSystem get TotalPhysicalMemory to get the %
Thanks...saw the fix in my twitter feed from melpa :-)
implemented. the latest version works fine ?
Almost. No error, but MEM:N/A (2158MB Swapped)
The individual parts to wmic look like they work: C:\Users\andre_000>wmic path Win32_ComputerSystem get TotalPhysicalMemory TotalPhysicalMemory 2023440384
C:\Users\andre_000>wmic path Win32_OperatingSystem get FreePhysicalMemory FreePhysicalMemory 181924
C:\Users\andre_000>wmic path Win32_Battery get EstimatedChargeRemaining EstimatedChargeRemaining 46
C:\Users\andre_000>wmic path Win32_PageFileUsage get CurrentUsage CurrentUsage 2247
Using git head (261546), I get: MEM:-100860% (40384 Swapped) Cpu: 91% BAT:40384%
I'll try and see what's happening. I'm an elisp beginner though...
hmm... can you try this one (paste somewhere and evaluate with C-x C-e
) ?
(print (shell-command-to-string
(concat "(echo path Win32_ComputerSystem get TotalPhysicalMemory"
" && echo path Win32_OperatingSystem get FreePhysicalMemory"
" && echo path Win32_Battery get EstimatedChargeRemaining"
" && echo path Win32_PageFileUsage get CurrentUsage"
" && echo exit) | wmic")))
calling wmic
four times every 5 seconds seems too inefficient so I want to collect four values at once.
Output was (with ^M at the end of each line):
"wmic:root\cli>TotalPhysicalMemory
2023440384
wmic:root\cli>FreePhysicalMemory
273832
wmic:root\cli>EstimatedChargeRemaining
25
wmic:root\cli>CurrentUsage
2140
wmic:root\cli>"
thanks, i got it.
output format of wmic
is different from my computer.
Perfect. Thanks. For reference this was a Windows 8.1 machine.
I'm using Windows 7 and got
"wmic:root\\cli>path Win32_ComputerSystem get TotalPhysicalMemory
TotalPhysicalMemory
4193701888
wmic:root\\cli>
ヘルプを表示するには \"/?\"、終了するには QUIT と入力してください。
wmic:root\\cli>path Win32_OperatingSystem get FreePhysicalMemory
FreePhysicalMemory
1617520
wmic:root\\cli>
ヘルプを表示するには \"/?\"、終了するには QUIT と入力してください。
wmic:root\\cli>path Win32_Battery get EstimatedChargeRemaining
EstimatedChargeRemaining
100
wmic:root\\cli>
ヘルプを表示するには \"/?\"、終了するには QUIT と入力してください。
wmic:root\\cli>path Win32_PageFileUsage get CurrentUsage
CurrentUsage
1378
wmic:root\\cli>
ヘルプを表示するには \"/?\"、終了するには QUIT と入力してください。
wmic:root\\cli>exit
"
regexps i first used were for this output format.
I followed the readme and got onlythe following output: MEM:N/A% (N/AMB Swapped) CPU:N/A% BAT:N/A%
So, there is something missing in the readme: system requirements, dependecies and installation instructions.