New Question

How do I set the Init.MTUSize to 9000 in the NetKVM Virtio Windows Driver

asked 2016-03-17 00:12:18 +0300

jmcevoy gravatar image

While developing a high performance Windows 7 mechanical engineering environment where most of the resources of the OpenStack vmhost are given to the Windows 7 instance running under the KVM hypervisor we have hit a problem configuring the 10GigE network which uses jumbo frames. We have managed to get cloudbase-init to set the MTU on the network interface but have just discovered that the NetKVM virtio driver also has an MTU setting named Init.MTUSize. The RedHat documentation only has a GUI method for changing from the default MTU size of 1500. Is there a way to change this driver setting using cloudbase-init? The engineers who will be using these virtual workstations will not have administrative authority in Windows to change the driver settings. We loose network connectivity to the VM when the small MTU is set in the driver. I'd like to avoid building a special version of the Windows virtio drivers just to change one default value.

edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted

answered 2016-03-17 02:14:13 +0300

avladu gravatar image


First of all, the actual MTU used by the kernel is the one set on the network adapter. The MTU for the network adapter can be set using the following command:

netsh.exe int ipv4 set subint <interface name> mtu=<mtu_value> store=persistent
# for example
netsh int ipv4 set subint "Local Area Connection" mtu=1200 store=persistent
# to show the current interface configuration
netsh.exe int ipv4 show subint

Secondly, if you have installed cloudbase-init, the MTUPlugin will query the DHCP server for the network in case and set it accordingly.

If the above does not apply to your case, you can set the device driver property Init.MTUSize using the registry keys. For example, in my Windows 2008R2 setup, using the Fedora VirtIO drivers version 0.1.102, the registry key with the MTU property value can be found at HKEYLOCALMACHINE\SYSTEM\CurrentControlSet\Control\Class{4D36E972-E325-11CE-BFC1-08002BE10318}\0007\MTU. In your scenario, the registry key can be found at another address, depending on the OS. You can search for the driver's exact registry keys using the HKEYLOCALMACHINE\SYSTEM\CurrentControlSet\Control\Class{4D36E972-E325-11CE-BFC1-08002BE10318}\0007\MatchingDeviceId value, which you can find in your netkvm.inf driver file. You can use the userdata cloudbase-init scripts to set the registry key with the wanted value.


edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2016-03-17 00:12:18 +0300

Seen: 4,999 times

Last updated: Mar 17 '16