VMware vSphere 6.5 Change vmkernel MTU size
When dealing with VMkernel ports in vSphere 6.5 for most use cases for performance, we want to enable jumbo frames on the vmkernel ports to allow for less fragmentation of the packets for iSCSI, vMotion, and so forth. ย Let’s take a quick look at the topic of VMware vSphere 6.5 Change VMkernel MTU sizeย with the web client as well as with PowerCLI.
VMware vSphere 6.5 Change vmkernel MTU size
Changing the MTU size in the web client is a bit clunky as you have to click in the right place to get the MTU options for your VMkernel ports. ย However, it is fairly straightforward with just pointing and clicking.
Underย Networking >> Virtual Switches. ย We then need to click the vmkernel port group and click the vmk nic and IP address. ย Then click the “pencil” button which takes us to where we can modify the vmk nic settings.
Here we can change theย NIC settings toย 9000.
Also, make sure the vSwitch itself is also set for Jumbo frames. ย Click the vSwitch above and the pencil icon above the vSwitch section. ย Here we can set the jumbo frames MTU to 9000.
Using PowerCLI
Alan Renouf has a great one liner script for getting vmkernel port settings including MTU and altering these to 9000.
Getting the port settings.
Get-VMHost | Get-VMHostNetworkAdapter | Where { $_.GetType().Name -eq "HostVMKernelVirtualNicImpl" } | Select VMHost, Name, MTU
Changing the settings without confirming:
Get-VMHost | Get-VMHostNetworkAdapter | Where { $_.GetType().Name -eq "HostVMKernelVirtualNicImpl" } | Foreach { $_ | Set-VMHostNetworkAdapter -Mtu 9000 -Confirm:$false }
Before:
Thoughts
VMware vSphere 6.5 Change vmkernel MTU size is easily accomplished either in the Web client or by using PowerCLI. ย The beauty of PowerCLI is that if you want to make mass changes, there is simply no way to do these kinds of bulk changes in the web client so PowerCLI is a much better option. ย There are many great one liners out there written by Alan and others that are extremely useful making these types of changes.