Vyos does not support multi-core?

Hi there,
Please correct me if i am wrong. I looked around the code and realized that Vyos does not have multi-threading support for it’s routing protocols at least, which means the performance of routing will not benefit from multi-core platforms?

If this is true, is there any plan to rewrite the routing protocol code (Quagga) to multi-threading? Is it necessary? Any advise?

Thanks!

You should probably ask that question on the quagga development mailing list.
VyOS just uses certain software that is available from upstream.
Quagga wants to be usable over several operating systems which limits certain easy optimizations.

You could of course also google this subject.

I understand vyos utilized quagga for ease of life. But as serialization of quagga limited routing performance of vyos, is there anyone in this forum could decide whether or not to modify or improve that for vyos? Let alone quagga being itself. :slight_smile:
Or is it necessary to do that?

Quagga itself doesn’t do any packet routing tasks. Quagga updates kernel routing tables and the kernel do routing jobs. The bottleneck of routing performance is in hardware and Linux kernel.

The main performance issue with large routing tables is that every packet should be passed throught large number of routing entries (the full routing table of Internet consists of ~500k entries for now) to make the desicion where it should be routed to. There is a number of optimized search algorithms that can speed up lookups a bit, but the problem still persists: conventional CPUs are working in sequnce way, they can analyze entries one-by-one only (ok, for 8-core CPU it’s possible to do 8 lookups per tick, but it’s still unsufficient).

That’s why high-end routers use specialized CPUs with embedded associative table lookup engines (like TCAM in FreeScale’s QorIQ or Cavium’s Octeon) or external routing co-processors connected to main CPU via high-speed interfaces (like we’re using in our platform) which make it possible to do routing entries lookup in just a few ticks. But it requires that router’s hardware and kernel supports this engines at low level.

You are right on the packet forwarding, ie. data plane of the linux box, we are talking about 2 different things. route table updates performance can also be improved by multi-threading, did some research, and for BGP, multi-threading can speedup to 6.5 times running on 16 cores.

Even for the forwarding plane, using multi-threading, and multiple Q on recent NIC, the throughput can reach 10G per core, as per research papers.

We should compare apple to apple.

As of now, Vyos could not benefit from multi-core, neither in routing table updating nor packet forwarding(?), is there any plan to address that?

I google’d a bit about the multithreading router and found some interesting comments below, just post it here for your reference. According to the information, XORP is a multi-threading routing suite, but has BGP performance issue, hence Vyatta turned to Quagga since VC4. Interesting enough, XORP uses “Click modular router” in the forwarding plane, which is an elements-based, multi-thread router.

Could anybody please give more comments on this topic?

Sorry for the late reply. VyOS directly may not have multi-threading. But few multi-threaded Data-planes have been written, for Packet forwarding.

Vyatta did it in the past. We (paxym) completed the same for a Customer last year, using OCTEON cpu cores. But also made it to work with Intel DPDK.
vyos-dpdk-accelerated-data-plane

Just realised that this is quite an old thread but it is worth noting that VyOS 1.2.0 switched from Quagga to FRR:

It looks like FRR is aware of the issue of the need to scale performance by adding more cores:

http://docs.frrouting.org/projects/dev-guide/en/latest/process-architecture.html