Qosify: new package for DSCP marking + cake

Not sure how this is set, but looking at cake's source code should settle that....

Just a side-note, since I have been observing that qosify does not offer DSCP marking based on internal IP addresses/port tupels. At least for egress traffic that can be easily implemented as a traffic rule like the following disabled snippet for /etc/config/firewall:

config rule
        option src '*'
        list src_ip '192.168.42.201'
        option target 'DSCP'
        option dest '*'
        option set_dscp 'EF'
        list proto 'tcp'
        list proto 'udp'
        list proto 'icmp'
        option enabled '0'

In this example ports are ignored... the same can also be achieved with the firewall GUI, just add a new rule in the "Traffic Rules" tab and choose "DSCP classification" as action and the desired DSCP value.

4 Likes

@amteza Qosify Port tagging has never worked for me and I tried multiple platforms (2 x86 Mini Pc’s, Rpi3+ and a WRT1200) and also different versions. Tried to communicate the issue a while ago with no success.

What works is tagging packets in the /etc/config/qosify:
Like tagging all tcp/udp packets or trigger tagging based on pps or packet length:
For example:

option dscp_default_tcp 
option dscp_default_udp
option bulk_trigger_pps 600
option bulk_trigger_timeout 10
option dscp_bulk CS1
option prio_max_avg_pkt_len 575
option dscp_prio AF41
...

What also works is if you tag based on specific ip in the /etc/qosify/00-defaults.conf

#test
8.8.8.8  CS7

At least this has always worked for me!!

What does not work is for example (neither with a class nor a DSCP):

# Gaming
udp:3074 CS5

I guess when people say their Qosify work they assume it because they set thresholds for pps, packet length, default udp in their /config/qosify and they never really do packet captures to verify that port tagging in the 00-defaults.conf is done right (they just check their tc -s qdisc)....

One way to verify if tagging works correct is to set up a simple qosify configuration. Something like that:

et/config/qosify

