mininet icon indicating copy to clipboard operation
mininet copied to clipboard

Change MTU (Maximum Transmission Unit) of a mininet host

Open p4pifor opened this issue 3 years ago • 1 comments

How can I change the MTU of a mininet host through the python script? I've figured it out with my switch's interfaces, I'm not able to do it with hosts though. Any idea of how can I do it? Thanks in advance

p4pifor avatar Aug 01 '21 09:08 p4pifor

Hello, I am not sure whether this is the correct way to do this or not, but I found a workaround for this.

When creating topology using python script we can run commands inside every host. Using the "ifconfig" command we can change MTU of a mininet host.

Example Code:

h1.cmd('ifconfig h1-eth0 mtu 65535') # here h1-eth0 is the interface name, 65535 is the new MTU for host 1.

NOTE: the above command must be executed before starting the CLI inside the python script.

shamimtowhid avatar Jul 01 '22 20:07 shamimtowhid

@lantz consider closing this issue and creating a "user support" label to mark such issues. GH issues should not be used for this type of questions.

janev94 avatar Nov 17 '22 12:11 janev94

Remember not to abuse github issues by posting support requests or usage questions.

lantz avatar Nov 18 '22 01:11 lantz