]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/commitdiff
aws: Configure MTU to maximum of 9001 on GREEN/ORANGE
authorMichael Tremer <michael.tremer@ipfire.org>
Mon, 15 Jun 2020 15:20:49 +0000 (15:20 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 19 Jun 2020 17:14:58 +0000 (17:14 +0000)
AWS supports jumbo-frames which IPFire can take advantage of
to increase network throughput internally.

The MTU for RED was left as 1500 to avoid packet fragmentation
in the cloud network and have IPFire do that job.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/initscripts/helper/aws-setup

index 8843198221df07be6f74ab9343cadcc621007a04..9b67019d625823f5c3c4f943b857bd7641ca24cd 100644 (file)
@@ -6,6 +6,9 @@
 # Set PATH to find our own executables
 export PATH=/usr/local/sbin:/usr/local/bin:${PATH}
 
+# AWS supports an MTU of up to 9001 bytes
+DEFAULT_MTU=9001
+
 get() {
        local file="${1}"
 
@@ -167,6 +170,7 @@ import_aws_configuration() {
                                        echo "RED_NETMASK=${netmask}"
                                        echo "RED_NETADDRESS=${netaddress}"
                                        echo "RED_BROADCAST=${broadcast}"
+                                       echo "RED_MTU=1500"
                                        echo "DEFAULT_GATEWAY=${gateway}"
                                ) >> /var/ipfire/ethernet/settings
 
@@ -188,6 +192,7 @@ import_aws_configuration() {
                                        echo "GREEN_NETMASK=${netmask}"
                                        echo "GREEN_NETADDRESS=${netaddress}"
                                        echo "GREEN_BROADCAST=${broadcast}"
+                                       echo "GREEN_MTU=${DEFAULT_MTU}"
                                ) >> /var/ipfire/ethernet/settings
                                ;;
 
@@ -204,6 +209,7 @@ import_aws_configuration() {
                                        echo "ORANGE_NETMASK=${netmask}"
                                        echo "ORANGE_NETADDRESS=${netaddress}"
                                        echo "ORANGE_BROADCAST=${broadcast}"
+                                       echo "ORANGE_MTU=${DEFAULT_MTU}"
                                ) >> /var/ipfire/ethernet/settings
                                ;;
                esac