Setting MTU on bonded interface

Latest response

Hi Guys,

thanks for helping out.

I have two interfaces eth0 and eth1. I have a created a bond0 for this interfaces. I have to change the MTU to 9000. Should set MTU 9000 for eth0 and eth1 as well as bond0?

Thanks for your help with this.

Responses

Hi Arrey,

On RHEL 6.6, we have the directive below in the ifcfg-bond0 and ifcfg-bond1 files (the server in question I queried has two bonded interfaces)

MTU=9000

We do not have the MTU directive in any of our ifcfg-ethX files

I just verified that out of one of our database servers that has been up for quite a number of days...

Kind Regards

Thanks Hinton. I was not very certain of this. But I did set the MTU on the bond interface and not on the eth interfaces. With your confirmation now, I can give myself a pat on the back. Thanks for your feedback. Much appreciated.

Arrey

Hey Rem/Arrey,
I had pondered this a bit, but didn't have anything to contribute (which I still don't ;-) but, I could not conclude as to whether an MTU is interface specific (physical - i.e. eht0 ), or logical (bond0). And I am still struggling with the concept. Let's say you have an active/passive bond (eth0 and eth1) currently active on eth0 and the MTU is set at 1500 (and working), and then there is failure, but for whatever reason eth1 can only use an MTU of 1492. (perhaps eth1 is plumbed to an older or misconfigured switch?).

This guy sort of talks about the same scenario
https://joshua.hoblitt.com/rtfm/2014/05/dynamically_changing_the_mtu_of_a_linux_bridge_interface/

So - it seems as though it would fail to accept the value if any component in the config was not capable of that MTU size (although that example is referring to a bridge).

Check out this older post on the topic too
https://access.redhat.com/solutions/64136

Good point. That's the reason why things have to be configured correct the first time and also tested. I think it will be safe to set MTU on the eth's as well. What does red hat say about this ?

You only need to set it on the bond, it will be propagated to the slaves. I edited the solution that James linked to in order to emphasize that.

As Stephen said, and additional as stated previously, in our own production network (and also test/development network) we only put the MTU directive in the ifcfg-bondX interface and not in any of the ifcfg-ethX files. We also follow the RHEL nic bonding guide, which oddly doesn't mention anything on this.

So both in my own experience/practice of years, and also what Stephen says as well, I'd recommend against putting the MTU directive in the ethX files. We've been running bonded NICs with no issues using the MTU directive only/solely in the ifcfg-bondX. Feel free to experiment, but I can tell you our bonded NICs work just fine in the way described.

James/Steve, thanks for the link, and Steve, thanks for editing it for clarity.

Kind Regards,

Great, I will follow what the experienced people have done. My bond stays with the MTU. Thanks to you all for the replies.