New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Network: add mtu setting #501
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ciao @squeed thx for pr! 🎅 Looks good.
We are missing however to handle a case: if we have an existing network and we want to update the mtu
value from an existing network ( example exiting network A mtu 2000 to 1000 fake values via terraform apply)
https://github.com/dmacvicar/terraform-provider-libvirt/blob/master/libvirt/resource_libvirt_network.go#L249 this is the function. If you want to test it via |
@squeed you will adress the comments in middle-term time? TIA. maybe next year, or when do you have time, feel free to do it. If you need need this urgently, i could help you adding the update call .let me know, ciao enjoy your day |
ciao @MalloZup. I should get to this in the next few days, thanks a lot for the pointers! |
@squeed yw, for any info feel free to ping. ok thx for info and take your time as needed 🍵 |
@MalloZup I think we will not be able to change the MTU dynamically, so I guess we will have to set |
@squeed can you rebase on top? @inercia @dmacvicar feel free to review and share your pov on it |
Closing due to stale. thx for pr feel free to reopen with rebase. Thx.! |
@MalloZup Picking this back up, finally. MTU isn't changeable on live networks - how should I handle this? |
@squeed hi, just rebase with master |
Signed-off-by: Casey Callendrello <cdc@redhat.com>
Rebased and updated. Thanks! BTW, I have a change in Libvirt 5.1 that sets mtu as a DHCP option too :-) |
@dmacvicar cc |
We have xslt which let you add it without implementing it in go. |
@squeed we decided following design goals: This goals were made to follow kind of minimalism in term of design/maintenance and also focus on feature which would enable more the community. I'm thinking that this PR is good per-se, but i am hesitating because of it thx anyways. I will let @dmacvicar and @inercia take decision on it |
Hi there, I understand where you are coming from - libvirt is definitely a large API surface. I would argue MTU makes the cut - it is a single independent scalar property that is easily plumbed through. It doesn't really add any complexity. It is also hard to change on a running network, which makes it difficult to fix up after Terraform. Setting the MTU is definitely critical for Kubernetes clusters, since the vxlan overhead decreases significantly for larger packets. That's my use-case, FWIW. So, IMHO, this would be a great feature to add. |
@squeed yep to me your PR is good to merge but i want to reach a consesus with other maintainers |
I agree with @squeed: I think the MTU is an important parameter in a network and it should be part of the exposed interface in the provider. |
This plumbs through the "mtu" top-level variable in the network XML.
It's not amazingly useful, as libvirt doesn't pass it through to the DHCP server, but... baby steps!