What is Spine and Leaf Network Architecture?

What is Spine-Leaf Architecture?

A lot of changes have happened in the data center architecture during the last couple of years. Many companies are shifting from the traditional 3-layer architecture (access, aggregation, and core) that was found to be only ideal for the “south to north” flow of data and not “east to west.” Spine-leaf is the new architecture model that lots of organizations are adopting thanks to the many benefits it has over the traditional 3-layer architecture.

Spine-leaf was developed to overcome the many limitations of the 3-tier architecture that many data centers have been using for the last decades. In this article, we shall discuss everything you may need to know about the spine-leaf architecture, including the differences and benefits it has over the 3-layer architecture. Without any further ado, let’s jump right in!

Spine-leaf architecture – explained!

A spine-leaf architecture refers to a data center network topology that involves two switching layers that is the leaf switches and the spine switches. The spine layer involves switches that act as the core of the network, so they do all the routing work. On the hand, the leaf layer consists of access switches that connect to the servers, storage devices and other end-users of the network.

With this kind of architecture, each leaf switch is connected to all the spine switches in the network. That means the different servers in the network can communicate with each other, and there is no more than one interconnected switch path that connects two leaf switches. That are several benefits that come with using the spine-leaf architecture. Let’s discuss some of them in the next section.

Spine-leaf vs. the Traditional Three-Tier Architecture

The major difference between the two mainly lies in the number of layers each of them consists. Another difference is that the three-layer architecture is primarily designed to accommodate “south-north” traffic, whereas spine-leaf does a better job with east-west traffic.  

Number of layers

The traditional 3-tier architecture consists of three layers; the core, aggregation and access layer. The switches on the access layers are connected to servers and storage devices. The aggregation layer brings together the access layer traffic and also puts in place redundant connections at the access layer. The final layer, which is the core plays the network transmission role.

On the other hand, in the Spine-leaf architecture, there are only two layers; the spine and the leaf. Every switch on the leaf layer connects to every switch in the spine layer of the network. So, no matter the switch any given server is connected to, it has to go through a similar number of devices every time it connects to another server.

Since the traffic only has to travel through the spine switch and one more leaf switch, there is a significant reduction in latency. In the 2-layer architecture, spine switches have the most ports and are the core of the network. Spine switches are also designed to have a higher bandwidth compared to leaf switches.

East-west traffic vs. south-north movement of traffic

Back then, most of the traffic was mainly moving in and out of the data centers, which is usually referred to as south to north. The 3-layer architecture was designed to handle this kind of traffic; that is why it doesn’t prioritize servers to server connection. With the three-layer architecture, a packet of data flows to the core, which directs it to the correct distribution switch and then is finally forwarded to the correct access switch that connects to the server.

But in this era, 70% of the traffic is mainly server to server, what we refer to as east to west. The spine-leaf architecture was designed to optimally handle both the traffic that moves within the servers in the data centers (east to west) and the traffic that moves in and out of the data center (north to south). That is why all the leaf switches are connected to every spine switch within the network mesh.

In the 2-layer architecture, every payload has to move through the spine switch and only one leaf switch before getting to its destination. This minimizes the latency whenever there is a need to move data from one server to another.

To sum this up, the spin-leaf architecture was invented to enable data centers to handle the needs of modern-day computing, where there is more exchange of data between the servers in the data centers than it used to be back. It is for this reason that most data centers have been upgrading their hardware to gradually transition to this new architecture in order to meet modern-day computing needs that involve more east to west movement of traffic.

Benefits of the spine-leaf architecture

More redundancy

One of the major advantages of using the spine-leaf architecture is the improved redundancy. In this architecture, any leaf switch connects to multiple spine switches in the network. So, it is possible to connect a leaf switch to all the spine switches in the network. This provides way more redundancy than in the three-tier model.

Three-tier model data centers use the Spanning Tree Protocol (STP) to avoid network loops. With STP, only two redundant paths are allowed between two connecting points, and only one of them is available at any given time. However, the new spine-leaf architecture allows multiple paths between two points implemented using protocols, including Transparent Interconnection of Lots of Links (TRILL) or Shortest Path Bridging (SPB).

The above protocols allow traffic flows on all the available paths, which leads to more redundancy. And this is all done while avoiding network loops, just like the Spanning Tree Protocol in the three-tier data centers.

Better performance

