computer.login_server module

class computer.login_server.LoginServer(utup, cpus, roots, credentials)[source]

Bases: computer.paramiko_server.ParamikoServer

connect()[source]
get_cpu_util()[source]

implement the idea of getting cpu_percents in psutil: 1. Get “cpu times” from /proc/stat once and wait a second before getting another reading of those. 2. Compare the two readings and define the utilization rate as:

(Non-idle and Non-iowait CPU time) / (total CPU time)

http://stackoverflow.com/questions/23367857/accurate-calculation-of-cpu-usage-given-in-percentage-in-linux