Registered 2016-06-11 by DanglingPointer

This program will keep your system ON based on certain parameters; namely cpu load, user activity, and network traffic (boolean OR for all three). It will also log its interval analysis to a managed log file.

TO INSTALL: Ubuntu 18.04 and above:
1) sudo apt install -y brz libxss-dev libx11-dev libffi-dev python3-pip python3-netifaces python3-psutil python3-distro xz-utils

2) cd /<your desired installation path>/

3) brz branch lp:keep.awake

Follow the steps above chronologically on Ubuntu's GNOME Terminal.

TO INSTALL: Ubuntu 16.04:
1) sudo apt install -y bzr libxss-dev libx11-dev libffi-dev python3-pip python3-netifaces python3-psutil xz-utils

2) sudo pip3 install distro

3) cd /<your desired installation path>/

4) bzr branch lp:keep.awake

Follow the steps above chronologically on Ubuntu's GNOME Terminal.

This program will keep your system ON based on certain parameters; namely cpu load, user activity and network traffic (boolean OR for all three). It will also log its interval analysis to a managed log file.

Keep Awake requires:
- python3.5+
- python3-netifaces
- python3-psutil
- python3-distro
- xz-utils

Keep Awake has a minimum linux distribution version of Ubuntu 16.04 LTS.
It has been extensively tested with Ubuntu 16.04 LTS and 18.04 LTS.
It works with Ubuntu 20.04 LTS.
It has NOT been tested with the non-LTS versions; however it should theoretically work.
Please report back in the Bugs or Answers section and I'll try and help.

It can run on other distributions as long as it has the requisite python3 packages, systemD, and the Gnome-Mutter desktop environment.
If you decide to try and use Keep.Awake with other distributions (not Ubuntu at least) please report back in the Bugs or Answers section and I'll try and help. It should work as long as you satisfy the dependencies mentioned above along with non-admin global user access to the "logrotate" command (comes with all distributions I've seen to date).

Keep.Awake was designed to run under a user. There is no need for sudo or root privileges.

Keep.Awake has pre-configured default values that will work for most desktops. To view the defaults, run the program interactively.

It works like a proper command. Type --help to see a full listing of what can be done.
$ ./keepawake.py --help

The examples underneath are only a few:

To run interactively:
$ ./keepawake.py

To get keepawake.py version:
$ ./keepawake.py -V

To run interactively with detailed output to screen and log-file:
$ ./keepawake.py -v Detail

To run interactively with verbose output to screen and log-file:
$ ./keepawake.py -v Verbose

To run interactively with detailed output to screen and log-file at custom path "/home/$USER/sleep/log/Keep.Awake/":
$ ./keepawake.py -l /home/$USER/sleep/log/Keep.Awake/ -v Detail

To run as a background service:
$ nohup ./keepawake.py -r > /dev/null 2>&1 &

To run as background service and set 15 min (900 sec) as the user activity idle time before it determines that the user is idle:
$ nohup ./keepawake.py -u 900 -r > /dev/null 2>&1 &

To run as background service and set minimum CPU load as 13%:
$ nohup ./keepawake.py -c 13 -r > /dev/null 2>&1 &

To run as background service and set minimum network traffic as 5KB (5120 bytes):
$ nohup ./keepawake.py -s 5120 -r > /dev/null 2>&1 &

To run as background service and set the schedule to sleep/suspend after 1 hour (this value is only set if user-activity, cpu, and network traffic are all determined to be idle) :
$ nohup ./keepawake.py -w 3600 -r > /dev/null 2>&1 &

To run all settings above (network, CPU, User idle, sleep schedule) in the one go and set the log-file path to "/home/$USER/sleep/log/Keep.Awake/" with detailed output:
$ nohup ./keepawake.py -s 5120 -c 13 -u 900 -w 3600 -l /home/$USER/sleep/log/Keep.Awake/ -v Detail -r > /dev/null 2>&1 &

Project information

Maintainer:
DanglingPointer
Driver:
DanglingPointer
Licence:
GNU GPL v3

RDF metadata

View full history Series and milestones

trunk series is the current focus of development.

All code Code

Version control system:
Bazaar
Programming languages:
python3

All questions Latest questions

All packages Packages in Distributions

All bugs Latest bugs reported

More contributors Top contributors

Downloads

Keep.Awake does not have any download files registered with Launchpad.

Announcements