---
title: "Configure Aerospike on Kubernetes with AKO"
description: "Configure Aerospike on Kubernetes using the Aerospike Kubernetes Operator (AKO) and Custom Resource files."
---

# Configure Aerospike on Kubernetes with AKO

> For the complete documentation index see: [llms.txt](https://aerospike.com/docs/llms.txt)
> 
> All documentation pages available in markdown.

## About this section

This section explains how to configure an Aerospike Database deployment with Aerospike Kubernetes Operator (AKO). Store cluster settings in the Aerospike cluster CR file. When you create or update the CR file, AKO applies the changes to the cluster. The CR file is not required to be in any specific location on the server where you run Kubernetes, since the command to update AKO with a new version of the file passes the entire file path to AKO.

By default, the examples in this documentation use a CR file named `aerospike-cluster.yaml` in the directory where you run `kubectl`.

::: note
In this section, _CR file_ means the YAML you create and edit locally. After you apply it with the `kubectl apply` command, Kubernetes keeps an in-cluster _Custom Resource (CR)_ that AKO reads and uses to update the cluster. When pages refer to “updating the CR,” they mean editing the CR file and re-applying it unless stated otherwise.
:::

## AKO configuration

Kubernetes uses YAML, while Aerospike uses its own configuration format. AKO translates between the two formats, so you must follow the [YAML configuration conventions](https://aerospike.com/docs/kubernetes/4.1.x/manage/configure/config-mapping).

See [Configuration parameters](https://aerospike.com/docs/kubernetes/4.1.x/reference/config-reference) for a list of all parameters and details on usage. Many parameters support [dynamic configuration](https://aerospike.com/docs/kubernetes/4.1.x/manage/configure/dynamic-config), which lets you update the cluster without a restart.

## Features

See the following pages for in-depth explanations and guides to configuring certain features on your Aerospike cluster.

-   Change the compute resources available to your cluster: [Scaling](https://aerospike.com/docs/kubernetes/4.1.x/manage/configure/scaling)
-   Split a single cluster across different hardware: [Rack awareness](https://aerospike.com/docs/kubernetes/4.1.x/manage/configure/rack-awareness)
-   Duplicate a cluster across different datacenters: [XDR](https://aerospike.com/docs/kubernetes/4.1.x/manage/configure/xdr)
-   Set up monitoring for the cluster using external tools: [Monitoring](https://aerospike.com/docs/kubernetes/4.1.x/observe/operator-monitoring)
-   Set up an automatically-managed strong consistency namespace to guarantee no partial writes: [Strong Consistency](https://aerospike.com/docs/kubernetes/4.1.x/manage/configure/strong-consistency)

## Configuration change process

In this example, we modify a parameter, triggering a rolling restart (default behavior), and check the parameter value after the restart.

1.  Edit and apply the CR file. For this example, make a change to the number of file descriptors available to each Aerospike Database instance. By default, this is `15000`. Change the [`spec.aerospikeConfig.service.proto-fd-max`](https://aerospike.com/docs/database/reference/config#service__proto-fd-max) field in the CR file to `20000`.
    
    ```yaml
    apiVersion: asdb.aerospike.com/v1
    
    kind: AerospikeCluster
    
    metadata:
    
      name: aerocluster
    
      namespace: aerospike
    
    spec:
    
      size: 2
    
      image: aerospike/aerospike-server-enterprise:8.1.0.0
    
      aerospikeConfig:
    
        service:
    
          proto-fd-max: 15000
    ```
    
2.  Save and exit the CR file, then use `kubectl` to apply the change.
    
    Terminal window
    
    ```shell
    kubectl apply -f aerospike-cluster.yaml
    ```
    
    The Kubernetes pods undergo a rolling restart.
    
    > Output:
    > 
    > Terminal window
    > 
    > ```sh
    > $ kubectl get pods -n aerospike
    > 
    > NAME              READY   STATUS    RESTARTS   AGE
    > 
    > aerocluster-0-0   1/1     Running   0          3m6s
    > 
    > aerocluster-0-1   1/1     Running   0          3m6s
    > ```
    
3.  After all the pods have restarted, use `kubectl describe` to get the cluster status. Check `spec.aerospikeConfig.service.proto-fd-max` under “Status.”
    
    Terminal window
    
    ```sh
    $ kubectl -n aerospike describe aerospikecluster aerocluster
    
    Name:         aerocluster
    
    Namespace:    aerospike
    
    Kind:         AerospikeCluster
    
    ...
    
    Status:
    
      Aerospike Config:
    
        Service:
    
          Proto - Fd - Max:   20000
    
    ...
    ```
    

## Unchangeable parameters

AKO does not support setting certain configuration parameters in the CR file. See the [limitations](https://aerospike.com/docs/kubernetes/4.1.x/install/limitations) page for more information.