What's new

[Release] FreshJR Adaptive QOS (Improvements / Custom Rules / and Inner workings)

  • 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!

Status
Not open for further replies.
@FreshJR I created a rule to tag a few tcp ports to streaming. It was easy to do and worked like a charm. I found that one of my ports I listed in the rule was not needed in that rule. I tried to remove just the port I didn't want Ex. 8443,8883,21047 changed to 8883,21047. When I click apply the rule tries to update itself but spits out this log entry in syslog:
Code:
Feb 24 19:53:18 adaptive QOS: Delayed Start Canceled
Feb 24 19:53:19 adaptive QOS: Applying - Iptable Down Rules
Feb 24 19:53:19 adaptive QOS: iptables v1.4.15: invalid port/service `8883,21047' specified
Feb 24 19:53:19 adaptive QOS: Try `iptables -h' or 'iptables --help' for more information.
Feb 24 19:53:19 adaptive QOS: Applying - Iptable Up   Rules (eth0)
Feb 24 19:53:20 adaptive QOS: iptables v1.4.15: invalid port/service `8883,21047' specified
Feb 24 19:53:20 adaptive QOS: Try `iptables -h' or 'iptables --help' for more information.
Feb 24 19:53:20 adaptive QOS: TC Modification Delayed Start (5min)
To get around this I had to remove the rule and reboot the router, or there was no way I could make the change without those log entries. I would then revert back the port I removed and apply the change and it would accept it. I don't think the rule is actually being recreated and has conflict problems. Other than this small problem, your script works awesome for me!! :D:cool:;):)
 
I couldn't see your customizaton button. ... My issue was nothing on your end

Actually the webpage does not mount during install. It mounts approimatly 10 seconds after your restart qos. (if you have no other scripts executing before my script in firewall-start that can delay this even longer).

If you checked back later or after a reboot I bet it would show up without the factory reset.

I originally did this so people can see that the script isn’t working since qos wasn’t reset. But since this is the 3rd report I will have the webpage re-mount on install and try to have qos restart automatically without user input.

I just need someone on stock/default firmware to check if a specific command extends/works on stock firmware aswell before implementing it.

@skeal can you post the exact parameters of the rule. I will recreate it and look into what is going on.

(Both the before and & after rules you had)
 
When this happens can you (in chrome)

open the classification page -> right click -> select inspect (element / developer tools) -> go to console -> type in device

1) Check if the affected macs in device are in uppercase.

Next type in clientlist

2) Check if all the macs in clientlist are uppercase.

I am thinking maybe some macs are lowercase in one of the two variables.
Devices are showing proper names now. I did go back and redo the name (before I saw your post) by taking out the "_" character that I was using for spaces. I saw some messages in the system log that I believed were pointing to that. Not sure if it fixed that issue or not though. If I see it again I will do this and report back.
 
Did see this in the system log...not sure if it means anything though. Mainly the Bad argument 'j' portion.

Code:
Feb 24 21:35:15 adaptive QOS: Delayed Start Canceled
Feb 24 21:35:16 adaptive QOS: Applying - Iptable Down Rules
Feb 24 21:35:16 adaptive QOS: Applying - Iptable Up   Rules (eth0)
Feb 24 21:35:16 adaptive QOS: Bad argument `j'
Feb 24 21:35:16 adaptive QOS: Try `iptables -h' or 'iptables --help' for more information.
Feb 24 21:35:16 adaptive QOS: TC Modification Delayed Start (5min)
 
Did see this in the system log...not sure if it means anything though. Mainly the Bad argument 'j' portion.

Send the output of debug2.

Seems like one rule isn’t formating correctly.

Are you saying it names dont assigned if a device has an underscore (_) in the nickname?
I need to recreate some of these issues to debug them.
 
Last edited:
Send the output of debug2.

Seems like one rule isn’t formatted correctly.

Are you saying it names dont assigned if a device has an underscore (_) in the nickname?
I need to recreate some of these issues to debug them.
No, those were manual names that I assigned using _ between them. For example my son's tablet would have been Son_Tablet, now just SonTablet.
 
Send the output of debug2.

Seems like one rule isn’t formatted correctly.

Are you saying it names dont assigned if a device has an underscore (_) in the nickname?
I need to recreate some of these issues to debug them.
Debug
Code:
Debug2:

Game CIDR:

Rule1 Down:  -d 192.168.1.114/31 -j MARK --set-mark 0x80040001
Rule1 Up  :  -s 192.168.1.114/31 -j MARK --set-mark 0x40040001

Rule2 Down:  -d 192.168.1.116/30 -j MARK --set-mark 0x80040001
Rule2 Up  :  -s 192.168.1.116/30 -j MARK --set-mark 0x40040001

Rule3 Down:  -d 192.168.1.114/31 -j MARK --set-mark 0x80040001
Rule3 Up  :  -s 192.168.1.114/31 -j MARK --set-mark 0x40040001

Rule4 Down:  -d 192.168.1.133/32 -j MARK --set-mark 0x80060001
Rule4 Up  :  -s 192.168.1.133/32 j MARK --set-mark {VOIP_mark_up}

AppDB1 Down:
AppDB1 Up  :

AppDB2 Down:
AppDB2 Up  :

AppDB3 Down:
AppDB3 Up  :

