You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There is an inconsistency in when the static tuning of an instance is applied:
Static tuning is only executed at startup (via instance_apply_tuning)
If at that time, the instance is not active (has no devices attached), static tuning is skipped
If devices are assigned to the instance later, it becomes active, but static tuning is not triggered
If the instance shuts down, it's now active, and static tuning will be unapplied
Same situation can happen in "reverse": If an instance starts out with devices, its static tuning will be applied. If then the devices are detached, it becomes inactive, and on shutdown its static tuning will never be unapplied.
Always (un)apply the static instance tuning, even if the instance is inactive. This would be easy to implement, but sounds wrong.
Track when an instance becomes active (first device is attached) or inactive (last device is detached) and then apply or unapply the static tuning. Since I believe adding/removing devices can be triggered by multiple threads, we'd probably need to add a lock here... so possible not so easy, but sounds a but more right than (1).
The text was updated successfully, but these errors were encountered:
Calls to our _instance_[un]apply_static() are unreliable [1], so we
can't use them to keep track of the active-instance count, to
start/stop the perf monitor thread on demand. Instead, this keeps
the thread running continuously.
[1] redhat-performance#662
Signed-off-by: Adriaan Schmidt <[email protected]>
Calls to our _instance_[un]apply_static() are unreliable [1], so we
can't use them to keep track of the active-instance count, to
start/stop the perf monitor thread on demand. Instead, this keeps
the thread running continuously.
[1] redhat-performance#662
Signed-off-by: Adriaan Schmidt <[email protected]>
Follow-up to #596 (comment)
There is an inconsistency in when the static tuning of an instance is applied:
instance_apply_tuning
)active
(has no devices attached), static tuning is skippedI don't think any of the current plugins has a problem with this, but it's an issue for my PR #628, where I'm trying to use
_instance_[un]apply_static
to determine the number of active instances (https://github.com/adriaan42/tuned/blob/adriaan/kthreads/tuned/plugins/plugin_kthread.py#L272).I see two possible solutions (there may be more):
The text was updated successfully, but these errors were encountered: