What's new
  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

spdMerlin spdMerlin v4.4.14 [2025-Jul-12] - Internet Speedtest and Monitoring Tool for AsusWRT Merlin

Something odd is happening.
I have auto speed tests configured for AUTOBW.
I have them excluded from QoS so QoS won't interfere.
Today, I configured a wireguard vpn client (wgc2). I included it in auto speed tests just for sake of fun.
Every speed test I realize (even with exclude from QoS), the wan interface is affected by QoS values, but the wgc2 don't as expected.
I tried to set my QoS down/up to 10mbps to test and yes, as soon as I start a speed test, it's capped to 10mbps on Wan (which isn't supposed), but not on wgc2.

What speedtest binary are you using? Built in or external? Does it make a difference to your observations?
 
Something odd is happening.
I have auto speed tests configured for AUTOBW.
I have them excluded from QoS so QoS won't interfere.
Today, I configured a wireguard vpn client (wgc2). I included it in auto speed tests just for sake of fun.
Every speed test I realize (even with exclude from QoS), the wan interface is affected by QoS values, but the wgc2 don't as expected.
I tried to set my QoS down/up to 10mbps to test and yes, as soon as I start a speed test, it's capped to 10mbps on Wan (which isn't supposed), but not on wgc2.
I'm not very familiar with all configuration parameters used by spdMerlin, especially those regarding QoS (I don't use QoS or spdMerlin in my own home router). But, to gather some clues, I've added code to leave log messages during Speedtests when stopping and restarting QoS (if enabled).

This new code is available only in the latest 'develop' branch, so if you want to run the 'develop' version, you can switch from the installed 'master' branch to the latest 'develop' branch with the following command:
Bash:
/jffs/scripts/spdmerlin develop

If you were already running the 'develop' branch version, you can force an update to get the very latest changes with the following command:
Bash:
/jffs/scripts/spdmerlin forceupdate

If you run the latest 'develop' version, please provide the full output generated when running the Speedtest via the CLI menu.
 
B
I'm not very familiar with all configuration parameters used by spdMerlin, especially those regarding QoS (I don't use QoS or spdMerlin in my own home router). But, to gather some clues, I've added code to leave log messages during Speedtests when stopping and restarting QoS (if enabled).

This new code is available only in the latest 'develop' branch, so if you want to run the 'develop' version, you can switch from the installed 'master' branch to the latest 'develop' branch with the following command:
Bash:
/jffs/scripts/spdmerlin develop

If you were already running the 'develop' branch version, you can force an update to get the very latest changes with the following command:
Bash:
/jffs/scripts/spdmerlin forceupdate

If you run the latest 'develop' version, please provide the full output generated when running the Speedtest via the CLI menu.
Besides those improved log messages, was anything changed between stable and develop version?
I'm asking because, after changing to develop and run a few speedtests with QoS set to a very low value (as I did on stable version), the QoS fully stops and the Speedtest runs at max speed 🤔
 
Besides those improved log messages, was anything changed between stable and develop version?
I'm asking because, after changing to develop and run a few speedtests with QoS set to a very low value (as I did on stable version), the QoS fully stops and the Speedtest runs at max speed 🤔
Several changes have been accumulating in the 'develop' branch version since the latest production 4.4.12 release was issued on June 22. Among those, the only change that I can think of that may have an effect on the code dealing with QoS would be a 3-second delay that I added after stopping (and later restarting) QoS to allow the operation to be completed before initiating the Speedtest. I suppose it's possible that without the short delay, the Speedtest may have started "too early" while QoS was not yet completely stopped.
 
Several changes have been accumulating in the 'develop' branch version since the latest production 4.4.12 release was issued on June 22. Among those, the only change that I can think of that may have an effect on the code dealing with QoS would be a 3-second delay that I added after stopping (and later restarting) QoS to allow the operation to be completed before initiating the Speedtest. I suppose it's possible that without the short delay, the Speedtest may have started "too early" while QoS was not yet completely stopped.
It sure must be, because it only happens on Wan speed test (which is the first). The ones following, QoS is fully stopped and don't get capped.

As soon as I change to stable again, same problem happens, so it must be the 3 second delay 🙏🏻
 