AppDB4 Down:
AppDB4 Up  :
(Press any key to exit)
Showing this looks like rule 4 is missing the "-" in front?
 
@QuikSilver yup, will be looking into it.
Thanks! Other than those two minor items it's working great. I'll update if I see more or if the Debug item arises. Thanks again for your hard work and valuable time!
 
@skeal can you post the exact parameters of the rule. I will recreate it and look into what is going on.
(Both the before and & after rules you had)
@FreshJR Ok before and after images:
before.png After.png
 
Last edited:
Nice and thanks for the help. Any way to rename the rules? I think I read before that there was some memory limitation before but maybe its not the case anymore?

Yes I didn't have room in nvram to spare to hold user assigned traffic names.

Currently, what you want can still be done but you would have to open webpage in notepad++ and manually change the names. It should be easy to spot the location of the existing name with a CTRL+F search.

You would then follow the (manual install for Non-RMerlin firmware) to upload your modified version to the router.

The manual install guide is not posted yet but should be up by tomorrow.

--

If you wait for next update I will either prepare a 1-line terminal command to replace the rule name or integrate name change functionality into the interactive terminal mode (but not webui mode due to limitations on passing data between the two)

The one-line command is essentially a find&replace command so I have first have to introduce a variable to hold the name instead of having it bring hard-coded as it currently is to allow consecutive use.

--

As an update, I currently am looking into and fixing all the little odds and ends that are being reported. A new revision should be up in not too long since all the fixes are relatively minor.

Since I see the reports of many users on pre384.9, I may consider backporting the changes to the classification page so I the affected people can use it needing to update.

But even doing so, implementing the tracked connections table will not be possible pre 384.9. Is there big enough demand to extend customizing then rules via WebUI on old firmware’s?? Not sure if I should bother.
 
Last edited:
Actually the webpage does not mount during install. It mounts approimatly 10 seconds after your restart qos. (if you have no other scripts executing before my script in firewall-start that can delay this even longer).

If you checked back later or after a reboot I bet it would show up without the factory reset.

I originally did this so people can see that the script isn’t working since qos wasn’t reset. But since this is the 3rd report I will have the webpage re-mount on install and try to have qos restart automatically without user input.

I just need someone on stock/default firmware to check if a specific command extends/works on stock firmware aswell before implementing it.

@skeal can you post the exact parameters of the rule. I will recreate it and look into what is going on.

(Both the before and & after rules you had)
I posted those before and after images above in post #2531
 
@FreshJR dumb question...the older script had 4 rules created for gaming with a static IP address using cidr. On the new script I have assigned the gaming ip address, my question is do I have to add those 4 rules to the script?
 
in some cases i am getting this as client names in classification page:
upload_2019-2-25_14-18-3.png


in client list is the name correct. same string is visible in the drop-down list on many places :
upload_2019-2-25_14-20-1.png


something wrong with DHCP or name resolution?
 
in some cases i am getting this as client names in classification page:
View attachment 16384

in client list is the name correct. same string is visible in the drop-down list on many places :
View attachment 16385

something wrong with DHCP or name resolution?
Mine was doing the same thing. Mine initially stated DEBUG:NVRAM and then I noticed DEBUG:DHCP. I manully changed the name of my devices to take out a special character I was using to put a space in between "_". Does yours have something similar. Also check out @FreshJR 's post to mine so he can look into it.

Code:
https://www.snbforums.com/threads/release-freshjr-adaptive-qos-improvements-custom-rules-and-inner-workings.36836/page-126#post-468423
 
i followed to check for device and client list objects and after checking i think that the DEBUG: DHCP is there for clients that are no longer listed in client list, but are still in device list ...
 
@FreshJR dumb question...the older script had 4 rules created for gaming with a static IP address using cidr. On the new script I have assigned the gaming ip address, my question is do I have to add those 4 rules to the script?

Everything is included no need to modify anything.

i followed to check for device and client list objects and after checking i think that the DEBUG: DHCP is there for clients that are no longer listed in client list, but are still in device list ...

Correct, if a MAC device in the “device” list does not match a MAC in the “clientlist”, the name corresponding to that devices will not be resolved and instead be listed as a “DEBUG” string.

I need to know more about what is happening:

Were these macs not yet in the clientlist?

Were they in the clientlist but the case sensitivity of the two macs not mathcing (lower or uppercase)

Were affected devices brand new devices that were connected to the network for the first time??

I ask since my client list has of historic data about any device ever connected and is a very reliable source for existing decices. Not sure about new devices since I am in a home setting, but I assume it takes a while for them to be added.

Does the dhcp table itself have the names of these devices or do they resolve into “*”?
 
Last edited:
the MACs with DEBUG: DHCP are in device list but not in client list, all MACs in both lists are in proper upper case.
 
the MACs with DEBUG: DHCP are in device list but not in client list, all MACs in both lists are in proper upper case.

I updated the post.

Please check if names appear in the dhcp table (in WebUI) or from the arp command (terminal).

A debug string is expected when no match occurs. (That’s how I coded it so I could see which devices are missing from the client list)

Still. Are these brand new devices connecting for the first time ?
 
some of them have an * in DHCP table, some have proper names there.
 
Status
Not open for further replies.

Latest 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!
Top