This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Copyright (c) 2017, Sky UK Ltd All rights reserved. | |
Redistribution and use in source and binary forms, with or without modification, are permitted provided | |
that the following conditions are met: | |
Redistributions of source code must retain the above copyright notice, this list of conditions and the | |
following disclaimer. | |
Redistributions in binary form must reproduce the above copyright notice, this list of conditions and |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* IPVS: Source Hashing scheduling module | |
* | |
* Authors: Wensong Zhang <wensong@gnuchina.org> | |
* | |
* This program is free software; you can redistribute it and/or | |
* modify it under the terms of the GNU General Public License | |
* as published by the Free Software Foundation; either version | |
* 2 of the License, or (at your option) any later version. | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# The loopback network interface | |
auto lo | |
iface lo inet loopback | |
# vdsl modem / wan port | |
auto eth0 | |
iface eth0 inet static | |
address 192.168.10.2 | |
netmask 255.255.255.0 | |
# to support jumbo frames on ppp (1500 mtu + 8 byte PPPoE overhead) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
/sbin/ethtool -K ppp0 gro off gso off |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ppp0 1 full full 1 default,fq_codel | |
ifb0:2 1 full full 1 default,fq_codel |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This should be set to slightly less than your raw upload speed. | |
ppp0 0 19mbit | |
# This should be set to slightly less than your raw download speed. | |
ifb0 0 72mbit classify ppp0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Setup ifb to ratelimit upload for fq_codel. | |
modprobe ifb numifbs=1 | |
ip link set ifb0 up |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# wan is setup with some basic filtering settings. | |
wan ppp0 detect routefilter,tcpflags | |
# lan is bridged and uses dhcp. | |
lan br0 detect dhcp,bridge | |
# modem is a separate interface for direct access to the vDSL UI. | |
modem eth0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ppp0 192.168.0.0/16,10.10.3.0/24 | |
eth0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ACTION SOURCE DEST PROTO DPORT SPORT ORIGDEST | |
# allow certain ICMP to not break TCP and pings | |
ACCEPT wan fw icmp 0,3,4,8,11 | |
# example port forwarding | |
DNAT wan lan:192.168.1.10 tcp 2628 | |
DNAT wan lan:192.168.1.10 udp 2628 |
OlderNewer