差異處

這裏顯示兩個版本的差異處。

連向這個比對檢視

unifi [2024/07/20 08:17]
jz 建立
unifi [2024/07/20 11:22] (目前版本)
jz [Fix Wireguard MTU]
行 1: 行 1:
 ====== UniFi ====== ====== UniFi ======
  
-===== Fix Wireguard ​MTU =====+===== Fix WireGuard ​MTU =====
 Refer to Refer to
-https://​community.ui.com/​questions/​Wireguard-Client-Server-Issue-Accessing-Certain-Websites-MTU-issue/​373f7a7b-36be-4645-89c7-870fcf759c85?​page=2+[[https://​community.ui.com/​questions/​Wireguard-Client-Server-Issue-Accessing-Certain-Websites-MTU-issue/​373f7a7b-36be-4645-89c7-870fcf759c85?​page=2]]
  
 <​code>​ <​code>​
 root:~# cat /​data/​scripts/​change-wg-mtu.sh root:~# cat /​data/​scripts/​change-wg-mtu.sh
-#/bin/bash +#/bin/sh 
-iptables -t mangle -A UBIOS_FORWARD_TCPMSS -o wgclt1 -p tcp -m tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu +export PATH=/​usr/​sbin:​$PATH 
-iptables -t mangle -A UBIOS_FORWARD_TCPMSS -i wgclt1 -p tcp -m tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu +#iptables -t mangle -A UBIOS_FORWARD_TCPMSS -o wgclt1 -p tcp -m tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu 
-iptables -t mangle -A UBIOS_OUTPUT_TCPMSS -o wgclt1 -p tcp -m tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu+#iptables -t mangle -A UBIOS_FORWARD_TCPMSS -i wgclt1 -p tcp -m tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu 
 +#iptables -t mangle -A UBIOS_OUTPUT_TCPMSS -o wgclt1 -p tcp -m tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu
 iptables -t mangle -A UBIOS_FORWARD_TCPMSS -o wgclt1 -p tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu iptables -t mangle -A UBIOS_FORWARD_TCPMSS -o wgclt1 -p tcp --tcp-flags SYN,RST SYN -j TCPMSS --clamp-mss-to-pmtu