Linux Format

MAKING USE OF THRESHOLD SCRIPTS

-

In addition to the s-tui.conf file, the ~/.config/s-tui directory also contain a directory called hooks-d. You can place custom scripts you wish to execute when a certain threshold, such as CPU temperatur­e or frequency is exceeded, within this directory. The name of the script must be source.sh, where is the name of the supported source. While you can use S-TUI to track various sources, for now it only supports running scripts based on CPU temperatur­e threshold setting.

The default threshold value for the CPU temperatur­e is 80. To change this value, you must invoke S-TUI with the s-tui --t_thresh command. You can then save the new threshold value into the ~/.config/s-tui/s-tui.conf

file by saving the settings from within S-TUI itself.

If you make any changes to the settings from within the S-TUI interface, and wish to save them for future use, you’ll need to navigate to the Save Settings option on the sidebar and then press Enter. Depending on how you installed S-TUI, you may have to amend the file permission­s on the s-tui.conf

file for it to be writeable, otherwise the tool will exit with a curt ‘Permission Denied’ error.

When you now open the s-tui.conf file in a text editor, you’ll find a new entry showing the newly defined temperatur­e threshold value:

[GraphContr­oll] refresh = 2.0 utf8 = True tthresh = 70

While the stress testing feature is of little use to home Linux users, there’s no denying the benefit of graphical representa­tion of the collected data for administra­tors and programmer­s.

Newspapers in English

Newspapers from Australia