It sure must be, because it only happens on Wan speed test (which is the first). The ones following, QoS is fully stopped and don't get capped.
Yes, that makes sense. Since the WAN interface is always the first (unless you explicitly exclude it), it would be the most likely to be affected by QoS when the Speedtest was started "too early" while shutting off QoS.
 
Martinski also added a command to reset the interfaces in PR: https://github.com/AMTM-OSR/spdMerlin/pull/35
Please try again by updating to the develop branch with Martinski's instructions, and report back after your reboot :)

Thanks!
Tested last night. The added delay was enough for one of my OVPN interfaces to come up, but not the second one.

Hopefully, it isn't too difficult for Viktor to add a reset to VPNMON-R3 because I think that is the best option.
 
Tested last night. The added delay was enough for one of my OVPN interfaces to come up, but not the second one.

Hopefully, it isn't too difficult for Viktor to add a reset to VPNMON-R3 because I think that is the best option.
Success. I had both a Non-Responsive VPN slot failure last night and a reboot this morning and all interfaces are still included for spdmerlin.

Thank you all.
 
Release Notes for spdMerlin v4.4.13 production version now available
[2025-July-03]


1) IMPROVED: Added a delay after stopping and then later after restarting QoS (if enabled) to allow the operation to be completed before initiating a Speedtest.

2) IMPROVED: Added log messages when stopping and later restarting QoS (if enabled).

3) IMPROVED: Added a delay to the reboot startup sequence that checks if VPN interfaces are up and ready for spdMerlin. This extra delay during reboot allows more time for all VPN interfaces to be initialized and become ready.

4) NEW: Added new CLI parameters "reset_interfaces force" to trigger an on-demand recheck of all VPN interfaces and reset them in cases where a VPN interface was previously found "disabled" but later becomes "enabled" and is now in a ready/active state.
[Based on a suggestion from @iTyPsIDg]​

The full command is the following:​
Bash:
/jffs/scripts/spdmerlin reset_interfaces force

5) Miscellaneous code improvements.


The fork from @Jack Yaz's spdMerlin add-on is now hosted on the AMTM-OSR GitHub repo:
 
Release Notes for spdMerlin v4.4.14 production version now available
[2025-July-12]


1) FIXED: When choosing to set a preferred server for speed tests, a bug was causing an endless loop when the request to get the list of closest servers was sent and failed. Upon failure, the code was not checking for an empty list (it assumed at least 1 entry), so it went into an infinite loop generating "[: bad number" error messages and creating a large temporary file in the TMPFS partition while trying to parse the *empty* server list. This happened when using the WebUI page only.

2) FIXED: On the WebUI page, the Manual Speedtest using the "Choose a Server" option for "All" interfaces was not working when more than one interface was enabled; instead, it would appear to get "stuck" indefinitely waiting to get back some results.

3) FIXED: A bug was corrupting the configuration file when a user selected a preferred server for an interface, and the server name info happened to contain certain special characters (e.g. ampersand '&'). The result corrupted the entry for the specified interface in the configuration file.

4) IMPROVED: When the request to get a list of closest servers fails, an error notification is shown on the WebUI page, and a log message is sent to the system log.

5) IMPROVED: Added code to allow users to reset the preferred server selection for an interface.

6) Miscellaneous code improvements.

Example screenshot when the request to get the list of closest servers is sent and fails:

spdMerlin_v4.4.14_ServerListError.jpg


The fork from @Jack Yaz's spdMerlin add-on is now hosted on the AMTM-OSR GitHub repo:


P.S. A special shout-out to my nephew Samuel for finding and reporting all 3 bugs that were fixed in this release. Great job, buddy!!
 
Just a quick suggestion, since this great script got proper logging levels after it became under the OSR-AMTM repository.

I used to filter spdMerlin log messages depending on message content only since it didn't have log levels before. Now that it got that much needed feature, I just had the time a week ago to edit my syslog-ng filter to depend on log level.

I used a template specifically to show the priority level of each log message from spdMerlin and monitored the log for a couple of days before deciding which messages I need and which I don't. So after I sorted everything out, and made the change on my filter, I noticed the following..

As I have one of the worst internet connections in the world, I get a lot of failed Speedtest messages, so there's a need for me to filter out more log messages. Having the log level showed for every message, it came to my attention that something is not optimal with the log levels of failed speed tests in spdMerlin log messages.

