ipspace / netlab

Making virtual networking labs suck less
https://netlab.tools
Other
444 stars 66 forks source link

Add support for EBGP sessions over unnumbered interfaces #102

Closed ipspace closed 2 years ago

ipspace commented 2 years ago

Right now, unnumbered external links crash netsim-tools. Fix that and add support for Cumulus-style unnumbered EBGP sessions.

petercrocker commented 2 years ago

I can work on this once this PR has been reviewed/merged: https://github.com/ipspace/netsim-tools/pull/155

petercrocker commented 2 years ago

Work in progress: https://github.com/ipspace/netsim-tools/pull/158

Note, I'm considering completely overhauling how Cumulus is configured. Right now, it's shell scripts copied to the node then run through vtysh. And it results in some inconsistencies between vtysh and NCLU. The typical way people automate Cumulus these days is to render /etc/network/interfaces and /etc/frr/* files via j2 templates, and have ansible push when they change and HUP daemons appropriately. I'm happy to update all of this, and it'll make it easier for future code changes (like vxlan). That said, it'll be a number of changes so don't want to bother unless it's worth it. Let me know any opinions on this @ipspace !

ipspace commented 2 years ago

I had this discussion before (#48 with @ssasso). I really don't mind how we configure Cumulus, but rendering a single configuration file from multiple configuration modules and custom templates could become an exercise in futility (see #80) as you need to configure interface parameters for OSPF, BGP, BFD, MPLS... and you don't want to have one giant all-in-one interface template. No idea how FRR handles a half-dozen configuration files with every file configuring some aspects of the same interface. I know how Cisco IOS reacts to that, and it's not nice.

It was nice having (almost) the same templates for Cumulus and FRR containers, but I have no problem if we have to diverge. I don't expect we'll ever try to implement VXLAN/EVPN on FRR containers -- one should use Cumulus VX for that.

So, if you feel like cleaning up and rewriting Cumulus templates, please go for it (or share it with @ssasso). I hacked something together to make it work with minimum effort, and I'm positive you know a much better way of doing it.

jbemmel commented 2 years ago

Personally, I think it might be valuable if we could showcase NVUE: https://docs.nvidia.com/networking-ethernet-software/cumulus-linux/System-Configuration/NVIDIA-User-Experience-NVUE/

To me it is not only about how to make things work, it's also how to organize things properly and sustainably. And while this would pose more of a competitor for SR Linux and SR-OS, I think it would be a healthy competition that would benefit the project and the community overall.

Of course, if people prefer to keep the dull config file template based approach, that's also fine with me - but I think we have plenty of examples for that already

petercrocker commented 2 years ago

I've been meaning to try programming to the new NVUE data model, and it would make this much cleaner, but it would put a requirement that people must spin up Cumulus Linux >= 5.0 only. Or we'd have to maintain an old (vtysh) and new (NVUE) way of doing it.

ipspace commented 2 years ago

Personally, I think it might be valuable if we could showcase NVUE: https://docs.nvidia.com/networking-ethernet-software/cumulus-linux/System-Configuration/NVIDIA-User-Experience-NVUE/

That sounds great, but remember how a similar great idea ended -- it was closed-source and available only with a paid license.

To me it is not only about how to make things work, it's also how to organize things properly and sustainably.

I'm all for that, but we also have to give networking engineers a tool that's useful. If everyone is OK with running Cumulus Linux 5.0, then I don't care, if most people prefer the older versions for whatever reason (like: because the newer version crashes) then we have a challenge.

Also, I don't think it makes sense to waste energy on maintaining two parallel ways of configuring a box.

Of course, if people prefer to keep the dull config file template based approach, that's also fine with me - but I think we have plenty of examples for that already

Presenting the correct examples is a different discussion, this tool should be about "making networking labs suck less". Nobody cares what's behind the scenes as long as they get the boring part of the configuration out of the way so they can start working on the fun stuff.

... and I thought this issue was about unnumbered EBGP sessions ;)

petercrocker commented 2 years ago

You can prob close this out now @ipspace since you merged the code.

I've got Cumulus >= 5.0 via yaml half implemented already. We're going to need it no matter what, since NVIDIA is going to push a vagrant box soon, and it'll be the default download, and it mandates the new NVUE cli/api. I'll create a new issue to track it.

On another note, just read your blog post this morning about python Box. Would have saved me a few hours yesterday learning the hard way about how it creates blank {} values, and how to work around that! See https://github.com/ipspace/netsim-tools/pull/158/commits/7175d5563dd9658c7432b503ac016a5000902c58

ipspace commented 2 years ago

Sorry about the Box stuff -- things are moving so fast I'm barely managing to catch up.

I know I have to write "Python developer guidelines", today's blog post is probably a decent starting point.