﻿# Node load balancing

> [HTML Version](pod-topology-spread-constraints.html)

To increase system resiliency during host or zone failures, configure the \[OBJECT\] parameter. This controls the even distribution of pods across the cluster topology, such as availability zones, nodes, or regions.

Before configuring the \[OBJECT\] parameter, please read the [BRIX On-Premises advanced settings](advanced-kubernetes-settings.md) article to learn about all the pod placement tools and recommendations for using them together.

## How to configure the topologySpreadConstraints parameter

You can configure the \[OBJECT\] parameter in the \[OBJECT\] file. Go to the \[OBJECT\] field and set the values, for example:

````
global:  
  topologySpreadConstraints:  
    - maxSkew: 1  
      topologyKey: "kubernetes.io/hostname"  
      whenUnsatisfiable: ScheduleAnyway

````
Where:

- \[OBJECT\] is the maximum allowable difference in the number of pods between nodes.

- \[OBJECT\] is the metadata key to define the topology of the nodes, for example \[OBJECT\].

- \[OBJECT\] is the algorithm of action if the constraints cannot be applied:

	-  \[OBJECT\]. If no suitable node is found, the pod will run on any available node.

	- \[OBJECT\]. If no suitable node is found, the pod will not run until the conditions are met.

Once the parameter is configured, apply it as described in the [Modify BRIX parameters](change-settings-enterprise.md#apply-new-parameters) article.

## Default values for the topologySpreadConstraints parameter

In the \[OBJECT\] file, the \[OBJECT\] parameter is set to the following default values:

````
topologySpreadConstraints:  
  - maxSkew: 1  
    topologyKey: topology.kubernetes.io/zone  
    whenUnsatisfiable: DoNotSchedule

````
You can change these values of the parameter.