Please take a look at the attached screenshot, you'll notice that I get two error messages every time my WAN interface fails the speed test. The not optimal thing is that both messages are of "crit" log level, although the first message content says "ERROR" at the very beginning, and the second message is a new log message added with the upgrade of spdMerlin to the OSR repo.

My suggestion is to lower the failed speed test message to "warn" log level and the second message to "error" log level since it will always be logged when one of the prior speed tests fail. Please also keep in mind that if a user tests the speed of more interfaces, there will be more of the first log message. So using either "warn" and "error" levels respectively, or "error" and "critical" levels respectively would be a good practice.

Kindly,
 

Attachments

  • 2025-07-19_22-53-15.png
    2025-07-19_22-53-15.png
    86.2 KB · Views: 13
And here's the big bomb! An emergency!!!

I just figured out what corrupted my spdMerlin script's whole setup a week ago while I was experimenting with logging as stated in my last post.

I just got it corrupted again a few minutes ago. I'll keep it corrupted for now. So, please guide me how to provide all the debugging information you need to solve the bug before I reset the database and reconfigure the settings again.

The error occurs exactly when I enable "WAN" in the list of "Interfaces that use a preferred server", knowing that I have a valid entry for the preferred server of the WAN interface, and it works totally okay when setup again. After submitting the change to enable the preferred server for WAN, all settings get lost and all database records of previous speed tests are gone too, both in GUI and CLI.

I believe this bug started happening with one of the very latest versions of the script. As I used to make this change normally in the past.

Dear @Martinski, and @ExtremeFiretop, and others in the team, I appreciate your quick attention, hoping for a quick response as soon as possible.

EDIT: A tip that could help in debugging, I use USB for storage not JFFS, and when doing the change that causes this bug, it switches to JFFS without me changing it to JFFS before submitting my desired other change!

EDIT 2: Split the scroll screenshot into 3 smaller screenshots for clarity. These screenshots are from "after" the bug occurs.
 

Attachments

  • 2025-07-20_00-27-49 (1).png
    2025-07-20_00-27-49 (1).png
    223.2 KB · Views: 8
  • 2025-07-20_00-27-49 (2).png
    2025-07-20_00-27-49 (2).png
    110.6 KB · Views: 8
  • 2025-07-20_00-27-49 (3).png
    2025-07-20_00-27-49 (3).png
    103.7 KB · Views: 8
Last edited:
Just a quick suggestion, since this great script got proper logging levels after it became under the OSR-AMTM repository.

I used to filter spdMerlin log messages depending on message content only since it didn't have log levels before. Now that it got that much needed feature, I just had the time a week ago to edit my syslog-ng filter to depend on log level.

I used a template specifically to show the priority level of each log message from spdMerlin and monitored the log for a couple of days before deciding which messages I need and which I don't. So after I sorted everything out, and made the change on my filter, I noticed the following..

As I have one of the worst internet connections in the world, I get a lot of failed Speedtest messages, so there's a need for me to filter out more log messages. Having the log level showed for every message, it came to my attention that something is not optimal with the log levels of failed speed tests in spdMerlin log messages.

Please take a look at the attached screenshot, you'll notice that I get two error messages every time my WAN interface fails the speed test. The not optimal thing is that both messages are of "crit" log level, although the first message content says "ERROR" at the very beginning, and the second message is a new log message added with the upgrade of spdMerlin to the OSR repo.

My suggestion is to lower the failed speed test message to "warn" log level and the second message to "error" log level since it will always be logged when one of the prior speed tests fail. Please also keep in mind that if a user tests the speed of more interfaces, there will be more of the first log message. So using either "warn" and "error" levels respectively, or "error" and "critical" levels respectively would be a good practice.

Kindly,
I don't quite understand your reasoning for changing the current log level/priority of the 2 log messages referenced in your post and shown in your screenshot.

Can you articulate exactly what the issue is with the current log levels being "critical"?
Are they causing an actual problem or malfunction?
Or is this just a cosmetic issue due to a personal preference?

What would be the benefits of the suggested changes?

Please be very clear and specific about the problem you're seeing.
 
