Create and verify a jumbo frame MTU network
This page walks you through creating a Virtual Private Cloud (VPC) network anda pair of VMs for testing. It assumes you are generally familiar with networkMTU.
Create an auto mode VPC network
Console
In the Google Cloud console, go to theVPC networks page.
Select a project in the project pull-down menu.
ClickCreate VPC network.
Enter aName for the network.
ChooseAutomatic for theSubnet creation mode.
Clear theSet MTU automatically checkbox.
Set theMaximum transmission unit (MTU).
For a VM to send and receive jumbo frames, the VM's virtual NIC needsto be connected to a VPC network with a MTU value that is as large orlarger than the machine MTU. Set the MTU to the largest possible valuefor the VM, for example 8896. If you're using GPU machines, seeJumbo frames and GPU machines.
ClickCreate.
Create firewall rules
Console
In the Google Cloud console, go to theFirewall policies page.
ClickCreate firewall rule.
Enter aName for the firewall rule.
This name must be unique for the project.In theNetwork pull-down menu, specify the name of the network youcreated.
In theTargets pull-down menu, selectAll instances in thenetwork.
From theSource filter pull-down menu, selectIPv4 ranges.
In the field enter10.128.0.0/16.
InProtocols and ports, selectSpecified protocols and ports.
Check thetcp checkbox and enter22 in the field.
Check theOther protocols checkbox and entericmp in the field.
ClickCreate.
Create VMs
This section shows you how to create two VM instances for testing.
Console
Do these steps twice to get two VMs in the same zone.
In the Google Cloud console, go to theVM instances page.
ClickCreate instance.
Specify aName for your first VM.
ClickNetworking, Disks, Security, Management, Sole-tenancy.
ClickNetworking.
InNetwork interfaces, clickdefault default (10.128.0.0/20).
In theNetwork pull-down menu, select the network you created.
Connect to VM instances using SSH
Console
In the Google Cloud console, go to theVM instances page.
In theConnect column of your first instance, clickSSH.
In theConnect column of your second instance, clickSSH.
Verify MTU
In the terminal for yourfirst VM, run the following command:
/sbin/ifconfig | grep mtu
The reported MTU should be
8896.ens4: flags=4163
mtu 8896lo: flags=73 mtu 65536 In the terminal for yoursecond VM, install
tcpdump:sudo apt-get install tcpdump --yes
In the terminal of yoursecond VM, start
tcpdump. ReplaceFIRST_VM_NAME with the name of your first VM.sudo tcpdump hostFIRST_VM_NAME -v
In the terminal of yourfirst VM, ping your second VM. The ping commandmust specify a packet size that is 28 bytes smaller than the network MTU.ReplaceSECOND_VM_NAME with the name of your second VM.
pingSECOND_VM_NAME -c 10 -M do -s 8868
Check your second VM. You should see something like the following:
tcpdump: listening on ens4, link-type EN10MB (Ethernet), snapshot length 262144 bytes19:43:57.116005 IP (tos 0x0, ttl 64, id 0, offset 0, flags [DF], proto ICMP (1), length 8896)FIRST_VM_NAME.c.PROJECT_ID.internal >SECOND_VM_NAME.c.PROJECT_ID.internal: ICMP echo request, id 5253, seq 1, length 887619:43:57.116053 IP (tos 0x0, ttl 64, id 23961, offset 0, flags [none], proto ICMP (1), length 8896)SECOND_VM_NAME.c.PROJECT_ID.internal >FIRST_VM_NAME.c.PROJECT_ID.internal: ICMP echo reply, id 5253, seq 1, length 8876
The variables mean the following:
FIRST_VM_NAMEis a name of your first VM.SECOND_VM_NAMEis a name of your second VM.PROJECT_IDis the ID of the project containing theVMs.
On your second VM, press
Ctrl-cto stoptcpdump.When you're done testing, delete your resources in the following order:
- Firewall rule and VM instances
- VPC network
What's next
- Learn more aboutMTU.
- Create aVPC network with a specifiedMTU.
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2026-02-19 UTC.