Change MSS

2017/12/25 10:47 于 RouterOS 0

It is a well known fact that VPN links have smaller packet size due to encapsulation overhead. A large packet with MSS that exceeds the MSS of the VPN link should be fragmented prior to sending it via that kind of connection. However, if the packet has DF flag set, it cannot be fragmented and should be discarded. On links that have broken path MTU discovery (PMTUD) it may lead to a number of problems, including problems with FTP and HTTP data transfer and e-mail services.

In case of link with broken PMTUD, a decrease of the MSS of the packets coming through the VPN link solves the problem. The following example demonstrates how to decrease the MSS value via mangle:

/ip firewall mangle 
add out-interface=pppoe-out protocol=tcp tcp-flags=syn action=change-mss new-mss=1300 chain=forward tcp-mss=1301-65535

脚本-自动删除close连接,提升系统资源

2017/12/25 10:34 于 RouterOS 0

/ system scheduler add name="del_close" on-event="/ip firewall connection \
remove [/ip firewall connection find tcp-state=close]" start-date=jan/01/1990 \
start-time=00:00:00 interval=1m comment="" disabled=no

蕾丝边

2017/11/15 19:07 于 镜观天下 0