Can you articulate exactly what the issue is with the current log levels being "critical"?
Are they causing an actual problem or malfunction?
Or is this just a cosmetic issue due to a personal preference?
It's not an issue at all, just a "cosmetic preference".

What would be the benefits of the suggested changes?
The benefit would be producing less "critical" log messages, as there is nothing (really) critical to get immediate attention from a user. From my point of view, "critical" should be kept for more serious problems, presumably for script's own errors and malfunctions.

So in general, when doing automatic speed tests for more than one interface, each interface that fails the test gives an "error" log message, then after all speed tests are done, if there were any errors, a higher level log message, let's say "critical", is produced to indicate that one or more speed tests has failed.
However, I just realized that the log message "Speedtest failed" does not get produced when VPNC1 Speedtest fails. I mistakenly assumed that the second log message in my first example gets produced whenever there's at least one failed test.



Anyway, I'm more concerned now about the bug I reported in my previous post, looking to know what exactly happened and why I lost my spdMerlin database for the third time!
 
Last edited:
And here's the big bomb! An emergency!!!

I just figured out what corrupted my spdMerlin script's whole setup a week ago while I was experimenting with logging as stated in my last post.

I just got it corrupted again a few minutes ago. I'll keep it corrupted for now. So, please guide me how to provide all the debugging information you need to solve the bug before I reset the database and reconfigure the settings again.

The error occurs exactly when I enable "WAN" in the list of "Interfaces that use a preferred server", knowing that I have a valid entry for the preferred server of the WAN interface, and it works totally okay when setup again. After submitting the change to enable the preferred server for WAN, all settings get lost and all database records of previous speed tests are gone too, both in GUI and CLI.

I believe this bug started happening with one of the very latest versions of the script. As I used to make this change normally in the past.

Dear @Martinski, and @ExtremeFiretop, and others in the team, I appreciate your quick attention, hoping for a quick response as soon as possible.

EDIT: A tip that could help in debugging, I use USB for storage not JFFS, and when doing the change that causes this bug, it switches to JFFS without me changing it to JFFS before submitting my desired other change!

First, you'll need to provide clear and readable screenshots of your WebUI configuration, ideally the "BEFORE" and "AFTER" screenshots WRT the scenario you described. There's no point in providing a screenshot that's unreadable.

Then, please provide step-by-step instructions to recreate the problem. If you prefer, provide screenshots and list the configuration parameters that were changed (e.g. Option 'A' was changed from 'X' to 'Y' setting).

Finally, run the attached shell script to get some debug info. Also, ideally, it would be good to get the "BEFORE" and "AFTER" results if you can; otherwise, simply provide the current output file for now (if you cannot recreate the problem later on).

Run BEFORE recreating the problem:
Bash:
./DEBUG_spdMerlin_INFO.sh before

Run AFTER the problem has already happened:
Bash:
./DEBUG_spdMerlin_INFO.sh after

If you'd rather provide the debug info via a DM, that's fine with me too.
 

Attachments

There's no point in providing a screenshot that's unreadable.
Totally right!
My bad, I didn't realize that my screenshot became unreadable after I uploaded it here to my post. I know this screenshot will provide zero clue.

If you'd rather provide the debug info via a DM, that's fine with me too.
Yes, I'm pretty sure I can reproduce the bug again. I'll provide you with the results of all needed troubleshooting steps within 24 hours.
Thank you!
 
It's not an issue at all, just a "cosmetic preference".


The benefit would be producing less "critical" log messages, as there is nothing (really) critical to get immediate attention from a user. From my point of view, "critical" should be kept for more serious problems, presumably for script's own errors and malfunctions.
A failure to get Speedtest results is considered "critical" because that's the core functionality for the add-on, and presumably, the user expects to get results. In any case, I don't see the value of spending time on this "cosmetic preference" (especially when my spare, free time is limited), and then someone may want some other message log levels set to "warning" or "error" just because that's their "personal preference."
 
A failure to get Speedtest results is considered "critical" because that's the core functionality for the add-on, and presumably, the user expects to get results.
I totally agree. It's good to hear other opinions

In any case, I don't see the value of spending time on this "cosmetic preference" (especially when my spare, free time is limited)
I apologize for any inconvenience!
 

Similar threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Back
Top