+1, this makes landscape-sysinfo report more accurate memory usage.
Without the change:
jseutter@perth:~/src/landscape-client/trunk$ ./scripts/landscape-sysinfo
System load: 0.82 Users logged in: 1
Usage of /: 58.1% of 228.21GB IP address for eth0: 192.168.2.138
Memory usage: 42% IP address for lxcbr0: 10.0.3.1
Swap usage: 0% IP address for wlan0: 192.168.2.100
Processes: 238
With the change:
jseutter@perth:~/src/landscape-client/correct-free-mem$ ./scripts/landscape-sysinfo
System load: 0.92 Users logged in: 1
Usage of /: 58.1% of 228.21GB IP address for eth0: 192.168.2.138
Memory usage: 22% IP address for lxcbr0: 10.0.3.1
Swap usage: 0% IP address for wlan0: 192.168.2.100
Processes: 238
This matches the output of top, free and The Internet. It differs from the free command by 1%, but I assume this is because we truncate the value somewhere.
I'm getting two PEP8 warnings, can you clean these up?
=== pep8 ===
landscape/lib/sysstats.py:16:80: E501 line too long (96 characters)
landscape/lib/sysstats.py:20:80: E501 line too long (87 characters)
+1, this makes landscape-sysinfo report more accurate memory usage.
Without the change: perth:~ /src/landscape- client/ trunk$ ./scripts/ landscape- sysinfo
jseutter@
System load: 0.82 Users logged in: 1
Usage of /: 58.1% of 228.21GB IP address for eth0: 192.168.2.138
Memory usage: 42% IP address for lxcbr0: 10.0.3.1
Swap usage: 0% IP address for wlan0: 192.168.2.100
Processes: 238
With the change: perth:~ /src/landscape- client/ correct- free-mem$ ./scripts/ landscape- sysinfo
jseutter@
System load: 0.92 Users logged in: 1
Usage of /: 58.1% of 228.21GB IP address for eth0: 192.168.2.138
Memory usage: 22% IP address for lxcbr0: 10.0.3.1
Swap usage: 0% IP address for wlan0: 192.168.2.100
Processes: 238
This matches the output of top, free and The Internet. It differs from the free command by 1%, but I assume this is because we truncate the value somewhere.
I'm getting two PEP8 warnings, can you clean these up?
=== pep8 ===
landscape/ lib/sysstats. py:16:80: E501 line too long (96 characters) lib/sysstats. py:20:80: E501 line too long (87 characters)
landscape/