Improved performance is also one of the major reasons several organizations are shifting from the traditional three-layer architecture to spine-leaf. The availability of multiple network paths makes it easier and faster for servers to communicate and exchange data since there is less congestion on the network.

It should also be noted that this architecture allows direct connection between two points, which is another reason for the improved performance.

Improved scalability

Scalability is another reason that makes spine-leaf architecture better than the traditional 3-layer model. The availability of multiple network paths, all available to carry traffic, reduces the likelihood of congestion even when the network is scaled up. Adding more switches to a spine-leaf network will add more paths to the network hence making it easier to build more extensive networks.

Allows the use of fixed-configuration switches, which are less costly

The spine-leaf architecture supports the use of fixed-configuration switches that are less costly compared to the modular chassis switches that are normally used in the three-tier network architecture. Not having to use the more expensive modular chassis switches reduces the overall cost of implementing this architecture in a data center.

Energy efficiency

Fixed-configuration switches require slightly lower power than the modular chassis switches used in the 3-layer data centers. When you consider the fact that data centers have thousands or even millions of switches, this cost difference becomes more significant. So, the energy cost of running data centers using the spine-leaf architecture is way lower.

It can be used by enterprises too.

At the start, the spine-leaf network architecture was designed mainly for large data centers to fix the issue of the east-west nature of traffic between servers and storage systems. However, enterprises are starting to adopt this architecture while building their servers. Enterprises are beginning to ditch the three-tier architecture because of the significant increase in the number of devices connecting to the access layer.

IoT devices that are now pretty common in enterprises generate huge chunks of data that need to be transmitted between different servers with little latency. The bottlenecks of the three-tier architecture make it less ideal to use this architecture if you intend to connect multiple resource-demanding devices on the network.

Good for cloud and containerized infrastructure

The prevalence of cloud and containerized infrastructure has been growing significantly in the last couple of years. Most sophisticated applications now use the microservices architecture with multiple services distributed across different servers or virtual machines. With this kind of infrastructure, there is a lot of east-west data transmission.

It is the spine-leaf datacenters that are designed to efficiently handle applications using the microservices architecture.

Limitations of the spine-leaf architecture

Despite the many benefits of using the spine-leaf architecture, there are some limitations that come with implementing this architecture. Some of them include the following;

More cables are required.

Since each leaf switch has to be connected to every spine device in the network, more copper cables have to be used to make all these connections possible. This, of course, leads to an increase in the cost of cables needed in the network. Of course, with so many connections required, a lot could go wrong.

Limited hosts

With this architecture, the number of hosts that can be supported is limited. The number of ports on the spine switches will limit the number of leaf switches we can add to the network. Of course, there are ways this issue is being resolved. Spine switches that are designed for this kind of architecture usually come with more ports when compared to the switches that were designed for the core layer in the 3-tier data centers.

Design Considerations of Spine-leaf Architecture

You need to consider two main factors while designing a spine-leaf architecture. These are oversubscription rate and leaf and spine sizing. Let’s look at each of these in detail.

Oversubscription rate

This refers to the contention rate when all devices on the network are sending traffic. Network engineers have to consider the contention rate while designing a spine-leaf architecture in order to avoid situations where the network gets bottlenecks when every device is trying to send traffic.  

Contention rate can be measured in both the north to south direction (traffic coming in and out of the data center) and in the east to the west direction (traffic between devices/servers within the data center). The recommended oversubscription ratio for networks in modern-day data centers is 3:1 or less, which is basically the ratio between the upstream bandwidth to downstream capacity.

It should be noted that the uplink has to always run faster than the downlink in order to avoid having port link blockage.

Leaf and spine sizing

Another crucial factor that network engineers have to put into consideration is the number of leaf and spine switches that have to get into the network. It is important to note that the maximum number of leaf switches in the topology will depend on the port density of the spine switches.

The number of spine switches in the topology will depend on the required throughput between the leaf switches, their port density and the number of redundant paths. So, the first step is determining the needed throughput, which will guide you to deciding the port density and the number of spine switches you need to add to the topology.

Final thoughts

We have looked at some of the basics that you may need to know about spine-leaf or 2-tier network architecture. This architecture was designed to meet the needs of a modern-day data center that involves a lot of east-to-west traffic. Old data centers used the 3-tier architecture because they did not have to deal with many server-to-server communications since most of the traffic then was moving in or out of the data center (south to north).

Network engineers need to understand this new architecture well since it is what most data centers are transitioning to, thanks to its many benefits over the traditional 3-layer architecture.