config defaults
 list defaults /etc/qosify/*.conf
 option dscp_icmp besteffort
 option dscp_default_udp besteffort
 option dscp_default_tcp besteffort

config class besteffort
 option ingress CS0
 option egress CS0

With this all packets should be tagged with CS0

Then in etc/qosify/00-defaults.conf put in the port you want to be tagged (in your case dns on port 53)

# Gaming
udp:3074 CS5

# DNS
tcp:53  CS7
tcp:5353 CS7
udp:53 CS7
udp:5353 CS7

Play a game of Cod warzone -> should be CS5
Or in your case make dns requests -> should be CS7

My internet hangs after a reboot, I saw logs in dmesg:

[Thu May  5 12:05:22 2022] net_ratelimit: 10 callbacks suppressed
[Thu May  5 12:05:22 2022] tc mirred to Houston: device ifb-dns is down

After restarting the qosify service, the interface came up correctly and the internet appeared.

I solved it by changing the priority of qosify after the network-service was up: mv rc.d/S19qosify -> S29qosify

1 Like

yes you're totally right and it's good to hear it :slight_smile: I changed my packages to CS5 two days ago and my game has literally changed, I don't know if it will last but it works pretty well I I did a capture with wireshark and my packages are in CS5, today I see your post and it confirms my idea that CS5 is better for Warzone :wink: health and happiness

this is my config now

config defaults
	list defaults /etc/qosify/*.conf
	option dscp_icmp +besteffort
	option dscp_default_tcp unmarked_traffic
	option dscp_default_udp unmarked_traffic

config class unmarked_traffic
	option ingress CS1
	option egress CS1
	option prio_max_avg_pkt_len 1270
	option dscp_prio CS5
	option bulk_trigger_pps 600
	option bulk_trigger_timeout 10
	option dscp_bulk CS1

config class browsing
	option ingress CS0
	option egress CS0
	option prio_max_avg_pkt_len 575
	option dscp_prio AF41
	option bulk_trigger_pps 1000
	option bulk_trigger_timeout 10
	option dscp_bulk CS1

config class bulk
	option ingress CS1
	option egress CS1

config class besteffort
	option ingress CS0
	option egress CS0

config class network_services
	option ingress CS2
	option egress CS2

config class broadcast_video
	option ingress CS3
	option egress CS3

config class gaming
	option ingress CS5
	option egress CS5

config class multimedia_conferencing
	option ingress AF42
	option egress AF42
	option prio_max_avg_pkt_len 575
	option dscp_prio AF41

config class telephony
	option ingress EF
	option egress EF

config interface wan
	option name wan
	option disabled 0
	option bandwidth_up 16mbit
	option bandwidth_down 56mbit
	option overhead_type bridged-ptm
	# defaults:
	option ingress 1
	option egress 1
	option mode diffserv4
	option nat 1
	option host_isolate 1
	option autorate_ingress 0
	option ingress_options ""
	option egress_options "wash"
	option options "ether-vlan"

config device wandev
	option disabled 1
	option name wan
	option bandwidth 100mbit


@segal72 you should be tested maybe with fifa22 if you are again a latency in your play

2 Likes

am not using snapshot, still on 21.02.2 [which officially does not support qosify but luckily installing from .ipk works] thus unfortunately i have no definite answer why it is not working out of box. maybe time for file a bug report?

1 Like

Thanks heaps, mate! I thought I was going cray-cray! And you are right, we confirmed that using a server IP it works, that fooled me in thinking it was me doing something wrong, hence my request for help.

I wouldn't guess, this is exactly what is happening.

1 Like

Wait, what?! I think you should read again, @Hudra says nothing about CS5 being better for Warzone, it's just an example to illustrate a point.

1 Like
# DNS
tcp:53		voice
tcp:5353	voice
udp:53		voice
udp:5353	voice

does alternative 00-defaults.conf setup achieve desired result?

No, it does not.

hi, your wireshark picture is showing a flow with src port 3074 and dst port 42270, for my benefit could you pls confirm what it is actually showing: is it a traffic on your wan interface, is it an incoming or outgoing flow? in short: which port is the local or near-end? and how did you capture it, as I guess wireshark is not running on your router?

I used tee before to capture with iptables now I have an HP switch that sniffs packets to connect to my console and the computer

Omg thanks for your confirmation! I thought I was going crazy too. Like @grrr2 said maybe we should file a bug report.

@Dopam-IT_1987 my post was about port tagging in 00-defaults.conf not working and not what DSCP is best for gaming. I think with cake, as long as you choose a DSCP Tag going into the voice tin you are good to go and I think it makes no difference if you choose CS4 or CS5 or CS7 for gaming...

2 Likes

Exactly, for cake all that matters is which priority tin a DSCP maps to... your ISP might or might not be happy with you inflicting unusual DSCPs onto its network, but if you use cake's wash keyword, cake will use the DSCP to steer packets into the appropriate priority tin abut will the re-mark the packet as default/best effort/CS0 so upstream networks never see your internal markings.

2 Likes

at the moment I'm a bit like @xato_coslada my game is very average and I don't understand why this sudden degradation whether it's qosify or sqm :confused:

Or none of them. Anything outside your network is out of your control, full stop.

Yeah, this is fun. People is trying to use Qosify to mark packets outgoing to port 3074 for this specific game. However, this game —COD Warzone— is opening a listener in port 3074, so they should be marking inbound connections to this port and not outbound connections to it.

Oh, well...

1 Like

I redid my line two months ago vdsl2 nine 70 20 mbps bulb changed at the level of looks change of card at the level of the new internet box nra ....

how to mark incoming connections suddenly?? :slight_smile:

call of duty has changed a lot I've been playing this game for about fifteen years I've never had so much difficulty setting up a game as this when I see this kind of video I tell myself that we haven't the same connection

the best streamer are french but there are not 40 operators I played on pc before and the fluidity was not such as well as the hitregs

Are you using a translator? Can you try DeepL? I've serious issues following what you are trying to say. Sorry, mate.