Release 1.1

This commit is contained in:
Clark Williams 2020-10-28 08:27:44 -05:00
parent 7dddf5053d
commit 0b46d1a305
4 changed files with 78 additions and 4 deletions

1
.gitignore vendored
View File

@ -1 +1,2 @@
/stalld-1.0.tar.xz /stalld-1.0.tar.xz
/stalld-1.1.tar.xz

View File

@ -1,3 +1,54 @@
# stalld # stalld
The stalld package - a daemon to detect (and possibly correct) stalled threads in a Linux system The stalld program (which stands for 'stall daemon') is a
mechanism to prevent the *starvation* of operating system threads in a
Linux system. The premise is to start up on a *housekeeping* cpu (one
that is not used for real-application purposes) and to periodically
monitor the state of each thread in the system, looking for a thread
that has been on a run queue (i.e. ready to run) for a specifed length
of time without being run. This condition is usually hit when the
thread is on the same cpu as a high-priority cpu-intensive task and
therefore is being given no opportunity to run.
When a thread is judged to be starving, stalld changes
that thread to use the SCHED_DEADLINE policy and gives the thread a
small slice of time for that cpu (specified on the command line). The
thread then runs and when that timeslice is used, the thread is then
returned to its original scheduling policy and stalld then
continues to monitor thread states.
There is now an experimental option to boost using SCHED_FIFO. This
logic is used if the running kernel does not support the
SCHED_DEADLINE policy and may be forced by using the -F/--force_fifo
option.
## Command Line Options
`Usage: stalld [-l] [-v] [-k] [-s] [-f] [-h] [-F]
[-c cpu-list]
[-p time in ns] [-r time in ns]
[-d time in seconds] [-t time in seconds]`
### Logging options
- -l/--log_only: only log information (do not boost) [false]
- -v/--verbose: print info to the std output [false]
- -k/--log_kmsg: print log to the kernel buffer [false]
- -s/--log_syslog: print log to syslog [true]
### Startup options
- -c/--cpu: list of cpus to monitor for stalled threads [all cpus]
- -f/--foreground: run in foreground [false but true when -v]
- -P/--pidfile: write daemon pid to specified file [no pidfile]
### Boosting options
- -p/--boost_period: SCHED_DEADLINE period [ns] that the starving task will receive [1000000000]
- -r/--boost_runtime: SCHED_DEADLINE runtime [ns] that the starving task will receive [20000]
- -d/--boost_duration: how long [s] the starving task will run with SCHED_DEADLINE [3]
- -F/--force_fifo: force using SCHED_FIFO for boosting
### Monitoring options
- -t/--starving_threshold: how long [s] the starving task will wait before being boosted [60]
- -A/--aggressive_mode: dispatch one thread per run queue, even when there is no starving
threads on all CPU (uses more CPU/power). [false]
### Miscellaneous
- -h/--help: print this menu

View File

@ -1 +1 @@
SHA512 (stalld-1.0.tar.xz) = 0a5571204a4d13054ad4a9ab3d3296511decf432fb85c640f785619d6369473353efee83dbb21b1d5136c42443d44f75d0a368cc8e2495766d705e5ef82bc6b4 SHA512 (stalld-1.1.tar.xz) = e53522cc9d820829e451c5edb74aaaf2715a4eed0b4cd37948239d3464a20161574a1788b21432fdd40f91e4d54422c1a2e9583a992383e81d68c1a8207b4570

View File

@ -1,6 +1,6 @@
Name: stalld Name: stalld
Version: 1.0 Version: 1.1
Release: 4%{?dist} Release: 1%{?dist}
Summary: Daemon that finds starving tasks and gives them a temporary boost Summary: Daemon that finds starving tasks and gives them a temporary boost
License: GPLv2 License: GPLv2
@ -50,6 +50,28 @@ allow 10 microseconds of runtime for 1 second of clock time.
%systemd_postun_with_restart %{name}.service %systemd_postun_with_restart %{name}.service
%changelog %changelog
* Tue Oct 27 2020 Clark Williams <williams@redhat.com> - 1.1-1
- Fix an option in README.md; consistency in user facing docs.
- Makefile: add 'static' target to link stalld statically
- gitignore: ignore object files and the stalld executable
- use FIFO for boosting (v3)
- stalld.c: fix sched_debug parsing and modify waiting task parsing
- redhat: update release for features and bugfix
- stalld: Do not die if sched_debug returns an invalid value
- src/stalld: Do not die if the comm is too large
- src/stalld: Do not die if cannot write a message to the log
- src/stalld: Do not die if the main runs while a thread is monitoring the CPU
- implement RT throttling management and refactor source files
- more refactoring
- src/stalld: Reuse already read nr_running nr_rt_running
- src/stalld: Gracefully handle CPUs not found on sched_debug
- src/stalld: Use dynamically allocated memory to read sched_debug
- src/utils: Die with a divizion by zero if verbose
- src/stalld: Add config_buffer_size variable
- src/stalld: Increase the sched_debug read buffer if it gets too small
- src/stalld: Fix an retval check while reading sched_debug
- src/throttling: Fix a compilation warning
* Sun Oct 4 2020 Clark Williams <williams@redhat.com> - 1.0-4 * Sun Oct 4 2020 Clark Williams <williams@redhat.com> - 1.0-4
- Fix an option in README.md; consistency in user facing docs. - Fix an option in README.md; consistency in user facing docs.
- gitignore: ignore object files and the stalld executable - gitignore: ignore object files and the stalld executable