Title
#linux
Hugh (Zercurity)

Hugh (Zercurity)

07/10/2020, 11:11 AM
of the users mouse activity? applications? or just general system CPU usage?
b

binu

07/10/2020, 6:44 PM
For users mouse activity ,and application
Hugh (Zercurity)

Hugh (Zercurity)

07/10/2020, 6:49 PM
sorry, couldn't help you with that use case.
b

binu

07/12/2020, 9:22 AM
Ok thanks
4:14 PM
Machine active/inactive(idle) times query available in osquery ?
Hugh (Zercurity)

Hugh (Zercurity)

07/15/2020, 4:15 PM
SELECT (SUM(user) + SUM(nice) + SUM(system) + SUM(idle) * 1.0) AS tsb, SUM(COALESCE(idle, 0)) + SUM(COALESCE(iowait, 0)) AS itsb FROM cpu_time;
4:16 PM
full example in the link to medium I posted
4:17 PM
though you will have to run this query periodically to check the difference in times. In order to correctly calculate usage.
b

binu

07/15/2020, 4:36 PM
Ok thanks for your help