Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

On OpenWRT, initscript's reload is called too frequently/when not necessary #171

Open
brianjmurrell opened this issue Apr 19, 2024 · 5 comments

Comments

@brianjmurrell
Copy link

Hi. There's a ticket open in OpenWRT about an observation that sqm-scripts reloads frequently and when it's unnecessary.

I think I've debugged this issue here to the point of understanding that it's happening when my IPv6 WAN connection (which is not even the interface I have SQM configured for!) triggers an ifupdate event. I believe that when this happens

service_triggers()
{
procd_add_reload_trigger "sqm"
}
causes procd to issue a /etc/init.d/sqm reload.

But clearly this is happening on far too many unrelated events.

Is there any way to do some more checking in /etc/init.d/sqm to limit the reload to only happen when necessary?

@tohojo
Copy link
Owner

tohojo commented Apr 20, 2024

Well, AFAICT from the documentation, that procd_add_reload_trigger thing should only cause a reload if /etc/config/sqm is changed. There's a separate set of commands to add monitoring of interfaces through procd, but we're not using those (we have the hotplug script instead). So I'm not really sure how sqm ends up being reloaded, actually...

@moeller0
Copy link
Collaborator

moeller0 commented Apr 20, 2024 via email

@tohojo
Copy link
Owner

tohojo commented Apr 20, 2024 via email

@brianjmurrell
Copy link
Author

Well, AFAICT from the documentation, that procd_add_reload_trigger thing should only cause a reload if /etc/config/sqm is changed.

Right!?!?

There's a separate set of commands to add monitoring of interfaces through procd, but we're not using those (we have the hotplug script instead). So I'm not really sure how sqm ends up being reloaded, actually...

Indeed. It is puzzling. Seems like a bug TBH.

Maybe, but that still doesn't explain why the ifupdate event leads to a reload of sqm...

Exactly, which is why it seems like a bug. But what is the OpenWRT component this is a bug with? procd?

@tohojo
Copy link
Owner

tohojo commented Apr 21, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants