Skip to content

Commit

Permalink
fix some typos? hope this works
Browse files Browse the repository at this point in the history
  • Loading branch information
dlakelan committed Aug 29, 2022
1 parent ae73e45 commit 81f6ce8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions dscptag.nft
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,14 @@ table inet dscptag {
ip6 nexthdr udp ip6 dscp > cs2 add @udp_meter6 {ip6 saddr . ip6 daddr . udp sport . udp dport limit rate over 450/second} counter ip dscp set cs2

# down prioritize the first 500ms of tcp packets
ip protocol tcp ct bytes > $downrate * 500/8 ip dscp < cs4 ip dscp set cs2
ip protocol tcp ct bytes > ($downrate * 500/8) ip dscp < cs4 ip dscp set cs2

# downgrade tcp that has transferred more than 10 seconds worth of packets
ip protocol tcp ct bytes > $downrate * 10000/8 ip dscp < cs4 ip dscp set cs1
ip protocol tcp ct bytes > ($downrate * 10000/8) ip dscp < cs4 ip dscp set cs1

## tcp with less than 150 pps gets upgraded to cs4
ip protocol tcp add @slowtcp4 {ip saddr . ip daddr . udp sport . udp dport limit 150/second burst 150} ip dscp set cs4
ip6 nexthdr tcp add @slowtcp6 {ip6 saddr . ip6 daddr . udp sport . udp dport limit 150/second burst 150} ip dscp set cs4
ip protocol tcp add @slowtcp4 {ip saddr . ip daddr . udp sport . udp dport limit rate 150/second burst 150} ip dscp set cs4
ip6 nexthdr tcp add @slowtcp6 {ip6 saddr . ip6 daddr . udp sport . udp dport limit rate 150/second burst 150} ip dscp set cs4


}
Expand Down

0 comments on commit 81f6ce8

Please sign in to comment.