SHOREWALL-TCPRI(5) | Configuration Files | SHOREWALL-TCPRI(5) |
NAME¶
tcpri - Shorewall file
SYNOPSIS¶
/etc/shorewall[6]/tcpri
DESCRIPTION¶
This file is used to specify the priority of traffic for simple traffic shaping (TC_ENABLED=Simple in shorewall.conf[1](5)). Beginning with Shorewall 5.2.7, the file allows ?FORMAT 2 which inserts a SPORT column immediately to the right of the DPORT column.
The priority band of each packet is determined by the last entry that the packet matches. If a packet doesn't match any entry in this file, then its priority will be determined by its TOS field. The default mapping is as follows but can be changed by setting the TC_PRIOMAP option in shorewall.conf[1](5).
TOS Bits Means Linux Priority BAND ------------------------------------------------------------ 0x0 0 Normal Service 0 Best Effort 2 0x2 1 Minimize Monetary Cost 1 Filler 3 0x4 2 Maximize Reliability 0 Best Effort 2 0x6 3 mmc+mr 0 Best Effort 2 0x8 4 Maximize Throughput 2 Bulk 3 0xa 5 mmc+mt 2 Bulk 3 0xc 6 mr+mt 2 Bulk 3 0xe 7 mmc+mr+mt 2 Bulk 3 0x10 8 Minimize Delay 6 Interactive 1 0x12 9 mmc+md 6 Interactive 1 0x14 10 mr+md 6 Interactive 1 0x16 11 mmc+mr+md 6 Interactive 1 0x18 12 mt+md 4 Int. Bulk 2 0x1a 13 mmc+mt+md 4 Int. Bulk 2 0x1c 14 mr+mt+md 4 Int. Bulk 2 0x1e 15 mmc+mr+mt+md 4 Int. Bulk 2
The columns in the file are as follows.
BAND - {1|2|3}
PROTO - protocol[,...]
Beginning with Shorewall 4.5.12, this column can accept a comma-separated list of protocols.
DPORT - port [,...]
Optional. May only be given if the the PROTO is TCP (6), UDP (17), DCCP (33), SCTP (132) or UDPLITE (136). A list of one or more port numbers or service names from /etc/services. Port ranges of the form lowport:highport may also be included. In format 1, packets whose source or destination port matches the specified port(s) are assigned to the band given in the BAND column.
SPORT - port [,...]
ADDRESS - [address]
INTERFACE - [interface]
Note
INTERFACE classification of packets occurs before classification by PROTO/PORT(S)/ADDRESS. So it is highly recommended to place entries that specify INTERFACE at the top of the file so that the rule about last entry matches is preserved.
HELPER - [helper]
FILES¶
/etc/shorewall/tcpri
/etc/shorewall6/tcpri
SEE ALSO¶
https://shorewall.org/configuration_file_basics.htm#Pairs[3]
prio(8), shorewall(8)
NOTES¶
- 1.
- shorewall.conf
- 2.
- shorewall-tcinterfaces
- 3.
- alternate input format
09/24/2020 | Configuration Files |