Description of problem:
When a profile's script.sh fails, all tuned will do is print an error message in tuned.log, for example:
2017-10-06 16:32:06,798 ERROR tuned.plugins.plugin_script: script '/usr/lib/tuned/realtime-virtual-host/script.sh' error: 1, ''
However, everything else will indicate that the profile has been successfuly applied. For example, "systemctl status tuned" will say tuned is running fine and "tuned-adm active" will show the profile is applied.
While the error message in tuned.log is necessary, we need a stronger indication that the profile is not applied. This could be systemctl status saying tuned was not loaded or tuned-adm active indicating an error.
Also, note that tuned.log may have unharmful error messages, such as:
2017-10-10 15:05:21,233 ERROR tuned.utils.commands: Executing sysctl error: sysctl: cannot stat /proc/sys/kernel/numa_balancing: No such file or directory
Which is fine and expected in the RT kernel since numa balancing is disabled, but makes it very hard to distinguish between harmful and unharmful messages.
Version-Release number of selected component (if applicable): tuned-2.8.0-5.el7.noarch
Steps to Reproduce:
1. Edit a profile's script.sh file and add a "return 1" from the start() function
2. Apply the profile
3. Check, systemctl status tuned, tuned-adm active. All will indicate the profile was successfuly applied
While reviewing profile BZs I found we already have an older BZ open for this issue.
*** This bug has been marked as a duplicate of bug 1385838 ***